Hi, I am an Electrical Engineering Student, in the Autonomous Systems course, and I had to develop an Extended Kalman Filter for attitude estimation.
After the Filter development, I had to take measurements from the following sensor:
http://www.sparkfun.com/products/10183
using the NXT brick. Unfortunately i can't communicate with the sensor since i keep getting errors like:
error message 221: "Communication bus error"
and
error message 32: "Pending Communication transaction in progress"
We can get the measurements from the NXT sensors.
Does anyone have an idea of what can be done to take measurements, using I2C interface with Matlab, from this kind of sensor?
Thanks for your help,
Regards
RS
IMU Sensor SEN-10183 I2C NXT
Re: IMU Sensor SEN-10183 I2C NXT
The pull-ups may not be sufficient, they're only 4.7K and the NXT likes them around 83K for 5V and around 47K for 3V3.
- Xander
- Xander
| My Blog: I'd Rather Be Building Robots (http://botbench.com)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
Re: IMU Sensor SEN-10183 I2C NXT
First thank you for your reply,
We already tried a pull-up with 82k resistors for 5V, since we found that info somewhere in this forum...
Can you identify any other possible problem?
Thank you again,
RS
We already tried a pull-up with 82k resistors for 5V, since we found that info somewhere in this forum...
Can you identify any other possible problem?
Thank you again,
RS
Re: IMU Sensor SEN-10183 I2C NXT
Your IMU runs on 3V3, judging from the schematics on the product page. So why are you pulling up to 5V when a 47K to 3V3 will do fine. You may need a level converter like this one: http://www.sparkfun.com/products/8745
Also, don't cross post to multiple sub forums. I will delete the other one and move this thread.
- Xander
Also, don't cross post to multiple sub forums. I will delete the other one and move this thread.
- Xander
| My Blog: I'd Rather Be Building Robots (http://botbench.com)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
-
- Posts: 1818
- Joined: 02 Oct 2010, 02:19
- Location: Michigan USA
- Contact:
Re: IMU Sensor SEN-10183 I2C NXT
Quick answer: expect it to be the hardest sensor you'll ever interface with the NXT (and hopefully it wont be too bad)!
Take a look at this topic for a more complete answer
I don't know what all you tried, or are capable of, but read through that topic for more info. I think the gyro and accel are the same for both IMUs, so expect the same issues.
Once you finish reading that topic (which explains some things), then click on the spoiler:Once you get the electrical right, and are able to communicate properly with the accelerometer and gyro, then it looks like communication with the magnetometer should be fairly straight forward.
Basically, make sure none of the pins on the IMU ever come in contact with a voltage >3.3v.
I also recommend you use a programming language that supports custom I2C calls. I don't know what all Matlab supports, but with a HW hack, you need to be reasonably sure that the SW isn't to blame for a lack of functionality (so you can focus on HW errors). I suggest you use NXC, as many people on these forums use it. ROBOTC is good as well, but not free (also not really supported here). If you are comfortable with Matlab, and confident with low level I2C (at a byte level), then I'd say give it a go.
Take a look at this topic for a more complete answer
I don't know what all you tried, or are capable of, but read through that topic for more info. I think the gyro and accel are the same for both IMUs, so expect the same issues.
Once you finish reading that topic (which explains some things), then click on the spoiler:
Basically, make sure none of the pins on the IMU ever come in contact with a voltage >3.3v.
I also recommend you use a programming language that supports custom I2C calls. I don't know what all Matlab supports, but with a HW hack, you need to be reasonably sure that the SW isn't to blame for a lack of functionality (so you can focus on HW errors). I suggest you use NXC, as many people on these forums use it. ROBOTC is good as well, but not free (also not really supported here). If you are comfortable with Matlab, and confident with low level I2C (at a byte level), then I'd say give it a go.
Matt
http://mattallen37.wordpress.com/
I'm all for gun control... that's why I use both hands when shooting
http://mattallen37.wordpress.com/
I'm all for gun control... that's why I use both hands when shooting
Re: IMU Sensor SEN-10183 I2C NXT
Well, that's not really true. As long as I'm still around on these forums, it'll be supported. Don't forget about some of the other ROBOTC power users on these forums, there's quite a few of them However, there /is/ a ROBOTC specific forum, which you can find here: http://www.robotc.net/forums/.ROBOTC is good as well, but not free (also not really supported here)
These forums are language-agnostic, just as long as the subject is vaguely Mindstorms-related.
- Xander
| My Blog: I'd Rather Be Building Robots (http://botbench.com)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
| RobotC 3rd Party Driver Suite: (http://rdpartyrobotcdr.sourceforge.net)
| Some people, when confronted with a problem, think, "I know, I'll use threads,"
| and then two they hav erpoblesms. (@nedbat)
-
- Posts: 1818
- Joined: 02 Oct 2010, 02:19
- Location: Michigan USA
- Contact:
Re: IMU Sensor SEN-10183 I2C NXT
Oh, I know. I just meant that NXC is by far the most used on these forums (compared to ROBOTC), and more people here seem to use NXC than ROBOTC.
Matt
http://mattallen37.wordpress.com/
I'm all for gun control... that's why I use both hands when shooting
http://mattallen37.wordpress.com/
I'm all for gun control... that's why I use both hands when shooting
Re: IMU Sensor SEN-10183 I2C NXT
I do not want to change this topic into a "what is the best environment" flame war. But in this case I would go for Lejos. It does have support for working with matrices, which is invaluable when doing Kalman filters.
I do have robotC and Lejos drivers for all three sensors on this board.
Do you have any documentation of the Kalman filter you designed? I am very curious to the state you modeled.
I do have robotC and Lejos drivers for all three sensors on this board.
Do you have any documentation of the Kalman filter you designed? I am very curious to the state you modeled.
My blog: nxttime.wordpress.com
Who is online
Users browsing this forum: Semrush [Bot] and 1 guest