View Single Post
  #5   Spotlight this post!  
Unread 22-10-2012, 18:59
fishythefish fishythefish is offline
Programmer
FRC #1504 (The Desperate Penguins)
Team Role: Programmer
 
Join Date: Jan 2012
Rookie Year: 2010
Location: Okemos, MI
Posts: 2
fishythefish is an unknown quantity at this point
Re: CAN Protocol/Missing .java and .class files

@joelg236: Those are the same files I have in the SDK. I just noticed that if you look at what they import, many of them end up importing from a class/classes in com.sun that do not appear in the SDK and are not included by default. I was just wondering where the sources for those were located. (Presumably, they're located in one of the compiled libraries.)

@Joe: Yeah, we discovered that FIRST hides the communication protocol. We're considering reverse engineering it as an alternative to what I'm trying to do right now.

I discovered that instead of trying to reconstruct the relevant classes, there is a suite directory containing a JAR that I could add to classpath. That library contains the same files that Joel and I have, but everything is functional.

To clarify what we're trying to do with the Arduino: We're not running anything on the Arduino itself. The idea was that we could possibly replace the cRIO with a combination of a laptop running the code and an Arduino on the robot passing the output to the relevant devices.

Current status: After adding the suite JAR file to the classpath of a vanilla Java project, I can import the CANJaguar class, create a CANJaguar variable, initialize it, and set its speed without any compiler errors. I'm just having trouble instantiating it at runtime, since I'm trying to communicate over USB-to-Serial, and that requires something in addition to the usual
CANJaguar jaguar = new CANJaguar(2);
Reply With Quote