New to Windriver/C++

This is my first year doing the FRC, and I’m helping program our robot. Experience-wise, I’ve used C for the past 3 years, and I haven’t used C++ very much. Right now, I’m working on trying to get input from out Logitech Attack3 joystick, however, I’m semi-confused on… Everything. Is there any documentation for windriver that’s FRC related? Anything I can read that can explain a little more in-depth? I’ve found a couple resources online, nothing meaty though.

I’d recommend you first read through this website:

It’s a comprehensive tutorial that covers most of the details on how to deploy code to the robot, set up your development environment, and some details on how the WPILib library works. It actually combines several documents that used to be in separate pdfs last year.

However, it doesn’t give you the actual API, which is a tad bit inconvenient. You can find that on your computer by going to:


…and looking through the files there. You probably want to look at the “GettingStartedWithC.pdf” and “WPI Robotics Library User’s Guide” (although some of the information may be repeats of what you read in the website linked above).

The actual API can be found in the “WPILib C++ Reference.chm” file. There’s a chance it might not display anything correctly if you open it. If so, right-click, hit properties, and look around a bit until you see something like “unblock”. You can ignore a lot of the classes you see there for now. Initially, you probably want to look at the ‘RobotDrive’ class to actually drive the robot, the ‘Joystick’ class for input, and the ‘Jaguar/Victor/Talon/SpeedController’ classes to control various motors.

I’d also recommend you study up on object-oriented programming a bit. While you can use WPILib in a procedural manner, it’s really meant to be an OOP library. Since you came from C, you might find that a bit foreign at first, but the examples FIRST provides makes it fairly easy to learn as you go.

I’d also recommend you study up a little on electronics. I guess it’s not strictly needed to program the robot, but I personally found it really useful since it let me know what was actually going on with my code (plus, a lot of the mistakes I first made when I first joined FRC were a combination of programming and wiring errors, so knowing some electronics makes debugging a less frustrating experience).

The kit of parts section of is really useful.

It has links to a whole bunch of resources (not necessarily programming-related).

Finally, you could try looking through this website. Nearly all the FRC-related software lives there, so you might be able to find some documentation there.

Check out the “WPILib Users Guide” on the WPILib project on FIRSTForge. In addition look at the sample programs for some ideas. And lastly, you might want to look at the “Getting Started with C++” document here:

If you still can’t find what you’re looking for go ahead and repost here.

Just to tack on some extra info, here’s a link to my github project from last year:

Hopefully it can provide a decent reference.
There are also some helpful examples in windriver (instructions are in the documentation listed above I think), but I would suggest using IterativeRobot instead of SimpleRobot as a base class.

Good luck, I was in your situation 1 year ago :slight_smile: