Hi all,
for my application I need to apply a rotating field to my machine at high currents. Basically exactly what the terminal command foc_openloop does.
Is there any way to control this via the CAN Bus? I am sure you can activate it via can, because it also works if the VESC is connected to VESC Tool via another Vesc over can but I am struggling to understand how the much more complex can forwarding seems to work.
With normal CAN Commands (https://github.com/vedderb/bldc/blob/master/documentation/comm_can.md) it seems like it is not possible.
Does anyone know more or could point me in the right direction?
Thanks;
Jakob
Yeah, it will work. You just need to mod your firmware a bit.
This would be a good example to start with (from here: https://github.com/vedderb/bldc/blob/c9dbe942e0262473ae7e978137e1f2c9928...)
case CAN_PACKET_SET_CURRENT:
ind = 0;
if (len >= 6) {
mc_interface_set_current_off_delay(buffer_get_float16(data8, 1e3, &ind));
}
mc_interface_set_current(buffer_get_float32(data8, 1e3, &ind));
timeout_reset();
break;
You might simply replace the above mc_interface command with mcpwm_foc_set_openloop_current(current, DIR_MULT * rpm) to maintain the standard command structure, provided you will never need to use regular FOC/non-openloop current set command.
NextGen FOC High voltage 144v/34s, 30kw (https://vesc-project.com/node/1477)
Thanks,
that sounds like a great insight and a good tip :-)
Jakob