I don't own this device, Tiago does. So that would mean that I was wrong in my post on the ROBOTC forums, although it worked fine for Elizabeth. I am not sure what you'd like me to say, though. If I had one of these I would gladly test it, however, I don't so, so there's no way for me to tell why this thing isn't working.
- Xander
NXC - Reading temperature from TPA81
Re: NXC - Reading temperature from TPA81
| 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: NXC - Reading temperature from TPA81
LOL, Xander is mightor...afanofosc wrote:The comment at the start of i2c_scanner.c says
Some guy name Xander on another site said this device requires pull-up resistors
http://www.robotc.net/forums/viewtopic. ... 203#p12203
That seems to contradict what was said above.
Yes, I know that, but that sensor was brought from my store ( nxt4you.com ) and I've sent cables (without resistors) to her.
When we met on Istambul (on Robocup2011) her team won USA qualifications, using those sensors on NXT with RobotC.
Tiago Caldeira
www.nxt4you.com
RobocupJunior Rescue TC for 2012
RobocupJunior Rescue OC Co-Chair for Mexico2012
www.nxt4you.com
RobocupJunior Rescue TC for 2012
RobocupJunior Rescue OC Co-Chair for Mexico2012
Re: NXC - Reading temperature from TPA81
All of what you say strongly implies that he's got his wires crossed. Did you guys look at how he has the circuit connected in his picture? If it works when it is wired correctly with picaxe then it absolutely should work without problems with the standard or enhanced NBC/NXC firmware using NXC. If he is getting a bus error then almost certainly his circuit is wrong.
Does his wiring look right or not? I haven't seen either of you answer that question in this thread. If it looks right and he is still getting a bus error, what hardware changes should he try to fix that? I.e., what are the most likely non-obvious hardware problems that could cause an I2C device to have a bus error? What would you try changing when hooking a custom I2C device to your NXT if it doesn't work as it ought to with your programming language of choice?
John Hansen
Does his wiring look right or not? I haven't seen either of you answer that question in this thread. If it looks right and he is still getting a bus error, what hardware changes should he try to fix that? I.e., what are the most likely non-obvious hardware problems that could cause an I2C device to have a bus error? What would you try changing when hooking a custom I2C device to your NXT if it doesn't work as it ought to with your programming language of choice?
John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
http://bricxcc.sourceforge.net/
-
- Posts: 10
- Joined: 21 Oct 2011, 15:25
Re: NXC - Reading temperature from TPA81
Hello again! So, after a week or so I am back ( I had exams and I really needed to study ) and I can see docilio already has the TPA81 working.
I just checked my circuit using this table in this blog: http://www.stewartallen.org/2010/08/des ... t-sensors/ and it seems everything is properly connected. However, I will download robot-c tomorrow and try to run docilio's code. I will post the results as fast as I can.
I just checked my circuit using this table in this blog: http://www.stewartallen.org/2010/08/des ... t-sensors/ and it seems everything is properly connected. However, I will download robot-c tomorrow and try to run docilio's code. I will post the results as fast as I can.
Re: NXC - Reading temperature from TPA81
I cannot think of any reason why your circuit could possibly work with RobotC if it does not work with the standard NXT firmware and/or the enhanced NBC/NXC firmware with NXT-G or NXC. If it works with RobotC it is guaranteed to work with NXC. If it doesn't work with NXC it isn't going to work with RobotC either.
I highly recommend that you read Sivan Toledo's I2C tutorial.
http://www.tau.ac.il/~stoledo/lego/i2c-8574/
He writes:
John Hansen
I highly recommend that you read Sivan Toledo's I2C tutorial.
http://www.tau.ac.il/~stoledo/lego/i2c-8574/
He writes:
Code: Select all
After I wired the circuit and wrote the program to toggle the LEDs, I ran it and nothing happened. So I added code to display the error codes from the system calls, and discovered that the firmware was reporting error -35, a bus error, which can indicate a device failure. I started to check voltages in the circuit with a voltmeter, and eventually discovered that the chip was not getting the full supply voltage. I looked at it carefully and discovered that I didn't push it all the way into the breadboard.
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
http://bricxcc.sourceforge.net/
Who is online
Users browsing this forum: Semrush [Bot] and 1 guest