Can you power VOXL2 from the ModalAI 6s ESC?
-
Yes, potentially. You should follow the steps to update your firmware and params specifically for low kv motors as I suggested and documented
-
Just to confirm - I updated the params file (mn4006 low kv) according to the instructions and I am on this ESC firmware: version 39, hash d4fe8e3d. The firmware you list is 39 RC11, is the firmware I'm running good, or do I need to use the RC11 version? Everything else is the same as in your instructions.
Thanks!
-
@Alex-Kushleyev - Nevermind. I see you checked it in 2 days ago. I am updating the firmware now. Sorry!!
-
@Matthew-Wellner you need the firmware
modalai_esc_firmware_m0134_6_v0_39_RC11_17d64675.bin
- there is an update specifically to address the de-sync issue. as well as the params i mentioned, most importantlytiming_advance
,sense_advance
anddemag_timing
-
also please review params that i used for a similar motor : https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/dev/voxl-esc-params/low_kv/mn4006_m0134_6_low_kv.xml
-
The firmware update worked! Sorry again for not paying better attention
-
@Matthew-Wellner said in Can you power VOXL2 from the ModalAI 6s ESC?:
The firmware update worked! Sorry again for not paying better attention
Ugh - I spoke too soon... 50%+ is still having issues, but I am going to re-run through everything again to make sure I didn't miss anything else.
Thanks again!
-
@Matthew-Wellner - good! not de-syncing now? Are you looking at the plots that are being saved after the test? visual inspection of the data is always good, once you look at a few plots and become familiar with what to expect you can easily spot if there are any issues.
By the way, the test you are doing by commanding
--power 40
etc, will essentially step from initial power of around 10 to 40. This is fine. I have been doing my step testing starting at 20%, which is a more realistic condition (stop from 20 to 50, 20 to 70, 20 to 90, 20 to 100 -- gradually increasing to build confidence). Stepping from 10 should be ok, but will experience even more aggressive transition.. let me know if you run into any issues with that.If you did not actually want an instant step when you are using
voxl-esc-spin.py
command, you can provide--ramp-time 2.0
argument (which will gradually ramp up) -
can you try the ramp test
https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/dev/voxl-esc-tools/doc/low_kv_motor_tuning.md?ref_type=heads#power-ramp-test
and the step tests
https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/dev/voxl-esc-tools/doc/low_kv_motor_tuning.md?ref_type=heads#power-step-tests
-
i think the issue may be happening because you are punching a lot of power right after spin-up.
You can try increasing the following parameter to make sure the motor is fully spun up :
https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/dev/voxl-esc-params/low_kv/mn4006_m0134_6_low_kv.xml?ref_type=heads#L77 increase to 500
I may need to add some protection against applying high power from very low rpm, as it is a really tough case
-
I was trying to avoid those tests before I had a proper setup to clamp the drone down, but I'll work on getting that together now and I'll give the ramp test a try.
Thanks!
-
@Matthew-Wellner , yes.. safety first!
-
I tried your test on my set up (mn4006 380kv, 15" prop), i cannot reproduce the issue. Please make sure that the following params are set correctly:
<param name="timing_advance" value="60"/> <param name="sense_advance" value="20"/> <param name="demag_timing" value="1"/>
If i set timing advance to something much lower, i can reproduce an issue, the motor makes a high pitch sound.
Also please check the spin-up params. you could increase the spin-up rpm target to make sure the motor spins a bit faster after spin-up.
Here is a plot of the following test (don't run at such high power until you make sure the lower power works fine :
./voxl-esc-spin.py --id 3 --power 100 --timeout 1.5 --enable-plot 1
You can see three phases of the motor spin-up
- smooth sinusoidal spinup (t=0..1s)
- short transition to 6-step commutation control (t=1.0..1.05s)
- apply desired power with a slight slew rate limit (rate limit happens internally to firmware). Motor accelerates to maximum RPM. t=1.05.. 1.5s
-
The ramp tests seems to have worked. I think that I was jumping the power up too quickly like you suggested. I'll get into trying to calibrate now. Thanks!!
-
@Alex-Kushleyev said in Can you power VOXL2 from the ModalAI 6s ESC?:
When I run the step tests, I can get up to the step amplitude of 70 successfully. When I try 20-100, it looks like I start to desync.
-
One last question - How do I get new values for kp & ki, or do I just leave them at 0?
-
@Matthew-Wellner , ok the results are not too bad. I will keep working on improving the low kv performance, but i think what you have should be sufficient.
You can also push the commutation advance a bit higher from 60 to 70 or 75, that should improve even more at an expense of a bit of motor efficiency.
You should be ready for the rpm controller, please run the calibration procedure. You can set kp=50, ki=10 to give it a little bit feedback.
Another thing that will prevent de-sync is the max_rpm_delta, which is basically the maximum RPM error that is used in the RPM controller. You can start by capping it about 2/3 of the max rpm and after calibration you can see if RPM step tests result in any de-syncs.
By the way, if you leave kp=0 and ki=0, the performance (speed of response) should be similar to a traditional ESC, but still better because of the Feed Forward curve and battery voltage compensation. So you can experiment with this and even kp=0 and ki=0 will still result in good performance. But a little better should be the defaults that i have here :https://gitlab.com/voxl-public/voxl-sdk/utilities/voxl-esc/-/blob/dev/voxl-esc-params/low_kv/mn4006_m0134_6_low_kv.xml#L62 including
max_kpe
andmax_kie
(andmax_rpm_delta
you can adjust if you see any de-syncs during rpm step tests) -
Also, keep in mind that the step tests are extremely aggressive, you will never experience this in practice, as it is practically impossible to have a step input like as output of a flight controller. Nevertheless we want to make sure that the ESC will perform well. At the end of the day, since the flight controller will use RPM control, the RPM (step) tests are the most important - the RPM controller can help avoid these extreme transitions.
-
@Matthew-Wellner , i have acquired SunnySky 4004 400kV motor, waiting for Tmotor MS1101 props, so i will be able to test your exact configuration and make sure it works well and does not desync. It will take a few more days for props to come in, just wanted to let you know.
-
@Alex-Kushleyev Awesome!! Thanks!
-