|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Re: BEI Gyro Accuracy
I found a way to compensate for the non linearity of the gyro but, the problem is that the gyro isn't consistent. I will turn it 90 degrees on way, then back to the starting position and it will read 0. But then when reset the system and try the same test it will be off by about 20 degrees. I then reset the system again, and its off by 5 degrees, and then without event reseting the system I turn it 90 degrees and it only changes the position by about 15 degrees, i turn it back to the starting position and it goes -90 degrees from where it was at.
I see absolutely no consistency in this device. It will work fine, but then when the controller is reset it will work totally difference. I have scaling factors in to change the readings so they are equal from one direction to another, but that only solves the linearity problem. I have figured there is something wrong with it this whole time simply because the neutral voltage is 2.1 volts. That just seems too far from the spec'ed 2.5 volts to be acceptable. -John |
|
#2
|
||||
|
||||
|
Re: BEI Gyro Accuracy
Quote:
BTW, is there a chance you can share your scaling code to compensate for the non-linearity. For some reason, mine doesn't seem to work. |
|
#3
|
||||
|
||||
|
Re: BEI Gyro Accuracy
Well, my code, ( I am at work now ), is simply a scaling factor. as far as linearity I was talking about from positive to negative, so crossing the neutral value it was non linear, so -90 degrees/sec for 1 sec wouldn't read the same as 90 degrees/see for 1 sec.
I will post it later tonight. -John |
|
#4
|
||||
|
||||
|
Re: BEI Gyro Accuracy
As an update: Mostly to you billbo911
I realized I had no "base" code to even drive the bot around, so I decided to work on that first. I am doing the 2 drive motors off of the 16 bit Timer1. Timer0 I decided to make an "event" timer. This way I can say do this after x seconds, or whatever and it will be very easy to do. The resolution is .01 seconds, which should be fine for my needs. The accuracy should be 0.0128% assuming the internal clock has 0% error (pffft! yea right!) and not counting any latency. But this should all be fine for this application. I wrote some simple motor functions to stop, both, stop individually, and set the speeds either together or individually. I mounted my bread board to the top of the bot, it is a very nice set-up now. The only problem I am having is that with how the motors are on there, one is turning CW while the other is turning CCW to go forward. So it curves. To solve this, I think I am gonna try to somehow mount the motors both facing the same direction. This should solve the problem. I can share the plans of the bot and my code if you would like. I assume you can almost just use it with little to no modification from what I have. -John |
|
#5
|
||||
|
||||
|
Re: BEI Gyro Accuracy
Quote:
My ultimate goal is to use the Arduino, or some other variant of the ATMega chips, to build a single board to both read in two+ quadrature encoders and a gyro and be able to provide distance and orientation from a single serial stream. I might use I2C but I will definitely have a simple RX/TX source. BTW, as a test, I have removed the guts from a ball mouse and will be using this as a source for a test set of Quadrature encoders. Hey, it was cheap at $5 for a pair of quad's. Now I just need to interface them mechanically. ![]() |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| BEI Gyro | John Gutmann | Electrical | 3 | 18-06-2008 17:36 |
| Weapon Accuracy? | scitobor 617 | Programming | 15 | 12-02-2006 22:16 |
| servo output accuracy | NextPerception | Programming | 9 | 07-02-2006 11:23 |
| BEI GyroChip Problems | Andrew Blair | Programming | 12 | 07-12-2005 18:02 |
| BEI Gyrochip | CyberWolf_22 | Electrical | 3 | 15-01-2005 16:27 |