About the live data from the VESC via UART

Hi,

I’m readin the live data of the VESC with an Arduino Mega via the UART channel. Got it working just fine. Yet I have trouble understanding some of the Information I get :smile: I hope you can help to clarify.

Those are the values:

  • avgMotorCurrent Ok this one is pretty clear. The average current of all 3 motor phass

  • avgInputCurrent This would be the current drawn from the battery

  • dutyCycleNow I control the VESC with PPM, so this would be the uptime of my signal in ms I guess?

  • rpm rounds per minute. SHOULD be clear, yet it shows a value of 45000 when running idle (without load, just in air). That would be 750 rounds PER SECOND. I just cant believe that. Do you have information on that data?

  • inpVoltage The battery voltage. No question here.

  • ampHours So those are the ampHours CURRENTLY DRAWN? or the remaining?

  • ampHoursCharged Are those the AmpHourse charged due to recuperation?

  • tachometer So whats that? The speed? Speed could be easily calculated from rolldiameter (using HUBS here) and a gear ratio of 1:1, but I cant find an option to tell in BLDC tool which rolldiameter I’m using

  • tachometerAbs And those would be the whole distance travelled than?

Cheers, thanks for your time, Nordlicht

1 Like

it’s not that easy, at least the value doesn’t seem to represent the actual amp draw for my board. I don’t know about this though, didn’t research it further yet.

I can’t confirm but i think it’s the duty cycle of the motor output and not the RC Input.

It’s rpm times pole count, so you have to divide this value by 7 (i think) for most motors since they have 14 poles.

The drawn amp hours since booting, the VESC doesn’t know how much amp hours are left in your battery.

exactly.

That’s not the speed. Each rotation your motor completes this value should go up by one, but since you’re having multiple poles in you motor you have to take your pole counts and multiply them by 3. with 14 poles this would be 42, that means 42 pulses of the tachometer equal one motor rotation. This value goes up and down depending on which direction the motor is turning.

it’s the same as the regular tachometer, but it just gets bigger regardless of motor direction.

4 Likes

Well, that is one hell of a reply! Thank you. Once the board is on the streets, I’ll check those values back and give feedback.

1 Like

Yes. You want to devide by 14. My HUB maxes out without load at around 54km/h which seems really plausible for 24V.

1 Like

Can you provide a tutorial on how to get live data from the vesc with an arduino? I would really appreciate =)

1 Like