Skip to main content
Topic: How do I sense direction with Aurdino? (Read 3113 times) previous topic - next topic

How do I sense direction with Aurdino?

Hello, I don't know if this is the correct place or forum to ask my question(s) in, so if not please refer me to the correct place.  Anyways, I am wondering if the A-Tech PTAM27/PTDM27 inclination sensor (sorry for no link, I was blocked from linking) is compatible with the Arduino board or if anyone has experience with it to know the output of the sensor.  The end result is to have two sensors on a helmet (one sensing up-down rotation and the other sensing left-right rotation) that connect the the Arduino board which in turn translates the sensor output into Arduino output going to two stepper motors (I know how to code) which move an object (spotlight possibly) so that it points wherever your head is pointing/looking at.  If there are any better sensor(s), please feel free to inform me.  Any help is appreciated!
-=m0dem=-

Re: How do I sense direction with Aurdino?

Reply #1
Doesn't someone have any ideas?  Please. :)
-=m0dem=-

Re: How do I sense direction with Aurdino?

Reply #2
"compatible" is a complex word... The sensor you've mentioned comes in five or six flavours of output and one or two axes of sensing. Depending on which one you have, it'll be easier or harder to interface to. It may or may not be the best sensor to use. Other sensors that might work include 2 or 3 axis gyros, of which there are many, with many different interfaces.

 

Re: How do I sense direction with Aurdino?

Reply #3
I wouldn't use gyros for position sensing. They are for measuring angular velocity, which you have to integrate to get position value. They also have a drift so over time error gets quite large.

Inclination sensors are good. What you should look for is SPI or I2C communication if digital (better) or analog output (harder to deal with). A 3 axis accelerometer would do too, you'll have to filter the output to get rid of the noise.

As an example Wii Nunchuck has a 3 axis accelerometer in it and uses I2C for communication. They are not that expensive and you can crack open the shell and get rid of all the buttons and joystick to make it slimmer. Also there are tons of tutorials about using it, eg: http://todbot.com/blog/2008/02/18/wiich ... available/