WPILib 2023.3.1 release - Do Not Use

EDIT: Do Not Update, we will make a 2023.3.2 patch release later today (2/5) due to an issue in this release with CTRE simulation.

This is an update release of WPILib for the 2023 season. Notable fixes in this release:

  • Several major NetworkTables bugs
  • ADXRS450 Gyros in C++

Significant new features in this release:

  • SysId CTRE CANivore and Phoenix Pro support

Upgrading from earlier 2023 releases is easy: simply download and run the new installer and it will update your current installation. If you already have the 2023 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. Note that using the installer is required to get the new version of desktop tools such as Shuffleboard.

The documentation for WPILib is located at https://docs.wpilib.org/ (if you have trouble accessing this location, FIRST Robotics Competition Control System — FIRST Robotics Competition documentation is an alternate location with the same content).

If you’re new to FRC, start with Getting Started.

WPILib is developed by a small team of volunteers and the FIRST community.

What’s Changed

WPILib

  • Load joystick values upon code initialization by ThadHouse
  • AprilTagFieldLayout: Improve API shape for loading builtin JSONs by brennenputh
  • Fix C++ ADXRS450 and Java SPI gyro defs by ThadHouse
  • Properly use control word that is in sync with DS data by ThadHouse
  • Add Timer::Restart() by srimanachanta

NetworkTables

  • Write empty persistent file if none found by PeterJohnson
  • Handle topicsonly followed by value subscribe by PeterJohnson
  • Special-case default timestamps by PeterJohnson
  • Use full handle when subscribing by PeterJohnson
  • Add client disconnect function by PeterJohnson
  • Don’t leak buffers in rare WS shutdown case by PeterJohnson
  • Change wire timeout to fixed 1 second by PeterJohnson
  • Report better connection close messages by PeterJohnson

Simulation

  • Fix MOI calculation error in SingleJointedArmSim by mcm001
  • Enable docking in the GUI by PeterJohnson
  • GUI: Fix buffer overflow in joystick axes copy by PeterJohnson
  • Check for null in getSimDeviceName JNI by PeterJohnson
  • Throw on nonexistent/invalid SimDevice name in SimDeviceSim constructor by rzblue

Math

  • HolonomicDriveController: Add getters for the controllers by OliverW10
  • Fix Pose3d exponential and clean up Pose3d logarithm by jlmcmchl
  • Workaround intellisense Eigen issue by PeterJohnson
  • Remove extraneous assignments from DiscretizeAB() by calcmogul
  • Make PIDController::Calculate(double, double) update setpoint flag by calcmogul
  • Add nearest to Pose2d and Translation2d by rzblue
  • Discard stale pose estimates by jlmcmchl

Examples

  • Add Computer Vision Pose Estimation and Latency Compensation Example by CarloWoolsey
  • Add comment to drivedistanceoffboard example by BerkeSinanYetkin
  • Fix swapped arguments in MecanumControllerCommand example by sciencewhiz
  • Update for AprilTag field load API usage by calcmogul
  • C++ RamseteCommand: Fix units by Starlight220
  • Hatchbots: Add telemetry by Starlight220
  • Improvements to Elevator Simulation Example by michaelleong25

Command-Based Framework

  • Fix C++ Select() factory by Starlight220

DataLogTool

  • Fix crash due to MemoryBuffer by PeterJohnson
  • Add msgpack to datalog example by truher

Glass

  • Add option for debug-level NT logging by PeterJohnson
  • Limit frame rate to 120 fps by default by PeterJohnson

Shuffleboard

  • Format integer arrays correctly by fovea1959
  • Support numbers in gyro widgets by SamCarlberg
  • Add all known topics on networktables client connect by lost1227
  • Use NetworkTable disconnect instead of stop by PeterJohnson

SysId

  • Upgrade vendordeps by calcmogul
  • Add CTRE CANivore and Phoenix Pro support by TytanRock

GradleRIO

  • Rename Sim DriverStation to be clearer about its purpose by PeterJohnson

VSCode

  • Add replacements for wpi/numbers and wpi/span by sciencewhiz
  • Change WPILib on status bar to open project information by ThadHouse
  • Re-enable standalone utility notarization by sciencewhiz
  • Upgrade vscode-java extension to 1.14.0 by PeterJohnson

Docs

  • [wpimath] Fix typo in Pose3d::Exp() docs by calcmogul
  • [wpimath] Update Wikipedia links for quaternion to Euler angle conversion by calcmogul
  • [wpilibj] Fix typo in MecanumDrive docs by calcmogul
  • [commands] Fix docs inconsistency for toggleOnFalse(Command) by Nyxiad
  • [wpilib] XboxController: Fix docs discrepancy by BruceMcRooster
  • Clarify DS functions provided by FMS by sciencewhiz
11 Likes

After the upgrade, opening the project in VSCode prompted for the version update which changed the version number in the build.gradle as expected:

    id "edu.wpi.first.GradleRIO" version "2023.3.1"

The project builds OK, but simulation now fails to initialize for Falcons:

********** Robot program starting **********
NT: Listening on NT3 port 1735, NT4 port 5810
[phoenix] CANbus Connected: sim
[phoenix] CANbus Network Up: sim
Error at com.ctre.phoenix.motorcontrol.can.WPI_TalonFX.<init>(WPI_TalonFX.java:122): Unhandled exception instantiating robot edu.wpi.first.wpilibj.simulation.SimDeviceSim java.lang.IllegalArgumentException: No sim device exists with name 'CANMotor:Talon FX'.
        at edu.wpi.first.wpilibj.simulation.SimDeviceSim.<init>(SimDeviceSim.java:29)
        at com.ctre.phoenix.motorcontrol.can.WPI_TalonFX.<init>(WPI_TalonFX.java:122)
        at com.ctre.phoenix.motorcontrol.can.WPI_TalonFX.<init>(WPI_TalonFX.java:170)

Does the WPILib update require a corresponding CTRE library update?

1 Like

Installed the most recent CTRE version 5.30.4, but get same error as previously used version 5.30.2: “No sim device exists with name ‘CANMotor:Talon FX’”

Maybe I shouldn’t have been storing credit card numbers in NT.

3 Likes

That’s an unexpected break. I’ll talk to the CTRE folks, but I’ll probably just do a quick patch release. The purpose of the change was that the SimDeviceSim object is useless if the corresponding SimDevice hasn’t been created, but maybe the CTRE code does something to make this work for them.

1 Like

Sorry all, don’t install this, wait for 2023.3.2 later today.

4 Likes

Thank you so much for quickly generating the patch release! All’s fine now with simulation. Also really enjoy the shuffleboard/NT fixes, no longer need to restart the board on every robot update (https://www.chiefdelphi.com/t/shuffleboard-needs-restart-after-robot-update)

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.