Hello,
I am Uwe from Den Haag, working on Wind Drones (aenarete.eu).
Is there a documentation of the VESC API (application programming interface)?
I would like to control the set speed of a VESC, operating in speed control mode and log the actual speed,
motor current, battery voltage, battery current and duty cycle.
I would like to write a script that is executing these tests and is communicating with the VESC via
USB, but to be able to do this I need a list of the available commands, a description of the protocol
and of the data format.
Where can I find this?
If it doesn't exist, would it make sense to write such a documentation?
Thanks for your good work!
Uwe
The only real way to learn the protocol is by reading the source code and the available interface source codes from for example the arduino example communications. By the way the protocol is implemented it slightly changes when variables are added or removed. That is why you need a specific PC UI version for a specific FW version.
I think that the most straightforward way is to work with Qt for your implementation and use the existing code from the VESC-Tool, this prevents you from making communication protocol implementation errors and allows you to easy upgrade when new versions become available.
The serial port interface is quite well documented. Various arduino libraries exist.
The source code explains all available fields.
There is also CAN, but less is exposed there and the interface is a little less obvious and not much code exists that uses it.
If you are looking for a actual API, no such thing. But the firmware code is very well structured, so you can call into the same functions that for example other control apps do as well. (I suspect you are not looking at building a custom app on the vesc controller. But this is where API as a term only really makes sense)
Dear Uwe,
I am vimarsh from Delft, I need to ask you that do you know or did you figure out a way to directly log data from vesc to computer using USB or UART cable?
Hope to hear from you soon,
Thank you