Go to Post Brandon Martus, making CD readers' lives easier since May 2001/Fall 98 - Beth Sweet [more]
Home
Go Back   Chief Delphi > Technical > Programming
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
  #9   Spotlight this post!  
Unread 13-04-2015, 12:26
raystubbs's Avatar
raystubbs raystubbs is offline
Programmer, Builder, Designer
FRC #2657 (Thundercats)
Team Role: Student
 
Join Date: Mar 2014
Rookie Year: 2012
Location: Deming NM
Posts: 121
raystubbs will become famous soon enough
Re: RoboDS Android 2015 Driverstation

Quote:
Originally Posted by gixxy View Post
As a developer for the Cross Platform DriverStation.js we too have been working to reverse engineer the 2015 protocol, not that we have made it too far...

What we DO have is here: https://github.com/gluxon/node-drive.../2015-Protocol
I don't have my notes with me right now but here is what comes after your general packet data, according to my memory:

The rest of the data is divided into joystick structures, each structure has the following:

1 byte: Size, in bytes, of the joystick structure
1 byte: Unknown, according to my memory it has always been 12, 0x0c in hex.
1 byte: 'a' the number of axis' available on the joystick.
'a' bytes: The values of each of the axis'.
1 byte: 'b' the number of buttons on the joystick.
'b'/8 rounded up, bytes: The state of every button, one per bit, button 1 is far right and button 'b' is far left.
3 bytes: Unknown, always seems to be 01-ff-ff.

The data for any other joysticks follows.

This may be slightly wrong, I do not have a perfect memory but I think this is mostly correct. If you want details or clarifications then contact me and I'll find my notes. If you find anything new with the 'Connection Packet' structure please let me know, thanks.
__________________
"If all else fails, read the instructions."
 


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:03.

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