Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 4935

MicroPython • Re: mpremote over UART/RS485

$
0
0
I guess I would need to modify micropython source code (change stdio to my own print/read functions) and then recompile it.
That would also be my guess; enabling REPL over UART.

Just adding the following to the end of 'CMakeLists.txt' and building the firmware should be enough -

Code:

target_compile_definitions(${MICROPY_TARGET} PRIVATE MICROPY_HW_ENABLE_UART_REPL=1)
Building the firmware is described here - viewtopic.php?p=1972803#p1972803

Upload that with 'picotool' or via BOOTSEL mode, then simply specify whatever USB-to-UART device you get, '/dev/ttyUSB0' probably, instead of '/dev/ttyACM0' with 'mpremote', 'minicom', Thonny, etc, and everything should just work, though I haven't tried it.

Statistics: Posted by hippy — Mon Jan 15, 2024 1:44 pm



Viewing all articles
Browse latest Browse all 4935

Trending Articles