FRC-Utilities / QDriverStation

Cross-platform clone of the FRC Driver Station

Home Page:https://frc-utilities.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for ROS protocol

alex-spataru opened this issue · comments

@BearzRobotics suggested me to add support for the ROS some time ago. Now that I have a little more free time, I would like to begin working on that, since this could be useful for people outside FRC. I think that adding support for ROS is critical for the survival of this project, since it would attract more developers and therefore, it may help keep this project alive (and hopefully attract more people into FRC).

I have reviewed some information about ROS, however, I am still not familiar with it. So it may take some time for me to actually write something useful without your help.

Taking that into account, I would welcome any information/projects/code/comments regarding ROS. If required, we could draft a new protocol here and then begin working on the implementation.

Coincidentally, I recently started learning ROS myself and am working on a robot that uses it (based on an iRobot Create).

As far as implementing the protocol, I would suggest linking against the roscpp library and running the driver station as a ROS node. Then you could publish sensor_msgs/Joy messages for the connected joysticks. AFAIK, ROS doesn't have any standard way to represent modes (teleop, auto, etc.) or enable/disable states, but you could simply publish them so that people can implement them accordingly in their own nodes.

For teleop control of my robot, I use joy and teleop_twist_joy, which might give you some idea of how the system works.

I'll try to help if you have any questions.

@lopsided98 Thanks for the links! If so, we could draft our own way to represent control modes, enabled states & other information.