
Anybody interested in a cheap IMU?
#1
Posted 02 February 2011 - 01:40 AM
#2
Posted 02 February 2011 - 02:26 AM
Ahhh, raw board, raw board + parts, or finished board?Terrorgen (from TinyCLR) and I were going to make a few IMUs roughly based on the Sparkfun 9DoF Stick: http://www.sparkfun.com/products/10321
Our board would be close to the same as the Sparkfun board, except that we are planning to replace the old HMC5843 for the far less expensive, higher resolution, smaller HMC5883L.
We are also replacing the 0402 passive components in the reference design for 0603 for ease of assembly.
As it is set, Terrorgen will do the board assembly, but we might do something different depending on how many people want in.
We estimate each IMU will be between $30 and $40.
Anybody else want to get in on this?
This is a cross post from: http://www.tinyclr.c...31/#/1/msg23385
#3
Posted 02 February 2011 - 04:42 AM
#5
Posted 03 February 2011 - 05:35 AM
#6
Posted 03 February 2011 - 09:18 PM
#7
Posted 03 February 2011 - 10:35 PM
This small stick looks awesome! However I have two quick questions, apologies if they are too naive; I have a project in mind but have never used an IMU before:I'd take one as well, that was the board i was going to buy but didnt want the old magnetometer, polling via i2c works for my application
- Do I understand correctly that the stick has 3 sensors, no on-board MCU, and would deliver the 3x3 raw data without any form of compensation?
- If so the compensation would need to be performed by the Netduino MCU?
Thanks
#8
Posted 03 February 2011 - 10:48 PM
#9
Posted 03 February 2011 - 11:03 PM
Thanks Brandon, that was useful. One difference at least with the stick is that you don't need to parse serial data output, obtained at 38400 bauds, as the stick delivers the individual values via I2C; however by putting in balance the two terms, does this parse-time "compensate" (so to speak) the compensation code performed on the on-board MCU? I found the code below here; in other words what would we lose by executing the below in C# on our 48MHz ARM7, rather than in native C on the on-board 8MHz ATMega?Chris will be able to answer better, but yes from what i understand there would be no compensation and no mcu.
from the razor one here's an implementation by zerov https://code.google..../QuadroLib/Ahrs which might give you an idea of the data coming down
void Compass_Heading() { float MAG_X; float MAG_Y; float cos_roll; float sin_roll; float cos_pitch; float sin_pitch; cos_roll = cos(roll); sin_roll = sin(roll); cos_pitch = cos(pitch); sin_pitch = sin(pitch); // Tilt compensated Magnetic filed X: MAG_X = magnetom_x*cos_pitch+magnetom_y*sin_roll*sin_pitch+magnetom_z*cos_roll*sin_pitch; // Tilt compensated Magnetic filed Y: MAG_Y = magnetom_y*cos_roll-magnetom_z*sin_roll; // Magnetic Heading MAG_Heading = atan2(-1*MAG_Y,MAG_X); }
#10
Posted 03 February 2011 - 11:42 PM
#11
Posted 04 February 2011 - 01:51 AM
#12
Posted 04 February 2011 - 01:52 AM
#13
Posted 06 February 2011 - 06:28 PM
#14
Posted 08 February 2011 - 06:01 AM
#15
Posted 08 February 2011 - 09:32 AM
My own take:
- Yes, it should be user-programmable, and a DSPIC is fine
- SPI is faster; watch out with I2C if the on-board MCU needs to be a master too, which I'd assume to be the case. Apparently Netduino does not support I2C multimaster mode; though I don't know the multimaster equivalent to SPI. Or preferably the IMU would be seen as one unique device , whether SPI or I2C (slave in both cases), masking the on-board sensors? I'm fine with this option too, as the firmware can always passthrough the individual, raw, sensors values without compensation, if needed
- How about PWM output pins, that may be used for driving motors or servos
JP
#16
Posted 08 February 2011 - 02:34 PM

#17
Posted 08 February 2011 - 03:11 PM
You can put me in given these requirements. We have made some progress since the first post!Are are leaning towards a lean pinout mode, so I'm not sure any additional headers would be appropriate...
I was mainly thinking about just having a strip of digital headrs that could be bit-banged to whatever protocol the user wanted to use. UART? No problem. I2C? No problem. SPI? No problem.
The firmware will be user reloadable, or at least I need it to be to develop it. Well have an ICSP PICKIT header on it.
The headers will definitely be standard to breadboard and such. If it's one thing that I _hate_ it's stupid electromechanical connection schemes like the one the Ublox GS507 uses. Proprietary, single mat connector that can't even hold it's own weight without breaking? No thanks...![]()
As for sensor masking, the MCU would be used to cross compensate the sensors into pitch/roll/yaw angles which would be available from the chosen comms bus. I think it only makes sensor to also include registers for all the of the raw sensor values, as well as any extras like temperature that sensors may have. ( I haven't looked to see what extra values are available in the datasheets, so no promises yet...)
#18
Posted 08 February 2011 - 03:16 PM
#19
Posted 08 February 2011 - 05:57 PM

#20
Posted 08 February 2011 - 07:06 PM
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users