Skip to content

Releases: NRG948/nrgcommon

v2026.2.4 Release

05 Mar 02:56
77fb678

Choose a tag to compare

New features

Elastic Dashboard Annotations

This release adds annotations for defining dashboard elements and data bindings in a robotics program. A companion annotation processor provides compile-time generation of an Elastic dashboard configuration and data binding code based on annotated classes, fields and methods.

See Package com.nrg948.common.dashboard for details.

Breaking changes

Preferences Support

The previous annotation-based approach to preference management is now replaced with PreferenceValue-derived objects that can be targets of the dashboard annotations for data binding.

The previous RobotPreferencesValue hierarchy has been replaced by new objects. The following table maps the old objects to new objects. The parameters remain the same, but dashboard UI integration is handled through the new dashboard annotations. Any widget with a bi-directional binding can be used to target a corresponding preference value.

Old Type New Type
RobotPreferences.BooleanValue BooleanPreference
RobotPreferences.DoubleValue DoublePreference
RobotPreferences.EnumValue<E> EnumPreference<E>
RobotPreferences.StringValue StringPreference

The new implementation adds PIDControllerPreference and ProfiledPIDControllerPreference which manage preferences for the P, I & D settings of a PIDController and ProfiledPIDController, respectively. Both implement a PID controller interface and are drop-in replacements for their respective PID controller object.

The common preferences initialization has also been removed from Common.init(). Checking for non-default and writing default preferences must now be done by the user of the library. The creation of a dedicated preferences tab in Shuffleboard has also been removed. Integration with the driver dashboard must now be done manually, e.g. by annotating preferences values with the new dashboard annotations.

The previous annotation-based implementation only supported static instances. The new implementation supports preference values as instance variables (fields) in addition to static variables. This also adds support for static fields and methods to be annotated with the dashboard annotations.

See Package com.nrg948.common.preferences for API documentation.

Autonomous Annotations

This release adds an annotation processor to scan for autonomous annotations. It generates a configuration file at compile time that contains references to the autonomous command classes and generation methods. The configuration file is loaded at runtime to lookup these elements, generate the autonomous commands and populate a SendableChooser which is used to select among them. The new implementation also allows for more than one argument to be passed to the command class constructors and generation methods increasing flexibility for supplying data needed to initialize the commands.

This change replaces the previous implementation based on the Reflections library that used runtime annotation scanning to look up the autonomous command classes and generation methods. Since it is no longer necessary to initialize the Reflections library with the package names to scan for annotations, the Common.init(String... pkgs) method has been removed. The README section on "Optimizing library load time" has also been removed as it was only needed by the Reflections library.

The Autonomous.getChooser method parameters have changed. The new definition is below:

  /**
   * Returns a {@link SendableChooser} object enabling interactive selection of autonomous commands
   * annotated with {@link AutonomousCommand}.
   *
   * @param args A list objects passed to the constructor of the autonomous commands providing
   *     access to the robot subsystems. This is typically an instance of <code>RobotContainer
   *     </code> but could be another type that manages the subsystems or the list of subsystems
   *     themselves. All commands must accept the same types and number of arguments.
   * @return A {@link SendableChooser} object containing the autonomous commands.
   */
  public static SendableChooser<Command> getChooser(Object... args);

See Package com.nrg948.common.autonomous for details.

