Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > Electronic Projects Design/Ideas/Reviews


Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution.

Reply
 
LinkBack Thread Tools Display Modes
Old 8th August 2007, 02:47 PM   (permalink)
Default electronic trigonometry?

im curious, if i was to build a walker robot, (not neccesarily autonimous, probably remote to start with) yet i wanted to be able to control its motions using maths to work out the position of each leg, mainly using COS, SIN, and TAN, posibly also in the inverse function, how would i go about getting a curcuit to do that? can a PIC do it?

if it can any code examples of the normal and inverse function would be brilliant, thanks
Torpedo is offline  
Old 8th August 2007, 09:53 PM   (permalink)
Default

I think it's a bit too much for a PIC (a dsPIC should be able to though). You might need this with a normal PIC:
http://www.micromegacorp.com/
dknguyen is online now  
Old 8th August 2007, 10:09 PM   (permalink)
Default

As it's a robot, speed isn't an issue, so there's plenty of time even for normal PIC's to do the maths. The PICList has maths routines, as does the EPE website. But I suspect you're probably making this a LOT harder than it needs to be?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 9th August 2007, 12:11 AM   (permalink)
Default

i was considering trying to put something together similar to the hexapod robot video on youtube, a little red one that walks around a cola bottle and can translate in the Y, Z and X axis and rotate about all three. its pretty impressive so i was thinking of trying to design something similar, but wanted to know if the sort of calculations i'd need could be done.
Torpedo is offline  
Old 9th August 2007, 12:14 AM   (permalink)
Default

this little bugger lol

http://www.youtube.com/watch?v=gsCbv...elated&search=
Torpedo is offline  
Old 9th August 2007, 12:17 AM   (permalink)
Default

I guess it depends how frequently you want to update it. THat's still a lot of trig per leg though and a lot of legs. It's a bit pointless to do some of that if you have no plan on where you want the leg in real-time, otherwise you could do all the calculations for a set of pre-defined positions beforehand and stick them in a table. Seeing as how it's RC servos and you don't have external access to the actual position of the servo, there might be no real reason to dynamically calculate foot positions (at least not very frequently).
dknguyen is online now  
Old 9th August 2007, 01:28 PM   (permalink)
Default

well i was thinking i didnt just want another walker that only goes on flat surfaces and only does steped up surfaces on the off chance you made its legs go high enough!
Torpedo is offline  
Old 9th August 2007, 09:30 PM   (permalink)
Default

Quote:
Originally Posted by Torpedo
well i was thinking i didnt just want another walker that only goes on flat surfaces and only does steped up surfaces on the off chance you made its legs go high enough!
I still don't see any need, or reason, for trig. to do that?. Assuming you want to vary the height of the gait based on the terrain, you simply need some kind of sensor to identify the terrain type, and alter the gait accordingly.

There are plenty of examples of walking HEX robots on the net, as far as I'm aware none use trig. functions?, nor can I think of a reason why they would want to?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 9th August 2007, 09:58 PM   (permalink)
Default

THen you would need vision (really REALLY extremely good vision at that) to make trig useful so it knows where it wants it's foot in advance. I know the temptation of wanting to give your robot as much feedback as you can though. Add foot pressure sensors first, and something that can track the terrain. Probably best to slowly build up on top of a working model than to build it all at once.
dknguyen is online now  
Old 10th August 2007, 07:11 AM   (permalink)
Default

You do realise that the Hexapod V4 is driven by a PC via a serial link !
Google link to the source due to the site being down currently.

Far more power than a PIC.
yngndrw is offline  
Old 10th August 2007, 09:25 AM   (permalink)
Default

Quote:
Originally Posted by yngndrw
Far more power than a PIC.
Obviously! - but I doubt that's why it was done, as a PIC (or a couple of PIC's) has far more power than required anyway. Presumably it was used mostly as a remote control system?, for the purposes of filming.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 10th August 2007, 03:36 PM   (permalink)
Default

Quote:
Originally Posted by yngndrw
You do realise that the Hexapod V4 is driven by a PC via a serial link !
Google link to the source due to the site being down currently.

Far more power than a PIC.
doesnt particularly matter, i thought it could be driven by an onboard system but either way im pretty sure they did make an onboard system which is in the video i posted above.

Thing is the question isnt why id want to do it, i'd just like to know how to do it!

which code forms that run on a pic are capable of doing the neccesary calculations, what code line i'll need to write to perform such!

i know it'd be very complex, but it has more uses than just a single walking machine, i mean for instance just a simple arm could be made alot more useful if you can calculate its exact position in space around it, which you'd need trig to do.
Torpedo is offline  
Old 10th August 2007, 03:57 PM   (permalink)
Default

Quote:
Originally Posted by Torpedo
Thing is the question isnt why id want to do it, i'd just like to know how to do it!

which code forms that run on a pic are capable of doing the neccesary calculations, what code line i'll need to write to perform such!
Like I said back in the 3rd post in this thread, there is code on the PICList and the EPE website.

Quote:

i know it'd be very complex, but it has more uses than just a single walking machine, i mean for instance just a simple arm could be made alot more useful if you can calculate its exact position in space around it, which you'd need trig to do.
Lookup tables would do just as well, and a LOT faster, although speed isn't likely to be an issue here. You would also need to consider how accurate RC servo's actually are - assuming you're looking at using those?.
__________________
PIC programmer software, and PIC Tutorials at:
http://www.winpicprog.co.uk
Nigel Goodwin is offline  
Old 10th August 2007, 05:45 PM   (permalink)
Default

Quote:
Originally Posted by Nigel Goodwin
Obviously! - but I doubt that's why it was done, as a PIC (or a couple of PIC's) has far more power than required anyway. Presumably it was used mostly as a remote control system?, for the purposes of filming.
I'd also like to point out that the PC can use features like hardware multi-threading and the object orientated programming in C++.

Quote:
Originally Posted by Nigel Goodwin
You would also need to consider how accurate RC servo's actually are - assuming you're looking at using those?.
They also make digital versions of the server which are more accurate especially when moving small distances.
yngndrw is offline  
Old 10th August 2007, 05:56 PM   (permalink)
Default

Quote:
Originally Posted by Nigel Goodwin
Like I said back in the 3rd post in this thread, there is code on the PICList and the EPE website.
ah yes, id seen the pic list one already, was quite suprised just how complicated the routine actually is for a sine fuction.
Torpedo is offline  
Reply

Bookmarks

Thread Tools
Display Modes



Similar Threads
Title Starter Forum Replies Latest
Hello, I'm new to Electronic circuits, how do I get info. on electronic tach for m.c. pwotoole General Electronics Chat 17 16th May 2007 06:33 AM
Signboard electronic leticia Micro Controllers 1 18th March 2007 05:01 AM
100 electronic circuits with ready to copy pcb reyarba Electronic Projects Design/Ideas/Reviews 0 1st November 2006 12:32 AM
frequency-voltage don't work with electronic ignition. Screech General Electronics Chat 7 16th March 2004 01:29 AM
Electronic Engineer evoke General Electronics Chat 1 21st July 2003 01:04 PM



All times are GMT. The time now is 07:32 PM.


Electronic Circuits  |  Learning Electronics
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

eXTReMe Tracker