Boron Canandgyro Faults
CanandgyroFaults are a series of flags sent with the Boron’s status frame that indicate if the device is experiencing an issue. This API presents faults in two formats: active and sticky faults.
Active faults are updated every time a status frame is sent, and thus if an issue is resolved it will update the fault flag accordingly. This is useful for issues that can be transient, such as undervoltage faults (which occurs during a brownout).
Sticky faults do not automatically clear when set to true. For example, if a Boron briefly undervolts, due to a brownout, but normal power is later restored, the undervoltage fault will still be set to true. Sticky faults must be cleared by the user.
Fetching Faults
Section titled “Fetching Faults”// Get a Canandgyro object with CAN ID 0Canandgyro canandgyro = new Canandgyro(0);
// Fetch this Canandgyro's active faultsCanandgyroFaults faults = canandgyro.getActiveFaults();
// Fetch this Canandgyro's sticky faultsCanandgyroFaults sticky = canandgyro.getStickyFaults();//Get a Canandgyro object with CAN ID 0Canandgyro canandgyro{0};
//Fetch this Canandgyro's active faultsCanandgyroFaults faults = canandgyro.GetActiveFaults();
//Fetch this Canandgyro's sticky faultsCanandgyroFaults sticky = canandgyro.GetStickyFaults();Types Of Faults
Section titled “Types Of Faults”Power Cycle
Section titled “Power Cycle”The Power Cycle fault is set to true when the gyro powers on. By clearing sticky faults on initialization, this flag can be used to determine if the device has rebooted.
CAN ID Conflict
Section titled “CAN ID Conflict”The CAN ID Conflict flag is set to true when the device detects another device with the same CAN ID. While available in the API, you should check the physical device for the LED flashing blue (which indicates a detected CAN ID conflict). Alchemist should be used to configure the different devices to avoid CAN ID conflicts.
CAN General Error
Section titled “CAN General Error”The CAN General Error flag is set to true if the encoder detects a problem with its ability to receive CAN packets, or other issues with the CAN bus. Generally, this indicates an issue with the CAN wiring.
Out Of Temperature Range
Section titled “Out Of Temperature Range”The Out Of Temperature Range flag is set to true if the encoder detects its temperature is outside the safe operating range.
Hardware Fault
Section titled “Hardware Fault”A Hardware Fault indicates the device has detected a problem during operation. For the Boron, this generally will indicate that the device is unable to communicate with the on board sensors.
Calibrating
Section titled “Calibrating”The Calibrating flag is set to true if the device is currently calibrating.
Angular Velocity Saturation
Section titled “Angular Velocity Saturation”This fault is flagged if the rotation of the gyro exceeded the measurable rotation rate of the sensor.
Acceleration Saturation
Section titled “Acceleration Saturation”This fault is flagged if the acceleration experienced exceeds the measurable acceleration of the sensor.