Problems with Babel & DroneCAN GUI Tool on Windows

The output just hangs when I enter this command, is this to be expected? It doesn’t seem to make a difference to deploying the configuration file

It is supposed to write the result within a few seconds. Here’s the full form once again for clarity:

cat configuration.yaml | y rb 125

Is this what you’re invoking?

I was using the command:
cat configuration.yaml | y rb
I added the node ID 125 at the end and it works now. the monitor output now looks like this

I now should be able to send publish commands and expect the motor to start spinning. Unfortunately this does not happen.
The command I am sending is:
y pub -T 0.1 1017:uavcan.primitive.scalar.real16 50
Where 1017 refers to uavcan.sub.setpoint_velocity.id according to my configuration file (uploaded for reference)
configuration.yaml (7.8 KB)

I changed the drive.velocity_ctl.type register value to 2 as per the example configuration file, and deployed to the ESC. Unfortunately this does not change anything. Is there more information about what the different values for this register do? Is this the only field that needs to be changed to activate velocity control?
The motor did not spin for the ratiometric torque control mode commands either.

I have attached example output using -v when entering the above command
example_output.txt (14.9 KB)

You have the readiness topic configured:

uavcan.sub.readiness.id: 1009

Per the reference manual, if you configured the readiness topic, then you must explicitly publish the arming command to allow the drive to leave the idle state; this is a safety feature. If you don’t want this behavior, you need to disable the readiness topic by setting its ID to 65535 again. More details here: Drive - Telega v1.0 Reference Manual

1 Like

I have managed to get the motor working now. Thank you for your help

1 Like

Hi Pavel,

I wondered if you could help with this.
Now that I have got the ESC spinning the motor, I am not sure that the velocity commands actually correspond to the rate of the motor.
The command I am sending is:
y -v pub -T 0.01 1017:uavcan.primitive.scalar.real16 2000
which would equate to 19098.59317102744 RPM, however the motor looks more like it is spinning at ~500 RPM.
I tried sending commands at 500 rad/s but this barely turned the motor.
Additionally the noise it not as smooth as I would have imagined, do you have any insights into this?

Configuration file, and video of motor running from above command uploaded

configuration.yaml (7.8 KB)
n

motor.mechanical_ratio is not configured correctly. It should equal the number of pole pairs as explained in the reference manual: Motor model - Telega v1.0 Reference Manual and in the tutorial: Yakut CLI tool - Telega v1.0 Reference Manual

Also, the maximum current is set to only 10 A, which is suspiciously low.

The sound is due to the oscillation in the velocity control loop, which is happening because the P term of the acceleration controller is set to a very high value of 1000 Hz, while normally it should be close to 50 Hz. The moment of inertia is set to 10\times10^{-6} \text{kg}\cdot\text{m}^2, I wager this value exceeds the actual inertia of your motor without load, which may also cause oscillation, but not sure on this one.

Thank you Pavel, this has been very helpful.

1 Like