Go to Post I can't help but notice during the building sequence, there were a whole lot of student hands working on that robot. Just sayin'. - Taylor [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 15-01-2017, 15:29
godkane godkane is offline
Registered User
FRC #3875
 
Join Date: Jan 2014
Location: Grand Rapids, MI
Posts: 12
godkane is an unknown quantity at this point
RPLIDAR with java

I'm having issues getting the RPLILDAR v2 working with the default serial driver in java with the RoboRIO. I have no issues communicating when connected to a PC with my own C# code or provided C libraries.

Here is the webpage with the lidar including SDK documentation and code:
http://www.robotshop.com/en/rplidar-...r-scanner.html

Here is a simple command to have the LIDAR spin.
SerialPort sp = new SerialPort(115200, SerialPort.Port.kUSB1, 8, Parity.kNone);
byte[] b = new byte[5];
b[0] = (byte)0xa5;
b[1] = (byte)0xf0;
b[2] = (byte)0x90;
b[3] = (byte)0x01;
b[4] = (byte)0xc5;
sp.write(b, b.length);
sp.flush();

I do seem to be able to get basic health commands to work, just the more advanced commands such as spin and get reading do not work.

I have also connected V5 power to the power connector on the RPLidar board.

Any help would be appreciated.
Reply With Quote
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 21:34.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi