W600-PICO region FLASH overflowed

Discussion and questions about boards that can run MicroPython but don't have a dedicated forum.
Target audience: Everyone interested in running MicroPython on other hardware.
federico
Posts: 34
Joined: Tue Feb 07, 2017 11:34 pm

Re: W600-PICO region FLASH overflowed

Post by federico » Fri Aug 28, 2020 5:00 pm

machine_uart_rhh_OK.png
wm_tool
machine_uart_rhh_OK.png (132.61 KiB) Viewed 3783 times
wm_tool.exe must be copied from WM_SDK/Tools to micropython_rhh/ports/w60x/tools

federico
Posts: 34
Joined: Tue Feb 07, 2017 11:34 pm

Re: W600-PICO region FLASH overflowed

Post by federico » Fri Aug 28, 2020 5:03 pm

download_fls.PNG
fls image download
download_fls.PNG (77 KiB) Viewed 3781 times

federico
Posts: 34
Joined: Tue Feb 07, 2017 11:34 pm

Re: W600-PICO region FLASH overflowed

Post by federico » Mon Sep 14, 2020 10:24 am

Minor change to Makefile in micropython/port/w60x directory.
To avoid a wrong output by the function w600.version() due to 2M Flash size setting it is sufficient to change the Makefile line 347 from:

CFLAG += -DW60X_USE_2M_FLASH=1
to:

CFLAG += -DW60X_USE_1M_FLASH=1

as clearly shown in the attached picture
W600-PICO_IDE&cmdLine_Tools_plus_HTB_upy_firmware_150900.jpg
w600.version() wrong output
W600-PICO_IDE&cmdLine_Tools_plus_HTB_upy_firmware_150900.jpg (260.8 KiB) Viewed 3720 times

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: W600-PICO region FLASH overflowed

Post by Roberthh » Mon Sep 14, 2020 10:48 am

That's OK. But I do not use the 2M flash setting in my build. Instead I modified the file link_w600_1m.ld allowing more space for the firmware.

phytoguy
Posts: 2
Joined: Sat Oct 10, 2020 10:06 pm

Re: W600-PICO region FLASH overflowed

Post by phytoguy » Sat Oct 24, 2020 6:09 am

Hi Roberthh,

I successfully compiled your most recent 10-23-2020 w60x micropython for the w600-pico and have been successfully compiling and using recent versions with much success. Specifically I am using it for IoT with mqtt; this works fine.

Most recently, I'm getting an ImportError: no module named 'ussl' when I import urequests and try to use it:

Image

Do you have any suggestions?

Thanks.

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: W600-PICO region FLASH overflowed

Post by Roberthh » Sat Oct 24, 2020 6:55 am

For ussl you have to set in Makefile:

MICROPY_SSL_MBEDTLS = 1

This is normally only enabled for 2Mbyte flash devices, which are hard to get. Setting the flash as above, the code area may overflow. Then you have to increase it in tools/link_w600_1m.ld, line 10.

federico
Posts: 34
Joined: Tue Feb 07, 2017 11:34 pm

Re: W600-PICO region FLASH overflowed

Post by federico » Tue Nov 03, 2020 11:12 am

To confirm roberthh
Attachments
TLS_e.png
WEB Weather Forecast Example
TLS_e.png (260.18 KiB) Viewed 3492 times
1MB_Flash_MBEDTLS.png
MBEDTLS Makefile flags
1MB_Flash_MBEDTLS.png (86.84 KiB) Viewed 3492 times
1_ssl_test_00.PNG
micropython modules
1_ssl_test_00.PNG (186.89 KiB) Viewed 3492 times

Post Reply