Some questions about making my own digital sensor
Some questions about making my own digital sensor
Hi,
I found this digital sensor at Sparkfun that combines a three axis gyro and a three axis accelerometer. I would like to use this sensor with my NXT but do lack any experience with sensor building. I got some beginner questions.
- The sensor needs 3.3V (3.6Max), the NXT sensor port supplies 4.3V. This is too much so I need to get the voltage down. I read about voltage regulators, but they need about 1.5V overhead, giving 4.8V as minimum for input. This is more than the NXT supplies. So how do I provide the sensor with some clean voltage?
- The sensor implements high speed I2C, 400 kb/s. Will it run on the NXT that only has 9600 b/s?
- Provided I have some suitable power for the NXT, can I just connect the digital pins of the NXT with those of the sensor, or do I need some extra components between the two?
I found this digital sensor at Sparkfun that combines a three axis gyro and a three axis accelerometer. I would like to use this sensor with my NXT but do lack any experience with sensor building. I got some beginner questions.
- The sensor needs 3.3V (3.6Max), the NXT sensor port supplies 4.3V. This is too much so I need to get the voltage down. I read about voltage regulators, but they need about 1.5V overhead, giving 4.8V as minimum for input. This is more than the NXT supplies. So how do I provide the sensor with some clean voltage?
- The sensor implements high speed I2C, 400 kb/s. Will it run on the NXT that only has 9600 b/s?
- Provided I have some suitable power for the NXT, can I just connect the digital pins of the NXT with those of the sensor, or do I need some extra components between the two?
My blog: nxttime.wordpress.com
Re: Some questions about making my own digital sensor
You can use an LDO (Low Drop Out) regulator that will only require around 0.6V overhead. I used the LM3940 in a previous project.aswin0 wrote:- The sensor needs 3.3V (3.6Max), the NXT sensor port supplies 4.3V. This is too much so I need to get the voltage down. I read about voltage regulators, but they need about 1.5V overhead, giving 4.8V as minimum for input. This is more than the NXT supplies. So how do I provide the sensor with some clean voltage?
That should be fine If you are using ROBOTC, your I2C clock speed will be about 30KHz instead of 9600.- The sensor implements high speed I2C, 400 kb/s. Will it run on the NXT that only has 9600 b/s?
Get one of these: http://www.sparkfun.com/products/8745 They're logic level shifters and work very nicely.- Provided I have some suitable power for the NXT, can I just connect the digital pins of the NXT with those of the sensor, or do I need some extra components between the two?
- 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: Some questions about making my own digital sensor
Xander,
Tanks.
Tanks.
Do you mean to say that the NXT uses 5V for I2C and the sensor 3.3V?mightor wrote:Get one of these: http://www.sparkfun.com/products/8745 They're logic level shifters and work very nicely.- Provided I have some suitable power for the NXT, can I just connect the digital pins of the NXT with those of the sensor, or do I need some extra components between the two?
My blog: nxttime.wordpress.com
-
- Posts: 323
- Joined: 29 Sep 2010, 05:03
Re: Some questions about making my own digital sensor
Will the level shifter also "hide" the pull ups on that board? If not they may give some problems as they have a much lower resistance then the values recommended by Lego...
Re: Some questions about making my own digital sensor
You put normal pull-ups (10k) on the 3V3 side and 82K on the NXT side. At least I think that's how I did it. Otherwise leave the ones on the 3V3 side and see how that works. I've used those logic level shifters before but it's been a long time and I didn't make drawings or photos.
- 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: Some questions about making my own digital sensor
Don't the data lines run at 3.3V logic? Or am I mistaken? I do remember that somebody on the NXTasy forums said that when interfacing with 3.3V sensors you could just substitute a 47K pullup for the 82K and connect the data lines directly. Maybe I'm mis-remembering something...
One King to rule them all, One King to find them,
One King to bring them all and in the darkness bind them
On Earth where Shadows lie.
One King to bring them all and in the darkness bind them
On Earth where Shadows lie.
Re: Some questions about making my own digital sensor
No, you are not misremembering, it is possible.
- 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: Some questions about making my own digital sensor
I looked in the hardware schematic and found the part that deals with the data lines. See the image below, don't forget to scroll down. Does this mean they run at 3.3V? (The fact that I can read a schematic does not mean I can understand it )nxtreme wrote:Don't the data lines run at 3.3V logic? Or am I mistaken? I do remember that somebody on the NXTasy forums said that when interfacing with 3.3V sensors you could just substitute a 47K pullup for the 82K and connect the data lines directly. Maybe I'm mis-remembering something...
My blog: nxttime.wordpress.com
Re: Some questions about making my own digital sensor
So really, aswin wouldn't really need the logic level shifters, right? I like to keep designs as simple as possible, maybe its showing now . Sparkfun also just released a new 9DOF "sensor stick". It's quite expensive but I'm thinking it'd be rather fun to plop it on a NXT and take to an amusement park.
-EDIT- You can also click on the picture to make it expand to it's full dimensions... and thanks for the picture, aswin! I have looked at the HDK before but it always seems to vanish when I do hard drive spring cleaning. Note to self: download HDK again .
-EDIT- You can also click on the picture to make it expand to it's full dimensions... and thanks for the picture, aswin! I have looked at the HDK before but it always seems to vanish when I do hard drive spring cleaning. Note to self: download HDK again .
One King to rule them all, One King to find them,
One King to bring them all and in the darkness bind them
On Earth where Shadows lie.
One King to bring them all and in the darkness bind them
On Earth where Shadows lie.
Re: Some questions about making my own digital sensor
OK. Lets go back to the overall design.
I need the sensor, and some circuit that provides 3.3V. That's all, right?
To get 3.3V I need a LDO voltage regulator and 2 capacitors (i.e. LD-1117 + 100nF + 10muF). That's all, right?
What about pull ups, do I need those?
I need the sensor, and some circuit that provides 3.3V. That's all, right?
To get 3.3V I need a LDO voltage regulator and 2 capacitors (i.e. LD-1117 + 100nF + 10muF). That's all, right?
What about pull ups, do I need those?
I've been looking at that one as well. It has a 3D compass, 3D gyro and 3D accelerometer. But it is rather big. That is why I choose the IMU, this lacks the compass but has the same gyro and accelerometer. I hope to fit it in an sound sensor housing.nxtreme wrote:Sparkfun also just released a new 9DOF "sensor stick". It's quite expensive but I'm thinking it'd be rather fun to plop it on a NXT and take to an amusement park.
My blog: nxttime.wordpress.com
Who is online
Users browsing this forum: No registered users and 0 guests