BMS: Method to Retrieve Fault Logs

We are planning to have some kind of fault log, which records fault conditions.
The exact implementation is still somewhat TBD, but I imagine the fault log would contain the timestamp, fault code, and maybe some captured data.

It could be easy enough as retrieving ASCII data. Example use case:

  • BMS has 10 different faults
  • FC requests fault count, BMS reports “10”
  • FC requests fault “1”
  • BMS sends details (in string format) for fault 1
  • FC loops to fault 10

Is there already an easy way in UAVCAN to allow for this kind of communications?

I think this is a very general use case that is applicable beyond just BMS. We envision a generic application-agnostic datalogging framework as outlined briefly here (even though it is documented in an implementation repo, it is not specific just to this implementation):

Under this model, the recommended way of handling faults is to emit a UAVCAN message (such as uavcan.diagnostic.Record or vendor-specific) and let the blackbox record it for postmortem analysis later. The analysis feature is to be implemented in Yukon.