Responses not Containing Complete Info for Decoding

As I reverse engineer the protocol I’ve encountered some messages that are a challenge decoding the response asynchronously. The Pi Python provides no guidance. (Phrased politely because IMO it ignores the problem.)

Two of them are:

get_battery_voltage_in_volts - 3 calibration voltages
get_current_sense_amplifier_current - 2 motors

The problem is this additional information is not returned in the response. Without that information you can’t tell the current for left vs right motors, for example.

My kludge is to keep my sequence numbers > 0x80 and putting this additional value in the sequence field. The response processing adjusts based on the received sequence number.

I suggest the API should be adjusted to include this additional information as the first byte in the data.

1 Like

Hey @rmerriam!

Thanks for bringing this up; you’ve sparked some internal discussions about how we can get you and other users the information that isn’t super intuitive here. We’re going to gather the Firmware and SDK teams to have a chat about how to best provide/document this information and will let you know how this will end up happening!

Thanks for being such an awesome and active member of our community!



Hey Rud!

Just wanted to follow up and say that, after speaking with some members of the firmware team, your kludge is actually how the sequence number is meant to be used. As you’ve indicated, this isn’t the best user experience, so we are still chatting about and brainstorming on the changes we could potentially feasibly make to the API to remedy this, but I wanted to make sure that you had all of the information that I do :slight_smile:


1 Like