What's Changed

  • Updates Javatuples to 2.0.1 by @edreed in #44
  • Prepare for 2026.1.1 release by @edreed in #45
  • Adds support for private preferences fields by @edreed in #46
  • Updates preferences JavaDoc by @edreed in #47
  • Updates WPILib to 2026.1.1 by @edreed in #48
  • Adds annotation-based Elastic dashboard creation and data binding by @edreed in #49
  • Upgrades WPILib to 2026.2.1 by @edreed in #50
  • Revamps preferences to support new annotation-based dashboard integration by @edreed in #51
  • Corrects parameter order to match annotation definition by @edreed in #52
  • Writes show_submit_button field for Text Display widget by @edreed in #53
  • Publish JavaDoc to nrg948.github.io/nrgcommon/javadoc by @edreed in #54
  • Use gradle wrapper to generate javadoc by @edreed in #55
  • Specify sub-project JavaDocs source directories by @edreed in #56
  • Fix JavaDoc subdirectories by @edreed in #57
  • Change hosting branch to javadoc by @edreed in #58
  • Fixes JavaDoc link in README by @edreed in #59
  • Relaxes type checks for complex widget source types by @edreed in #60
  • Adds support for nested classes as dashboard definitions by @edreed in #61
  • Optimizes publishing of primitive and String constants by @edreed in #63
  • Improves error handling for missing @DashboardDefinition annotation by @edreed in #64
  • Implements ProfiledPIDControllerPreference by @101zh in #65
  • Fixes dashboard field integration. by @raptorhawk9 in #67
  • Adds support for annotating Optional values with @DashboardTab by @edreed in #66
  • Add Rebuilt game field. by @raptorhawk9 in #68
  • Adds autonomous annotation processor by @edreed in #62
  • Fix MatchTime by @raptorhawk9 in #69
  • Unboxes primitive type when generating type list string by @edreed in #70
  • Fixes JavaDoc linter warnings in nrgcommon sub-project by @edreed in #71
  • Completes PID controller preference APIs by @edreed in #72
  • Adds missing methods and fixes JavaDocs by @edreed in #73
  • Removes extraneous space by @edreed in #74
  • Adds missing JavaDoc and fix some widget types by @edreed in #75
  • Adds support for NTSendableBuilder.setUpdateTable by @edreed in #76
  • Fix gyro by @NRG948DriverStation in #77
  • Publishes profile PIDController errors to network tables. by @NRG948DriverStation in #78
  • Adds type-specific bindings by @edreed in #80
  • Fixes DataBinding.disable method by @edreed in #81
  • Replaces global list of data bindings with hierarchical bindings by @edreed in #82
  • Fix visibility of NO_DATA constant. by @edreed in #83
  • Simplifies logic in DataBinding.disable by @paulwdavis in #84
  • Fixes camera stream integration with Elastic by @edreed in #85
  • Reworks constant bindings to unpublish on disable by @edreed in #86
  • Adds dashboard modes that dynamically enable & disable tab bindings by @edreed in #87
  • Overrides topic for dashboard alerts by @NRG948DriverStation in #88
  • Improves dashboard annotation error reporting by @edreed in #89
  • Enables Alert & Alert[] to be target of dashboard annotations by @edreed in #90
  • Prepares v2026.2.4 release by @edreed in #91

New Contributors

Read more

v2025.3.2

30 Mar 03:46
e253db1

Choose a tag to compare

What's Changed

  • Sets SendableChooser widget type by @NRG948DriverStation in #36
  • Simplifies EnumValue change notification and updates WPILib to 2025.2.1 by @edreed in #37
  • Adds final to preferences classes by @edreed in #38
  • Updates WPILib to 2025.3.1 by @edreed in #39
  • Improves and corrects JavaDoc by @edreed in #40
  • Adds a select method to EnumValue by @edreed in #41
  • Updates WPILib to 2025.3.2 and nrgcommon version to match by @edreed in #42
  • Prepares 2025.3.2 release by @edreed in #43

New Contributors

Full Changelog: v2025.1.0...v2025.3.2

v2025.1.0 Release

05 Jan 21:55
924927c

Choose a tag to compare

What's Changed

Full Changelog: v2024.3.1...v2025.1.0

v2024.3.1 Release

28 Feb 06:59
985bc29

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v2023.4.0...v2024.3.1

v2023.4.0 Release

29 Mar 02:51
ac2ec39

Choose a tag to compare

What's Changed

  • Add annotation for autonomous command factory method by @edreed in #17
  • Add support for autonomous command generator methods by @edreed in #22
  • Upgrade to WPILib 2023.4.2 by @edreed in #23
  • Prepare 2023.4.0 release by @edreed in #24

Full Changelog: v2023.2.0...v2023.4.0

v2023.2.0 Release

18 Jan 05:46
8f34bdb

Choose a tag to compare

What's Changed

Full Changelog: v2022.1.0...v2023.2.0

v2022.1.0 Release

31 Dec 23:53
5fcf1e0

Choose a tag to compare

This is the first official release of the nrgcommon Java library. It is compatible with WPILib 2022.4.1.