View previous topic :: View next topic |
Author |
Message |
CrazyIgels
Joined: 26 Oct 2007 Posts: 79
|
Posted: Fri Jan 21, 2011 2:25 pm Post subject: Low cost MEMS YAW angle sensor for mobile robot. How to do? |
|
|
Hello all!
In my robot i use encoders to synchronization of speed and position of the wheels - for strait line movement.
All working fine. But i have trouble with robot turns. Wheels slip on the floor surface an i can obtain high precision on turn angle.
I need to obtain something like 0.5 angle degree precision.
I think - using MEMS solution - good idea to solve this task but complete AHRS systems like http://www.pololu.com/catalog/product/1253 - not cheap.
And i don't need all axis - only one YAW axis to control.
I understand - to solve this task i need gyroscope and accelerometer sensor and MCU to data processing. I want have serial output "angle" and "turning speed" in my system.
Please, tell me - which gyro and accel sensor i need and which code processing i need to. I think - Calman's filter - very hard to implementation on AVR MCU.
PS i have many ATMEGA8 - 16PU MCU an i want to use it in this task.
Thanks all!
Sorry my bad English. |
|
Back to top |
|
|
hgrueneis
Joined: 04 Apr 2009 Posts: 902 Location: A-4786 Brunnenthal
|
Posted: Fri Jan 21, 2011 5:31 pm Post subject: |
|
|
Seems to me you might need a combination of sensors.
For the angle (heading) a compass module like the HMC6352 might be ok.
It can be calibrated and has I2C interface, gives a heading in tenth deg in two bytes.
One source of components and modules might be following website.
http://www.parallax.com/.
Depending on use indoors or outdoors a GPS heading might also be of use.
It all depends on how much money you are willing to spend and what type
of chips you can implement on your boards.
A robot forum might be able to help you better.
For accelleration and g-force I use MMA7261QT (VCC up to 3.6V).
They are a bit hard to surface solder (very small). With 3 analog outputs they are ideal for atmegas with ADC and have 3 axis.
There are as you know many others on the market.
I don't know what is available in your country.
Hubert |
|
Back to top |
|
|
pseddon
Joined: 20 Oct 2006 Posts: 84
|
Posted: Fri Jan 21, 2011 6:13 pm Post subject: Re: Low cost MEMS YAW angle sensor for mobile robot. How to |
|
|
You would not get that level of performance on either gyros or magentos on a robot.
Gyros drift are noisey and are rate devices not absolute position devices. The magneto is very susceptible to magnetic fields from surrounding metal work, motors, current carrying wires etc. and again would not give that level of accuracy (one part in 720).
Using a multisensor approach and fusing the data would not give the accuracy you are looking for. A vision sensing approach might give better results and could give absolute position.
Peter
CrazyIgels wrote: | Hello all!
In my robot i use encoders to synchronization of speed and position of the wheels - for strait line movement.
All working fine. But i have trouble with robot turns. Wheels slip on the floor surface an i can obtain high precision on turn angle.
I need to obtain something like 0.5 angle degree precision.
I think - using MEMS solution - good idea to solve this task but complete AHRS systems like http://www.pololu.com/catalog/product/1253 - not cheap.
And i don't need all axis - only one YAW axis to control.
I understand - to solve this task i need gyroscope and accelerometer sensor and MCU to data processing. I want have serial output "angle" and "turning speed" in my system.
Please, tell me - which gyro and accel sensor i need and which code processing i need to. I think - Calman's filter - very hard to implementation on AVR MCU.
PS i have many ATMEGA8 - 16PU MCU an i want to use it in this task.
Thanks all!
Sorry my bad English. |
|
|
Back to top |
|
|
AdrianJ
Joined: 16 Jan 2006 Posts: 2483 Location: Queensland
|
Posted: Sat Jan 22, 2011 3:32 am Post subject: |
|
|
Think about how an optical mouse does position sensing. The optical sensing assemblies are cheap and are often SPI bus, before sending off to a USB port. I played with one from a mouse quite a while ago, and is pretty easy to read with an AVR. _________________ Adrian Jansen
Computer language is a framework for creativity |
|
Back to top |
|
|
pseddon
Joined: 20 Oct 2006 Posts: 84
|
Posted: Sat Jan 22, 2011 11:53 am Post subject: |
|
|
It uses optical flow technology which is being used in robotic applications.
Peter
AdrianJ wrote: | Think about how an optical mouse does position sensing. The optical sensing assemblies are cheap and are often SPI bus, before sending off to a USB port. I played with one from a mouse quite a while ago, and is pretty easy to read with an AVR. |
|
|
Back to top |
|
|
CrazyIgels
Joined: 26 Oct 2007 Posts: 79
|
Posted: Sat Jan 22, 2011 2:29 pm Post subject: |
|
|
Ok.
First. Thanks All
I can't use GPS to control heading - robot for indoor using only.
If 0.5 deg - impossible - something like 1 - 3 deg - possible with IMU?
I don't want to use optical sensor because we don't know which surface we have on competition field and very hard to obtain good contact with sensor and surface.
We try to use ordinary old style ball mouse - not good - slipping between floor surface and ball |
|
Back to top |
|
|
JC
Joined: 15 Dec 2007 Posts: 584 Location: Cleveland, OH
|
Posted: Sat Jan 22, 2011 6:26 pm Post subject: |
|
|
Well, I think you need to make sure wheel encoders have enough resolution for your needs, and then work on your software for driving them.
If your wheels slip, consider putting a rubber band around them for better traction.
If they still slip when you turn them on, then you need to work on a driver algorithm which will slowly increase their rate of rotation, to overcome the ineria of the system.
JC |
|
Back to top |
|
|
CrazyIgels
Joined: 26 Oct 2007 Posts: 79
|
Posted: Sat Jan 22, 2011 6:36 pm Post subject: |
|
|
We have industrial encoders with 1000 pules per turn resolution.
You don't reply in my question JC - it's possible to obtain 1 -3 deg. precision with low cost "DIY" IMU or not.
I don't want to play with encoders and "start/acceleration" curve and speed tuning because time is critical and we don't have time to slow turns.
All robot movements must be fast as possible - this is main directive to using IMU. |
|
Back to top |
|
|
JC
Joined: 15 Dec 2007 Posts: 584 Location: Cleveland, OH
|
Posted: Sat Jan 22, 2011 10:39 pm Post subject: |
|
|
Crazy,
I think you did not understand my answer, I will try again.
GPS: No, not for short range high precision tracking, and not for indoor usage.
MEMS Accel: No, Accumulative tracking error...
Gyro: Sure, if you have Mega $ and a big power supply. Low cost gyros: No.
Mag Compass: No, see prior discussionof its limitations in this environment.
Optical: Perhaps, but not trivial to implement.
You ALREADY have high resolution wheel position encoders, which is exactly what is needed to give you your desired information. You use an accel curve for the wheels to START them turning, and to bring them up to speed. You do not have to always turn the wheels slowly!
This is a workable software solution and should work with the hardware you already have.
JC |
|
Back to top |
|
|
AdrianJ
Joined: 16 Jan 2006 Posts: 2483 Location: Queensland
|
Posted: Sun Jan 23, 2011 1:35 am Post subject: |
|
|
With a suitable lens assembly in front of an optical sensor, you can have any target distance you like.
I did this with a mouse sensor, but the application was for a target 3 metres away. It worked fine, although the project was dropped for other reasons.
With a target distance of a cm or so, it works for almost any surface, except maybe a mirror.
Maybe its possible also with the current crop of MEMS gyros for angles down to 1-3 degrees, but you still have to integrate them with wheel sensors as the stabilising element. AN177 in the Bascom App notes might be a starting point, although that is for an IMU with GPS and magnetometers for stabilisation.
Edit 23/01:
This link might also be of interest
http://www.surveyor.com/tmp/griffithsRAM2006.pdf _________________ Adrian Jansen
Computer language is a framework for creativity
Last edited by AdrianJ on Mon Jan 24, 2011 12:55 am; edited 1 time in total |
|
Back to top |
|
|
pseddon
Joined: 20 Oct 2006 Posts: 84
|
Posted: Sun Jan 23, 2011 11:25 am Post subject: |
|
|
I agree, but it is a great solution until the wheels slip for whatever reason. An absolute solution is what I think he is looking for.
This may be an inspiration http://www.diydrones.com/profiles/blog/show?id=705844:BlogPost:91683&commentId=705844:Comment:91733
http://www.diydrones.com/profiles/blogs/kicking-off-two-open-source
Peter
JC wrote: | Crazy,
I think you did not understand my answer, I will try again.
GPS: No, not for short range high precision tracking, and not for indoor usage.
MEMS Accel: No, Accumulative tracking error...
Gyro: Sure, if you have Mega $ and a big power supply. Low cost gyros: No.
Mag Compass: No, see prior discussionof its limitations in this environment.
Optical: Perhaps, but not trivial to implement.
You ALREADY have high resolution wheel position encoders, which is exactly what is needed to give you your desired information. You use an accel curve for the wheels to START them turning, and to bring them up to speed. You do not have to always turn the wheels slowly!
This is a workable software solution and should work with the hardware you already have.
JC |
|
|
Back to top |
|
|
CrazyIgels
Joined: 26 Oct 2007 Posts: 79
|
Posted: Tue Jan 25, 2011 9:33 pm Post subject: |
|
|
Thanks All.
I use SiliconSensing CRS03 Gyroscope
http://www.siliconsensing.com/CRS03
And i use next data processing sequence
1. robot stop. After robot stop - i enable power to gyro.
2. delay to gyro bootstraping
3. starting of ADC and getting raw data from gyro
4. filtering raw data from noise with "moving average"
5. out signal=rawsignal - zero offset
6. discrete integration
7. angle goes to engine control PID
8. after turning i switch gyro off.
Because tuning speed relatively big (something 90 deg per sec) i don't use "special magic" to compensate gyro drift.
All data processing realize in NI LabView as software and NI Single Board Rio as hardware.
Our team take decision not use AVR to this task because SingleBoard have better ADC on board and main control loop on all robot running on this board. |
|
Back to top |
|
|
AdrianJ
Joined: 16 Jan 2006 Posts: 2483 Location: Queensland
|
Posted: Tue Jan 25, 2011 11:42 pm Post subject: |
|
|
Good that you got it working with such a gyro. The STMicroelectronics gyros like the LPY510AL are at least a factor 10 better in temp stability and drift performance than those. A bit harder to mount though, in LGA packages, although breakout boards with the gyros already mounted are available. _________________ Adrian Jansen
Computer language is a framework for creativity |
|
Back to top |
|
|
rgbujan
Joined: 05 Jan 2005 Posts: 29
|
|
Back to top |
|
|
|