Page 1 of 1

STM32F769 Discovery not executed

Posted: Sat Oct 17, 2020 10:17 am
by moez

I successfully flashed MicroPython on my STM32F769 Discovery board.
I can access REPL mode with picocom and execute multiple python commands from there, I am also able to execute the available python scripts using

Code: Select all

I am also able to access the filesystem from my linux machine (file explorer is opened when connecting to USB-HS) and modify/create/delete python files.
But neither nor will execute after reset/reboot. I tried multiple solutions i found on the Internet, but none of them worked. After i stumbled across this topic (viewtopic.php?t=6303), i simply replaced line 713 in ./micropython/ports/stm32/main.c

Code: Select all

// changed line 713
if ((reset_mode == 1 || reset_mode == 3) && pyexec_mode_kind == PYEXEC_MODE_FRIENDLY_REPL) {
// to
if (1) {
and now is executed after system reset (but isn't).
For me it looks like the disco board is in safe mode and skips both files (respectively just now). But this is strange since safe mode is more an hardware issue (from what i learned from the multiple threads with similar problems the usr button is pulled in the wrong direction or is floating) and the disco board was probably tested successfully by the corresponding micropython developers ..
Also this fix doesn't seem to be a good solution, but works for now. I also had no time to dive deeper into main.c.
Do you have any hint what's the reason for this or have a solution to fix this permanently?

Thanks, moez

Re: STM32F769 Discovery not executed

Posted: Sat Oct 17, 2020 7:57 pm
by moez
Fixed it by flashing mboot again :roll: Now its working without a problem