FRC2706 / 2023-2706-Fall-Poseidon

Reprogramming Poseidon from scratch in the offseason.
Other
2 stars 0 forks source link

Swerve Logging (networktables) #6

Open ErikCald opened 1 year ago

ErikCald commented 1 year ago

It is very important to send data to the networktables so we can view it in real time and debug or tune the robot. Also, we can enable the DataLogManager to log all networktable values into a log file on a usb stick. This will be very helpful to know what happened during matches when something went wrong. Though, if a piece of data should be logged but doens't need to use networktables, that can also be done with a DoubleLogEntry object (or other types) to avoid consuming bandwidth on the network.

Another part of this will be reading networktable entries and updating specific constants in code. This is specially for the PID values of swerve (drive and steering), the kS, kV and kA values of the swerve drive motor, and an offset value between the cancoder and steer encoder. We can use glass/shuffleboard/outlineviewer to set networktable entries allowing us to update these constants very quickly, making tuning go much faster.

ErikCald commented 1 year ago

Things to log with swerve: