WPILib Documentation

repository·main·Indexed 41 days ago

https://github.com/wpilibsuite/wpilib-docs

Technical guidance for FIRST Robotics Competition (FRC) and FIRST Tech Challenge (FTC) teams, including software installation, roboRIO configuration, and programming instructions. Includes specific resources for the 2025 Beta project, such as task progression for the Control System Beta Test, dependency management, and bug reporting workflows.

Tokens
221.5K
Snippets
459
Records
1.1K
Agent score
51%

What's inside WPILib

  1. Overview of Elastic dashboard capabilities

    main

    Elastic is a modern, drag-and-drop dashboard designed for competition driver use or testing. Key features include:

    • Data Visualization: View data from various NT4 topics and widgets.
    • Customizable UI: Draggable and resizable card widgets with over 20 color scheme variants.
    • Optimized Video: Camera streams that automatically deactivate when not in use to save bandwidth.
    • Network Integration: Automatic IP retrieval from the FRC Driver Station.
  2. Overview of Drivetrain Simulation in WPILib

    main

    WPILib provides a simulation framework designed to model the physical behavior of a robot's drivetrain. This allows developers to implement and test software before physical hardware is available.

    Key capabilities include:

    • Physical Modeling: Creating a drivetrain simulation model using your robot's specific physical parameters.
    • Predictive Testing: Using the model to predict how a real robot will move based on specific voltage inputs.
    • Software Verification: Tuning feedback constants (like PID) and identifying common bugs, such as incorrect motor or encoder inversions.
    • Advanced Validation: Verifying the accuracy of complex behaviors like path following.
    • Visualization: Using the Simulation GUI to visualize the robot's movement on a virtual field.

    Note: The simulation implementation is framework-agnostic; it can be used with both command-based and simple data-flow architectures.

  3. Overview of Commands v2 Programming

    main

    Commands v2 is the stable, production-ready command-based framework for WPILib, supporting Java, C++, and Python. It utilizes a declarative programming style, leveraging method chaining and lambda expressions to compose complex robot behaviors.

    Key benefits include:

    • Multi-language support: Native support for Java, C++, and Python.
    • Stability: Battle-tested for FRC robot applications.
    • Broad platform support: Compatible with roboRIO, simulation, and coprocessors.
  4. Getting Started with XRP

    main

    The XRP is a small, inexpensive robot designed for learning robot programming. It is compatible with the same tools used for programming full-sized FRC and FTC robots.

    Key hardware features include:

    • Two drive motors with integrated wheel encoders.
    • An IMU sensor for measuring headings and accelerations.

    Programming the XRP involves writing a robot program and running it on your computer, which then commands the robot to follow the defined steps.

  5. Overview of sensor software support in WPILib

    main
    WPILib provides built-in classes to interface with various sensors that provide environmental feedback to a robot. These sensors leverage the roboRIO's FPGA for accurate real-time measurement. This software overview covers how to use supported sensor types and how to write custom code for sensors that do not have official WPILib support.
  6. Introduction to the Java Units Library

    main

    The Java Units Library (package edu.wpi.first.units) is a tool designed to prevent measurement errors by tracking physical dimensions and ensuring compatible units are used in operations. It provides predefined units (meters, degrees, seconds, etc.), supports unit conversion, and allows for type-safe arithmetic and comparisons.

    Key concepts:

    • Dimension: The nature of a physical quantity (e.g., length, time, mass).
    • Unit: A specific realization of a dimension (e.g., meters, inches).
    • Measure: A specific magnitude expressed in a unit (e.g., 5 meters).
  7. Overview of Glass dashboard and visualization tool

    main

    Glass is a dashboard and robot data visualization tool designed for programmers. Its graphical user interface (GUI) is modeled after the Simulation GUI.

    Important Limitations:

    • It is currently intended as a programmer's tool rather than a production-ready dashboard for competition environments.
    • Glass is not available within the list of dashboards in the NI Driver Station.
  8. What is NetworkTables

    main

    NetworkTables is a publish-subscribe messaging system used to distribute data between different components of a robot system (e.g., the robot, driver station, or coprocessors).

    Values are published to named topics. When a value is written to a topic, it is automatically distributed to all clients subscribed to that topic. This allows for real-time data sharing, such as sending vision processing results from a laptop to a robot, or sending sensor data from a robot to a dashboard for plotting.

  9. Getting Started with Romi

    main

    The Romi is a small, inexpensive robot designed for learning FRC (FIRST Robotics Competition) robot programming. It uses the same software tools and programming paradigms as full-sized FRC or FTC robots.

    Key Hardware Features:

    • Two drive motors with integrated wheel encoders.
    • An integrated IMU (Inertial Measurement Unit) sensor for measuring heading and acceleration.

    Programming the Romi involves writing a robot program and running it on your computer, which then commands the robot to execute the programmed steps.

  10. Overview of Choreo for trajectory calculation

    main

    Choreo is a tool designed for calculating time-optimal autonomous trajectories. It simplifies the creation of autonomous routines by allowing users to generate paths with specific constraints and schedule commands at various events along those paths.

    Key capabilities include:

    • Creating trajectories using a variety of different constraints.
    • Scheduling commands at different events on your path.
    • Support for various drivebase configurations, including swerve and tank drivebases.

    For more in-depth information, refer to the official documentation at https://choreo.autos/.