[APPROVED] Speedybee F405 V3 Flight Controller for Porting

Ok, I will have to dig deeper. I only tried with the baro - will add a compass as well and see what I can find. (They all run on the i2c bus, which is what I have been trying to improve).

1 Like

Ok please can you try this updated version. The issue this time was memory rather than I2C - I was able to calibrate a compass successfully with this build.

arducopter.zip (655.5 KB)

1 Like

Same problem. Here are the steps I took again: Reset parameters, flash new firmware, start setup (quadX, acelerometer…), start compass calibration and got this msg: CompassCalibrator: Cannot start compass thread… Then disable logging, start compass calibration, neither the bar or 0% change. I checked messages and I see “compass calibration running”, but it does not finish.
Thanks!

This is due to out of memory, please post your full parameter file then I can try. Maybe something is pushing the memory usage over the edge in your setup.

Here it is. Please note I reset parameters after I installed this new firmware. I went as far as the compass config. Nothing else.
Tks!
speedybee.param (18.7 KB)

By the way, here are messages I get at M.P. when connected:

2/4/2022 2:34:52 PM : PreArm: RC not found
12/4/2022 2:34:44 PM : EKF3 IMU0 is using GPS
12/4/2022 2:34:44 PM : EKF3 IMU0 origin set
12/4/2022 2:34:21 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 2:34:21 PM : PreArm: Compass not calibrated
12/4/2022 2:34:21 PM : PreArm: RC not found
12/4/2022 2:33:50 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 2:33:50 PM : PreArm: Compass not calibrated
12/4/2022 2:33:50 PM : PreArm: RC not found
12/4/2022 2:33:19 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 2:33:19 PM : PreArm: Compass not calibrated
12/4/2022 2:33:19 PM : PreArm: RC not found
12/4/2022 2:33:19 PM : u-blox 1 HW: 00080000 SW: ROM CORE 3.01 (107888)
12/4/2022 2:33:16 PM : GPS 1: u-blox saving config
12/4/2022 2:33:02 PM : GPS 1: detected as u-blox at 230400 baud
12/4/2022 2:33:00 PM : EKF3 IMU0 MAG0 initial yaw alignment complete
12/4/2022 2:33:00 PM : EKF3 IMU0 tilt alignment complete
12/4/2022 2:32:58 PM : AHRS: EKF3 active
12/4/2022 2:32:58 PM : EKF3 IMU0 initialised
12/4/2022 2:32:56 PM : RCOut: PWM:1-8 NeoP:9
12/4/2022 2:32:56 PM : AHRS: DCM active
12/4/2022 2:32:56 PM : ArduPilot Ready
12/4/2022 2:32:56 PM : Barometer 1 calibration complete
12/4/2022 2:32:55 PM : Frame: QUAD/X
12/4/2022 2:32:55 PM : RCOut: Initialising
12/4/2022 2:32:55 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 2:32:55 PM : ChibiOS: 996b29d4
12/4/2022 2:32:55 PM : ArduCopter V4.4.0-dev (ada637a5)
12/4/2022 2:32:55 PM : Frame: QUAD/X
12/4/2022 2:32:55 PM : RCOut: Initialising
12/4/2022 2:32:55 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 2:32:55 PM : ChibiOS: 996b29d4
12/4/2022 2:32:55 PM : ArduCopter V4.4.0-dev (ada637a5)
12/4/2022 2:32:54 PM : Frame: QUAD/X
12/4/2022 2:32:54 PM : RCOut: Initialising
12/4/2022 2:32:54 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 2:32:54 PM : ChibiOS: 996b29d4
12/4/2022 2:32:54 PM : ArduCopter V4.4.0-dev (ada637a5)
12/4/2022 2:32:54 PM : Calibrating barometer

I reset parameters (set FORMAT_VERSION 0), reboot, set FRAME_CLASS 1, load your parameters, reboot - compass calibration started fine. I’ll see if I can rebase on 4.3 just in case that uses slight less memory.

I am not using 4.3. The firmware I have to get it working without logging is 4.4 → it’s on the latest firmware download.

Ok, there were some more flash and memory savings to be made - this version has loads of memory free

arducopter.zip (607.9 KB)

Also please try logging again - should be fine now

I reset parameters to default on MP.
Loaded new firmware and configured frame class, accelerometer and run compass calibration.
Same result as before… I don’t know what I am doing wrong…

See msgs:
12/4/2022 4:44:34 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 4:44:34 PM : PreArm: Compass calibration running
12/4/2022 4:44:34 PM : PreArm: RC not found
12/4/2022 4:44:03 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 4:44:03 PM : PreArm: Compass not calibrated
12/4/2022 4:44:03 PM : PreArm: RC not found
12/4/2022 4:43:32 PM : PreArm: Battery 1 low voltage failsafe
12/4/2022 4:43:32 PM : PreArm: Compass not calibrated
12/4/2022 4:43:32 PM : PreArm: RC not found
12/4/2022 4:43:31 PM : u-blox 1 HW: 00080000 SW: ROM CORE 3.01 (107888)
12/4/2022 4:43:29 PM : GPS 1: u-blox saving config
12/4/2022 4:43:16 PM : Frame: QUAD/X
12/4/2022 4:43:16 PM : RCOut: PWM:1-8 NeoP:9
12/4/2022 4:43:16 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 4:43:16 PM : ChibiOS: 4810ba51
12/4/2022 4:43:16 PM : ArduCopter V4.4.0-dev (78a407ab)
12/4/2022 4:43:16 PM : Frame: QUAD/X
12/4/2022 4:43:16 PM : RCOut: PWM:1-8 NeoP:9
12/4/2022 4:43:16 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 4:43:16 PM : ChibiOS: 4810ba51
12/4/2022 4:43:16 PM : ArduCopter V4.4.0-dev (78a407ab)
12/4/2022 4:43:16 PM : Frame: QUAD/X
12/4/2022 4:43:16 PM : RCOut: PWM:1-8 NeoP:9
12/4/2022 4:43:16 PM : speedybeef4v3 002F0044 32315111 35383730
12/4/2022 4:43:16 PM : ChibiOS: 4810ba51
12/4/2022 4:43:16 PM : ArduCopter V4.4.0-dev (78a407ab)
12/4/2022 4:43:15 PM : GPS 1: detected as u-blox at 230400 baud

By the way, I disabled logging and got same result.
When I load 4.4 latest back and disable logging, calibration runs fine…

I don’t see the error about cannot start thread? Also you reboot after accel calibration right?

Are you able to run mavproxy? We can look at the memory usage on your board:

ftp get @SYS/memory.txt -
ftp get @SYS/threads.txt -

The “cannot start thread” happens if I don’t disable logging. If I do disable it, it keeps on running forever and the bar (%) doe not move and settings are not saved. After reboot, I get msg “compass not calibrated”…
If I do the same procedure with the latest stable 4.4 firmware, after disabling logging, compass calibration runs fine and settings are saved.
I do reboot after calibration of course.
I am not familiar with mavproxy, but if you think it is necessary, I will get hold of it and learn its basics.

I think its worth it - your experience is not the same as mine. You definitely have the v3 right?

Ok, I have found a problem with my logging - maybe that’s the problem - I’ll have a look

What is LOG_BACKEND_TYPE set to in your config?

I changed it from 1 to 0

It is F405 V3 for sure

Somehow my logging had been disabled. With it enabled, the RAM usage is too high - I am trying to figure out what can be cut

Please try this firmware - I have tried something more drastic

arducopter.zip (603.0 KB)