2022 Update Release 2 of WPILib
This is the second update release of WPILib for the 2022 season. This release tracks to RoboRIO image v4.0, which fixes the Analog Devices SPI gyros issue and is required per Team Update 8. Download links and additional information are available at https://github.com/wpilibsuite/allwpilib/releases/tag/v2022.3.1.
Important: Reimaging the RoboRIO to 2022_v4.0 is required to use this release; this is installed by National Instruments FRC Game Tools 2022 f1 (note the "f1" in the version number). After installing 2022 f1, use the RoboRIO Imaging Tool to reimage your RoboRIO to 2022_v4.0. This release will not work with earlier 2022 RoboRIO images and will error out if a deploy is attempted to an earlier version; similarly, older versions of WPILib will not work with the v4.0 image.
Upgrading WPILib from earlier 2022 releases is easy: simply download and run the new installer and it will update your current installation. If you already have the 2022 WPILib vscode installed, it will detect it and you can simply click "next" for that installation step. After installation, vscode will prompt you when opening your robot project whether you want to upgrade it to this version.
The documentation for WPILib is located at https://docs.wpilib.org/ (if you have trouble accessing this location, https://frcdocs.wpi.edu/en/stable/ is an alternate location with the same content).
If you're new to FRC, start with Getting Started.
If you're returning from a previous season, check out what's new for 2022; be sure to read through this, as a lot has changed from 2021! You will need a new RoboRIO image for 2022; this is available via the FRC Game Tools. Follow the WPILib installation guide to install WPILib.
If you're starting from a 2020 or 2021 robot project, you will need to import your project to create a 2022 project. The import process is particularly important for 2022, as it will make a number of automated corrections for the various breaking package moves/renames that happened in 2022.
A complete list of known issues with this release can be found here. In particular, there is a warning against using the "onboard" I2C port (the MXP I2C port does not have an issue). Also, while overall AD gyro support has been fixed, there is a bug in this release in the ADIS16448 Java implementation's no-args constructor: to work around this, use ADIS16448_IMU(ADIS16448_IMU.IMUAxis.kZ, SPI.Port.kMXP, ADIS16448_IMU.CalibrationTime._1s);
instead of the no-args constructor.
WPILib is developed by a small team of volunteers and the FIRST community.