Telemetry over CAN

Info and Discussion about the ESC32 hardware and software

Telemetry over CAN

Postby lou-s » Mon Nov 28, 2016 6:45 pm


I'm trying to get telemetry from the ESC32v3 over CAN. Currently, I am able to arm, start, and set the rpm. However, when I send the command to change telemetry rate and values I don't get any data, let alone an acknowledgement. I'm using the ESC32v2 source code as reference for the CAN communication structure.

I'm using a data object code of 12 for setting telemetry rate and 13 for setting telemetry values.

I'd like to double check that telemetry rate/values can be set over CAN in version 3 in the same way that it was set in the version 2 source.

Posts: 3
Joined: Tue Nov 22, 2016 6:53 pm

Re: Telemetry over CAN

Postby Max » Mon Nov 28, 2016 9:32 pm

That's correct, ESC32 v2 and v3 use the same telemetry interface/commands. The only difference is one of the data struct members -- instead of error count you get temperature. But this shouldn't affect basic communication.

Are you using AQ flight controller firmware code as a reference also? This has a full ESC32 CAN telemetry implementation already, working with both ESC versions. It can also forward the telemetry data via Mavlink.

Code: Select all
typedef struct {
    unsigned int state :    3;
    unsigned int vin :      12;     // x 100
    unsigned int amps :     14;     // x 100
    unsigned int rpm :      15;
    unsigned int duty :     8;      // x (255/100)
    unsigned int temp :     9;      // (Deg C + 32) * 4
    unsigned int errCode :  3;
} __attribute__((packed)) esc32CanStatus_t;

Posts: 2814
Joined: Mon Aug 13, 2012 9:45 pm
Location: Near Ithaca, NY, USA

Return to ESC32

Who is online

Users browsing this forum: No registered users and 2 guests