How to methodically tune (almost) any multicopter using ArduCopter 4.4.x

I installed bluejay then went to install the bd firmware and discovered there isnt a bdshot fimware for hte speedybeef405mini or the JHEMCU-GSF405A that I have. Is there a reason those boards dont support it?

They both support bidirectional DShot. It’s the opposite - there is no firmware version for them, which does not support BDShot.

1 Like

what should SERVO_DSHOT_ESC be set for to use bluejay escs on blheli-s?

I don’t really know whether the answer is right, but it seems from experience that Bluejay understands options 2 and 4 for SERVO_DSHOT_ESC (that is, both related to blheli_s).

At least they work well in flight, and option 4 enables extended telemetry. There is not really much coming via extended telemetry in the case of typical hardware running Bluejay, but I am working on supporting Extended DShot Telemetry v2 in Ardupilot, which will bring some status information about how much an ESC struggles to keep it going.

3 Likes

The RPM is coming through now thank you.

1 Like

The process can be automated with the new ArduPilot Methodic Configurator available from ArduPilot Methodic Configurator github repository

3 Likes

2 or 4. The reason the settings are different is because BLHeli_S/BlueJay use MCUs that are not able to leverage some of the newer features of 32-bit MCUs (e.g. DMA) and thus are quite timing sensitive (they use bit-banging instead). The settings change the calculation of the high/low period for dshot in a way that these firmware’s seem happier with. Why don’t they follow the standard you might reasonably ask? Well first off there isn’t really a “standard” for dshot timing. The output bitrates are fixed, but the duty cycle within that is not. Second off, blame BetaFlight - my suspicion is that many ESC manufacturers only test against BetaFlight in development - so if it works in BetaFlight they assume “job done” and move on. But BetaFlight itself also has some variability in timing because it also uses bit-banging in many instances. So what this boils down to is us trying to replicate BetaFlight timings on a very different platform, without a standard - and surprise, surprise, not everything works as expected.

4 Likes

FETtec is a better protocol in that regard. the checksum is not the best, but at least the timing is a lot simpler.

The GUI tool can now replace the text editor even when no flight controller is connected to it.

2 Likes

Did a temperature calibration step by step , but had different results

Reason for redoing was because the first time I left the FC in freezer only for few mins was a bit hesitant. And second calibration I thought my dog had entered the room and must have pushed the table where the FC was kept.

Total did 3 calibrations and all had different results. I understand tmin can be different depending on how long we keep the FC in freezer but tmax behaved quiet different in all 3 calibrations and all results are quiet different. Could you have a look.

Also the drone might have to operate in temp ranging from -10C to 55c .

Pixhawk orange cube+

Attempt 1- temp cal1 - Google Drive

Attempt 2 temp cal 2 - Google Drive

Attempt 3 temp cal 3 - Google Drive

1 Like

The second one looks the best. Use that one.

2 Likes

Thank you @amilcarlucas

I have a drone with pixhawk cube orange FC in which temp calibration wasn’t done previously. The drone is tuned and have been flying it for a time now. Is it possible to do just the temp cal now? Will it hamper my pids? Or tuning ?

Yes, it is possible. No, it will not mess the tuning. It will improve it.

1 Like

Ok…I used the install to get the methodic configurator installed. I ran the first script for setting the temp cal, put the quad in the freezer, took it out and plug in a battery. After some time the calibrate finished. I copied the log file off of the SD card, installed Python on my Win11 laptop, and copied the tempcal.py locally. When I try running it to get the graphs, I get the following:

C:\Users\kevin\Documents\tempCal>tempcal_IMU.py 00000086.bin
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:301: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match(“^INS_TCAL(\d)ENABLE$“, msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:315: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match(”^INS_TCAL(\d)
(ACC|GYR)([1-3])_([XYZ])$”, msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:327: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match(“^INS_TCAL(\d)_TMIN$”, msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:333: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match(“^INS_TCAL(\d)_TMAX”, msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:339: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match(“^INS_GYR(\d)CALTEMP", msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:345: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match("^INS_ACC(\d)CALTEMP", msg.Name)
C:\Users\kevin\Documents\tempCal\tempcal_IMU.py:351: SyntaxWarning: invalid escape sequence ‘\d’
m = re.match("^INS
(ACC|GYR)(\d?)OFFS
([XYZ])$”, msg.Name)
Traceback (most recent call last):
File “C:\Users\kevin\Documents\tempCal\tempcal_IMU.py”, line 20, in
from pymavlink import mavutil
ModuleNotFoundError: No module named ‘pymavlink’

What do I need to get this working? I also installed the MavProxy tool, but that didn’t help. Looks like I’m missing a file, but what do I get that from?

Thanks for any ideas you can provide,
Kevin

That script is not python 3.11 friendly. I stared integrating the script in the ArduPilot Methodic Configurator software. Once that is done you no longer need to install python or download the script. You will be able to use the ArduPilot Methodic Configurator software to compute the parameters and write the results to both file and flight controller. Stay tuned. I have big plans.

That sounds great. Thanks for the quick reply. In the meantime, would downgrading the Python I installed to say v3.10 allow me to continue with the tuning process? Or it’s better to wait for your next release?
Thanks again.

I already have a new version of tempcal_IMU.py inside my software. You can download and test that one first.

The new version helped. Now I’m just getting the following error:

C:\Users\kevin\Documents\tempCal>tempcal_IMU.py 00000086.bin
Traceback (most recent call last):
File “C:\Users\kevin\Documents\tempCal\tempcal_IMU.py”, line 11, in
from pymavlink import mavutil
ModuleNotFoundError: No module named ‘pymavlink’

Just to clarify, I only downloaded the new tempcal_IMU.py file. I noticed other files in the repository were new now as well. Perhaps I need to reinstall the whole MethodicConfigurator package?

No, you just need to do:

python -m pip install pymavlink numpy matplotlib

Edited with the tip from @KevinB below