Unit 5: Basic FRC Coding
Before you can write code, you need to set up your tools. A development environment is the collection of software you'll use to write, test, and deploy code to the robot. For FRC, this environment is specifically designed to make programming your robot as smooth as possible.
The FRC development environment has a few key parts that work together. The great news is that the official FRC WPILib installer bundles almost everything you need.
This is your Integrated Development Environment (IDE), or code editor. You'll spend most of your time here, writing and organizing your Java files. With the special FRC plugin, IntelliJ can create, build, and deploy robot projects.
Since we're writing code in Java, we need the JDK. It acts as the compiler that translates your human-readable Java code into bytecode that the roboRIO (the robot's main computer) can understand and execute.
This is a separate suite of programs that runs on your driver station laptop. It includes:
While some teams use VS Code, our team uses IntelliJ. Here’s how you get it ready for FRC development.
// Step 1: Install IntelliJ IDEA Community Edition (it's free!)
// Step 2: Install the FRC Plugin
// - Open IntelliJ and go to File > Settings > Plugins.
// - Go to the 'Marketplace' tab and search for "FRC".
// - Install the plugin and restart IntelliJ.
// Step 3: Create a New FRC Project
// - Go to File > New > Project...
// - Select 'FRC' from the project types on the left.
// - Follow the wizard to choose a project template (like 'Command Robot'),
// set your team number, and name your project.
// Step 4: Configure the JDK
// - The WPILib installer places the correct JDK in a public folder.
// - In your project settings, you may need to point IntelliJ to this
// specific JDK if it isn't found automatically.
Question: Which FRC Game Tool is used to enable and disable the robot during a match and view real-time log messages?