![]() |
LIDAR-Lite Interfacing -- can't read distance
I'm having trouble getting the LIDAR-Lite interfaced to the roboRIO, and could use some input. My code is based on this Java class: https://gist.github.com/tech2077/c4ba2d344bdfcddd48d2.
For reference, here's the LIDAR-Lite manual: https://s3.amazonaws.com/cdn.freshde...lication%2Fpdf Power is supplied via one of the prior year KOP 25w 12v-5v regulators, and I've verified that there's 5v on the output. The red wire (pin 1) from the LIDAR-Lite is connected to the yellow (+5) wire and pin 6 is connected to the black (-) wire on the regulator. Pin 4 on the LIDAR-Lite (SCL) is connected to pin 32 on the MXP port, and pin 5 (SDA) is connected to pin 34. Here's some code snippets -- initialization (from the constructor): Code:
this->Lidar = new I2C(port, LIDAR_ADDR);Code:
void LIDARLite::ReadValue() {Code:
const int LIDAR_ADDR = 0x62; |
Re: LIDAR-Lite Interfacing -- can't read distance
We had issues as well. We ended up putting a pull-up resistor on the SCL pin. Here is our example:http://www.chiefdelphi.com/forums/sh...d.php?t=135043
It is Java, but the look will be similar. |
| All times are GMT -5. The time now is 08:02. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi