Crash with 4.2.0-beta and 4.3.0-daily (bdshot)

Thanks a lot! Actually I don’t understand code so can’t be usefull any way, but please let me know when some changes are made and will need testing!

Today I confirmed that spontaneous crash of this version isn’t directly related to the harmonic notch or autotune, because it happened in the normal acro flight (video and log).
I know the version from Feb 22nd is obsolete, but so far is the only one, which can arm my motors and so far I supposed it’s working at least without notch filter and buzzer - now I know it’s not.
I’m quite sure that FC rebooted because FC started a new log and OSD was showing some strange messages.


Posting only hoping it can be helpful for developers.

I’m sorry, but from pull request I don’t understand if any solution for shot and bluejay is on the way or not - github record is complete foreign language for me :frowning_face:.

Sorry for your crash :frowning: yes this is an in-flight reboot. The log after is the dreaded all-zeros watchdog, which I haven’t been able to get to the bottom of. What I have found is that this can be related to flash corruption, so my first suggestion is that you take a copy of your parameters and completely wipe the board. If you know how to use mavproxy you can set FORMAT_VERSION to 0 and reboot. Another way is to load betaflight and then load AP back again. Then restore your parameters.

That said I have only seen flash corruption occur on H7 flight controllers, so it could easily not be this.

I’ve never heard of this “all zeros” watchdog so I’ve added it to our 4.2 issues list.

I’m glad if I can be any way usefull to the developement. I’m not a programmer so can’t help with the code, at least I’ll try to help with some testing.
This quad is very crash resistant so nothing happened during all previous crashes.
I’ll load iNAV for some time and wait for some newer AP version allowing at least to arm my ESCs again. Doesn’t make sense to use Feb 22nd version any longer as it’s probably not stable.
Is any new dev version with improved timer prescalers on the way to be released (or when it can be)?
As said 4.2beta2-bdshot doesn’t arm my ESCs so I can’t fly :wink:

I need to fly the prescaler change before it can go in

4.2.0-beta3 will go out probably tomorrow with some DShot/BLHeli fixes but as far as I know those only improve the situation for Rover/Boat.

Would you be able to get mavproxy working on your setup? We would like to check the RAM usage and mavproxy makes this easy. Basically we want to see the output of ftp @SYS/threads.txt - when the system is armed.

Sorry, but I’m quite stupid in Linux and such things.
Never used MAVPROXY before so I installed it on Windows and made connect it to my FC over USB cable.
After getting prompt I pasted command you requested, but probably it’s just a hint (for someone smarter), not full description so I got only help for ftp - see below.
I’ll be glad to test it for you, but I need complete steps how to proceed for a dumb Windows user.
Extra question: from the version do you want memory usage? From Feb 22nd I crashed, or 4.2beta2 or which one?
Thanks!

COM6 : ArduPilot (COM6) : USB VID:PID=1209:5741 SER=2F0030000951363432333236 LOCATION=1-1
Unloaded module map
MAV> ftp @SYS/threads.txt
Usage: ftp <list|get|put|rm|rmdir|rename|mkdir|crc>

try

ftp get @SYS/threads.txt

Like @amilcarlucas says, but:

ftp get @SYS/threads.txt -

notice the trailing - which means print to the console rather than to a file

Thanks!
I can’t arm vehicle now as it’s noisy and children are already sleeping, but please see dump in disarmed state, whether its’ what you’ll need for armed state:
Getting @SYS/threads.txt as -
ThreadsV2
ISR PRI=255 sp=0x20000000 STACK=1280/1536
ArduCopter PRI=182 sp=0x20000600 STACK=5368/7168
idle PRI= 1 sp=0x20013568 STACK=144/352
UART_RX PRI= 60 sp=0x2001DA88 STACK=768/1104
OTG1 PRI= 60 sp=0x2001D1A8 STACK=264/656
monitor PRI=183 sp=0x20010B60 STACK=480/848
timer PRI=181 sp=0x20011D80 STACK=1488/1872
rcout PRI=181 sp=0x20011470 STACK=432/848
rcin PRI=177 sp=0x20010EE8 STACK=1064/1360
io PRI= 58 sp=0x200101D8 STACK=1496/2384
storage PRI= 59 sp=0x200117F8 STACK=848/1360
UART1 PRI= 60 sp=0x2001C858 STACK=296/656
UART3 PRI= 60 sp=0x2001C010 STACK=280/656
UART6 PRI= 60 sp=0x2001B930 STACK=272/656
UART4 PRI= 60 sp=0x2001B208 STACK=368/656
SPI3 PRI=181 sp=0x20019C48 STACK=904/1360
OSD PRI= 59 sp=0x200154F0 STACK=920/1616
log_io PRI= 59 sp=0x20015CD8 STACK=1248/1656
I2C0 PRI=176 sp=0x20017B38 STACK=920/1360
SPI1 PRI=181 sp=0x200142D0 STACK=720/1360
FTP PRI= 58 sp=0x1000DCA8 STACK=1440/2896

1 Like

Thanks! It looks ok - I can’t see anything concerning there

1 Like

The prescaler changes are now in. Unfortunately they just missed the cut for last nights build so you will have to wait until tomorrow to try. Would you be able to try? If they fix your BlueJay issues then I am keen for them to go into 4.2.

OK, I’ll test new build hopefully today evening. Do you still recommend full wipe of the FC and restoring params, or I can just upgrade?
I made “armed state” threads dump on the “crashing” version Feb. 22nd - see below. It not a real flight, only turning motors without props indoor.

ThreadsV2
ISR PRI=255 sp=0x20000000 STACK=1280/1536
ArduCopter PRI=182 sp=0x20000600 STACK=5280/7168
idle PRI= 1 sp=0x20013568 STACK=144/352
UART_RX PRI= 60 sp=0x2001DA88 STACK=768/1104
OTG1 PRI= 60 sp=0x2001D1A8 STACK=264/656
monitor PRI=183 sp=0x20010B60 STACK=480/848
timer PRI=181 sp=0x20011D80 STACK=1488/1872
rcout PRI=181 sp=0x20011470 STACK=432/848
rcin PRI=177 sp=0x20010EE8 STACK=1064/1360
io PRI= 58 sp=0x200101D8 STACK=1496/2384
storage PRI= 59 sp=0x200117F8 STACK=824/1360
UART1 PRI= 60 sp=0x2001C858 STACK=248/656
UART3 PRI= 60 sp=0x2001C010 STACK=264/656
UART6 PRI= 60 sp=0x2001B930 STACK=248/656
UART4 PRI= 60 sp=0x2001B208 STACK=368/656
SPI3 PRI=181 sp=0x20019C48 STACK=896/1360
OSD PRI= 59 sp=0x200154F0 STACK=920/1616
log_io PRI= 59 sp=0x20015CD8 STACK=128/1656
I2C0 PRI=176 sp=0x20017B38 STACK=920/1360
SPI1 PRI=181 sp=0x200142D0 STACK=720/1360
FTP PRI= 58 sp=0x1000E130 STACK=1440/2896

Definitely try the flash wipe trick.

log_io looks a little low on stack. I know we have made some changes here - I wonder if this has pushed things over the edge. We had memory problem on this board before.

There wasn’t yet GPS fix during stack measurement above. It could even increase amount of the data to be logged so it worth attention.

Should be prescaler changes already implemented in 2022-03-30-08:03, or Mar. 30th evening build or tomorrow Mar. 31st morning?

Current latest now has the change

Loaded 2022-03-30-08:03/omnibusf4pro-bdshot version after complete wiping FC and bluejay ESCs ARM OK.
That’s short version, here is more details:

Before it I did armed state thread dump on Feb 22nd version having GPS fix. I put disarmed copter under open sky, connected to mavproxy and waited for the fix. Ofter a minute FC at once rebooted (could be that GPS just got fix). There will be some logs - ask if you need them.

Then I armed and did thread dump: (daily build Feb 22nd 2022)
ISR PRI=255 sp=0x20000000 STACK=1256/1536
ArduCopter PRI=182 sp=0x20000600 STACK=5384/7168
idle PRI= 1 sp=0x20013568 STACK=144/352
UART_RX PRI= 60 sp=0x2001DA88 STACK=768/1104
OTG1 PRI= 60 sp=0x2001D1A8 STACK=264/656
monitor PRI=183 sp=0x20010B60 STACK=88/848
timer PRI=181 sp=0x20011D80 STACK=1488/1872
rcout PRI=181 sp=0x20011470 STACK=432/848
rcin PRI=177 sp=0x20010EE8 STACK=1064/1360
io PRI= 58 sp=0x200101D8 STACK=1448/2384
storage PRI= 59 sp=0x200117F8 STACK=864/1360
UART1 PRI= 60 sp=0x2001C7F8 STACK=248/656
UART3 PRI= 60 sp=0x2001BFB0 STACK=264/656
UART6 PRI= 60 sp=0x2001B8D0 STACK=272/656
UART4 PRI= 60 sp=0x2001B1F0 STACK=368/656
SPI3 PRI=181 sp=0x20019B88 STACK=896/1360
OSD PRI= 59 sp=0x20015430 STACK=896/1616
log_io PRI= 59 sp=0x20015C18 STACK=128/1656
I2C0 PRI=176 sp=0x20017B30 STACK=920/1360
SPI1 PRI=181 sp=0x10004010 STACK=720/1360
FTP PRI= 58 sp=0x1000E150 STACK=1440/2896

Then I wiped the FC board (installed iNAV) and after that installed daily build 2022-03-30-08:03.
Restored configuration (it was still complaining about unhealthy AHRS so I recalibrated ACC) and then it looks good ESCs ARM and all motors spin.
Not flight tested yet.

Also for this version I did armed state thread dump with GPS fix (2022-03-30-08:03):
ISR PRI=255 sp=0x20000000 STACK=1272/1536
ArduCopter PRI=182 sp=0x20000600 STACK=5264/7168
idle PRI= 1 sp=0x20013658 STACK=144/352
UART_RX PRI= 60 sp=0x2001DA88 STACK=768/1104
OTG1 PRI= 60 sp=0x2001D1A8 STACK=264/656
monitor PRI=183 sp=0x20010C10 STACK=480/848
timer PRI=181 sp=0x20011E30 STACK=1488/1872
rcout PRI=181 sp=0x20011520 STACK=432/848
rcin PRI=177 sp=0x20010F98 STACK=1024/1360
io PRI= 58 sp=0x20010288 STACK=1408/2384
storage PRI= 59 sp=0x200118A8 STACK=848/1360
UART1 PRI= 60 sp=0x2001C858 STACK=248/656
UART3 PRI= 60 sp=0x2001C010 STACK=264/656
UART6 PRI= 60 sp=0x2001B930 STACK=248/656
UART4 PRI= 60 sp=0x2001B208 STACK=368/656
SPI3 PRI=181 sp=0x20019C40 STACK=896/1360
OSD PRI= 59 sp=0x200154D8 STACK=896/1616
log_io PRI= 59 sp=0x20015CC0 STACK=144/1656
I2C0 PRI=176 sp=0x20017B28 STACK=920/1360
SPI1 PRI=181 sp=0x200142B8 STACK=720/1360
FTP PRI= 58 sp=0x1000DE18 STACK=1440/2896
I hope my testing can help some way!

1 Like