Subject:
|
Re: Ping mode for US Sensor in NXT-G
|
Newsgroups:
|
lugnet.robotics.nxt
|
Date:
|
Sun, 4 Mar 2007 13:53:40 GMT
|
Viewed:
|
17008 times
|
| |
| |
Hi Guy,
You inspired me to do a ping using NBC, but I have run into trouble. I get
a -35 (ERR_COMM_BUS_ERR) when I try to read more than one object reading.
The code is long, so I'll just put the basics of what I am doing here to see
if anyone notices anything wrong with the technique. I'm only reading
distances for two objects here.
- Write 0x02, 0x41, 0x01 to ping
- Read furthest away of the two objects first (0x02, 0x43)
- Read closest object last (0x02, 0x42)
If I just read one object distance (even if it's not the closest), it seems
to be OK. I've tried delaying from 10 ms to 1 sec between reads, but it
doesn't help.
I am using NBC's __ReadLSBytes to do the reads.
Do you have the disassembly for the NXT-G I2C read/write blocks?
David
|
|
Message has 1 Reply:
Message is in Reply To:
| | Ping mode for US Sensor in NXT-G
|
| I've written a detailed toturial on working in ping mode in NXT-G using I2C read/I2C write block and the US Sensor block. Read it here: (URL) shows how you can set the sensor to ping mode, read and display all 8 measurements and alternatly ping two (...) (18 years ago, 28-Feb-07, to lugnet.robotics.nxt)
|
5 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|