[STM32] Errors when building with W5500

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.
Post Reply
User avatar
SunWukong
Posts: 11
Joined: Thu Jan 16, 2020 2:22 pm
Contact:

[STM32] Errors when building with W5500

Post by SunWukong » Mon Dec 13, 2021 10:27 pm

First I built the firmware, uploaded it via DFU and did first tests with Thonny, so far so good. Then I wanted to use my W5500 module also in MicroPython and built the firmware with the option MICROPY_PY_WIZNET5K=5500, here I got a bunch of errors. What did I do wrong?

Code: Select all

mike@mpc4:~/micropython/ports/stm32$ make BOARD=BLACK_F407VE MICROPY_PY_WIZNET5K=5500
Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.
GEN build-BLACK_F407VE/genhdr/mpversion.h
mkdir -p build-BLACK_F407VE/drivers/wiznet5k/ethernet/
mkdir -p build-BLACK_F407VE/drivers/wiznet5k/ethernet/w5500/
mkdir -p build-BLACK_F407VE/drivers/wiznet5k/internet/dns/
CC ../../extmod/moduplatform.c
CC ../../shared/runtime/pyexec.c
CC moduos.c
CC network_wiznet5k.c
network_wiznet5k.c: In function 'wiznet5k_make_new':
network_wiznet5k.c:272:32: error: comparison of distinct pointer types lacks a cast [-Werror]
     if (wiznet5k_obj.base.type == &mod_network_nic_type_wiznet5k) {
                                ^~
network_wiznet5k.c:280:28: error: assignment to 'const mp_obj_type_t *' {aka 'const struct _mp_obj_type_t *'} from incompatible pointer type 'const struct _mod_network_nic_type_t *' [-Werror=incompatible-pointer-types]
     wiznet5k_obj.base.type = &mod_network_nic_type_wiznet5k;
                            ^
In file included from ../../py/mpstate.h:35,
                 from ../../py/runtime.h:29,
                 from network_wiznet5k.c:30:
network_wiznet5k.c: At top level:
network_wiznet5k.c:454:19: error: 'MP_QSTR_send_ethernet' undeclared here (not in a function); did you mean 'MP_QSTR_pend_throw'?
     { MP_ROM_QSTR(MP_QSTR_send_ethernet), MP_ROM_PTR(&send_ethernet_obj) },
                   ^~~~~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
network_wiznet5k.c:454:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_send_ethernet), MP_ROM_PTR(&send_ethernet_obj) },
       ^~~~~~~~~~~
network_wiznet5k.c:458:21: error: conflicting types for 'mod_network_nic_type_wiznet5k'
 const mp_obj_type_t mod_network_nic_type_wiznet5k = {
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../../py/mpconfig.h:62,
                 from ../../py/mpstate.h:31,
                 from ../../py/runtime.h:29,
                 from network_wiznet5k.c:30:
./mpconfigport.h:256:45: note: previous declaration of 'mod_network_nic_type_wiznet5k' was here
 extern const struct _mod_network_nic_type_t mod_network_nic_type_wiznet5k;
                                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
network_wiznet5k.c:460:13: error: 'MP_QSTR_WIZNET5K' undeclared here (not in a function); did you mean 'MP_QSTR_UINT8'?
     .name = MP_QSTR_WIZNET5K,
             ^~~~~~~~~~~~~~~~
             MP_QSTR_UINT8
network_wiznet5k.c:460:13: error: initialization of 'short unsigned int' from 'const mp_rom_map_elem_t *' {aka 'const struct _mp_rom_map_elem_t *'} makes integer from pointer without a cast [-Werror=int-conversion]
network_wiznet5k.c:460:13: note: (near initialization for 'mod_network_nic_type_wiznet5k.name')
network_wiznet5k.c:460:13: error: initializer element is not constant
network_wiznet5k.c:460:13: note: (near initialization for 'mod_network_nic_type_wiznet5k.name')
cc1: all warnings being treated as errors
make: *** [../../py/mkrules.mk:77: build-BLACK_F407VE/network_wiznet5k.o] Fehler 1

User avatar
SunWukong
Posts: 11
Joined: Thu Jan 16, 2020 2:22 pm
Contact:

Re: [STM32] Errors when building with W5500

Post by SunWukong » Tue Dec 14, 2021 4:28 pm

In the meantime, I have made tests with several STM32 boards that are available to me:
ADAFRUIT_F405_EXPRESS, BLACK_F407VE, PYBV11 and WEACT_H750
Since all boards are affected, I have renamed the subject from [BLACK_F407VE] to [STM32].

Originally I followed the instructions in Getting Started. I already had a fork of MicroPython, so I took the following steps.

Code: Select all

git clone https://github.com/mitag/micropython
// Configure remote upstream
cd ~/micropython/
git checkout -b dev-branch
// Install the required dependencies for Linux:
sudo apt install build-essential libffi-dev git pkg-config
// For the stm32 port, the ARM cross-compiler is required:
// sudo apt-get install arm-none-eabi-gcc arm-none-eabi-binutils arm-none-eabi-newlib
sudo apt install gcc-arm-none-eabi binutils-arm-none-eabi libnewlib-arm-none-eabi

// --------------------------

// Building the firmware 
cd boards
git clone https://github.com/mcauser/BLACK_F407VE
cd ..
make BOARD=BLACK_F407VE

LINK build-BLACK_F407VE/firmware.elf
   text    data     bss     dec     hex filename
 459028      80   80892  540000   83d60 build-BLACK_F407VE/firmware.elf
GEN build-BLACK_F407VE/firmware0.bin
GEN build-BLACK_F407VE/firmware1.bin
GEN build-BLACK_F407VE/firmware.dfu
GEN build-BLACK_F407VE/firmware.hex

// Flashing via DFU
make BOARD=BLACK_F407VE deploy
Writing build-BLACK_F407VE/firmware.dfu to the board
File: build-BLACK_F407VE/firmware.dfu
    b'DfuSe' v1, image size: 459413, targets: 1
    b'Target' 0, alt setting: 0, name: "ST...", size: 459128, elements: 2
      0, address: 0x08000000, size: 14656
      1, address: 0x08020000, size: 444456
    usb: 0483:df11, device: 0x0000, dfu: 0x011a, b'UFD', 16, 0xa3626c2d
Writing memory...
0x08000000   14656 [=========================] 100% 
0x08020000  444456 [=========================] 100% 
Exiting DFU...
Finished
After several unsuccessful attempts to include the W5X00 driver in the firmware (here are only the best of to see),

Code: Select all

mike@mpc4:~/micropython/ports/stm32$ make BOARD=WEACT_H750 MICROPY_PY_WIZNET5K=5500 MICROPY_PY_LWIP=1
Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.
GEN build-WEACT_H750/genhdr/qstrdefs.collected.h
QSTR not updated
GEN build-WEACT_H750/genhdr/compressed.collected
Compressed data not updated
CC ../../extmod/modlwip.c
In file included from ../../py/objlist.h:29,
                 from ../../extmod/modlwip.c:32:
../../extmod/modlwip.c:1564:19: error: 'MP_QSTR_sendall' undeclared here (not in a function); did you mean 'MP_QSTR_gencall'?
     { MP_ROM_QSTR(MP_QSTR_sendall), MP_ROM_PTR(&lwip_socket_sendall_obj) },
                   ^~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1564:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_sendall), MP_ROM_PTR(&lwip_socket_sendall_obj) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1568:19: error: 'MP_QSTR_makefile' undeclared here (not in a function); did you mean 'MP_QSTR_mktime'?
     { MP_ROM_QSTR(MP_QSTR_makefile), MP_ROM_PTR(&lwip_socket_makefile_obj) },
                   ^~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1568:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_makefile), MP_ROM_PTR(&lwip_socket_makefile_obj) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1742:50: error: 'MP_QSTR_lwip' undeclared here (not in a function); did you mean 'MP_QSTR_zip'?
     { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_lwip) },
                                                  ^~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1742:38: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_lwip) },
                                      ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1742:38: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_lwip) },
                                      ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[0].value')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1742:38: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_lwip) },
                                      ^~~~~~~~~~~
../../extmod/modlwip.c:1746:19: error: 'MP_QSTR_print_pcbs' undeclared here (not in a function); did you mean 'MP_QSTR_print'?
     { MP_ROM_QSTR(MP_QSTR_print_pcbs), MP_ROM_PTR(&lwip_print_pcbs_obj) },
                   ^~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1746:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_print_pcbs), MP_ROM_PTR(&lwip_print_pcbs_obj) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1746:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_print_pcbs), MP_ROM_PTR(&lwip_print_pcbs_obj) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[4].key')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1746:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_print_pcbs), MP_ROM_PTR(&lwip_print_pcbs_obj) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1762:19: error: 'MP_QSTR_SOL_SOCKET' undeclared here (not in a function); did you mean 'MP_QSTR_SOFT_RESET'?
     { MP_ROM_QSTR(MP_QSTR_SOL_SOCKET), MP_ROM_INT(1) },
                   ^~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1762:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SOL_SOCKET), MP_ROM_INT(1) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1762:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SOL_SOCKET), MP_ROM_INT(1) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[11].key')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1762:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SOL_SOCKET), MP_ROM_INT(1) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1763:19: error: 'MP_QSTR_SO_REUSEADDR' undeclared here (not in a function); did you mean 'MP_QSTR_SOFT_RESET'?
     { MP_ROM_QSTR(MP_QSTR_SO_REUSEADDR), MP_ROM_INT(SOF_REUSEADDR) },
                   ^~~~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1763:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SO_REUSEADDR), MP_ROM_INT(SOF_REUSEADDR) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1763:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SO_REUSEADDR), MP_ROM_INT(SOF_REUSEADDR) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[12].key')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1763:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_SO_REUSEADDR), MP_ROM_INT(SOF_REUSEADDR) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1765:19: error: 'MP_QSTR_IPPROTO_IP' undeclared here (not in a function); did you mean 'MP_QSTR_PERIODIC'?
     { MP_ROM_QSTR(MP_QSTR_IPPROTO_IP), MP_ROM_INT(0) },
                   ^~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1765:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IPPROTO_IP), MP_ROM_INT(0) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1765:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IPPROTO_IP), MP_ROM_INT(0) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[13].key')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1765:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IPPROTO_IP), MP_ROM_INT(0) },
       ^~~~~~~~~~~
../../extmod/modlwip.c:1766:19: error: 'MP_QSTR_IP_ADD_MEMBERSHIP' undeclared here (not in a function); did you mean 'IP_ADD_MEMBERSHIP'?
     { MP_ROM_QSTR(MP_QSTR_IP_ADD_MEMBERSHIP), MP_ROM_INT(IP_ADD_MEMBERSHIP) },
                   ^~~~~~~~~~~~~~~~~~~~~~~~~
../../py/obj.h:96:56: note: in definition of macro 'MP_OBJ_NEW_QSTR'
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                                                        ^~~
../../extmod/modlwip.c:1766:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IP_ADD_MEMBERSHIP), MP_ROM_INT(IP_ADD_MEMBERSHIP) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: error: initializer element is not constant
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1766:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IP_ADD_MEMBERSHIP), MP_ROM_INT(IP_ADD_MEMBERSHIP) },
       ^~~~~~~~~~~
../../py/obj.h:96:30: note: (near initialization for 'mp_module_lwip_globals_table[14].key')
 #define MP_OBJ_NEW_QSTR(qst) ((mp_obj_t)((((mp_uint_t)(qst)) << 3) | 2))
                              ^
../../py/obj.h:308:24: note: in expansion of macro 'MP_OBJ_NEW_QSTR'
 #define MP_ROM_QSTR(q) MP_OBJ_NEW_QSTR(q)
                        ^~~~~~~~~~~~~~~
../../extmod/modlwip.c:1766:7: note: in expansion of macro 'MP_ROM_QSTR'
     { MP_ROM_QSTR(MP_QSTR_IP_ADD_MEMBERSHIP), MP_ROM_INT(IP_ADD_MEMBERSHIP) },
       ^~~~~~~~~~~
make: *** [../../py/mkrules.mk:77: build-WEACT_H750/extmod/modlwip.o] Fehler 1

Code: Select all

mike@mpc4:~/micropython/ports/stm32$ make clean
Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.
rm -rf build-PYBV10 
mike@mpc4:~/micropython/ports/stm32$ make BOARD=PYBV11 MICROPY_PY_WIZNET5K=5500 MICROPY_PY_LWIP=1
Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.
CC mpnetworkport.c
mpnetworkport.c: In function 'pyb_lwip_poll':
mpnetworkport.c:58:5: error: implicit declaration of function 'wiznet5k_poll' [-Werror=implicit-function-declaration]
     wiznet5k_poll();
     ^~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [../../py/mkrules.mk:77: build-PYBV11/mpnetworkport.o] Fehler 1
I dug through the forum, code, the issues and various README.md on github.com/micropython/micropython, as well as the net using search engines.
After this hint I cloned micropython/miropython again:
Re: Pyboard + W5500/W5200 Ethernet - Cant get it to work - MicroPython v1.11-422-g98c2eabaf
wangshujun@tom.com wrote:
Wed Nov 17, 2021 1:26 am
Download the package of 1.17 + daily update package from the official website, and the compilation will report the above error
If you clone directly from GitHub, the compilation is correct
Unfortunately, in my case, I could not confirm this advice.

Code: Select all

// due to a hint in the forum, I clone directly without diversions via my fork.
mike@mpc4:~/micropython$ cd ~
mike@mpc4:~$ mkdir mp.org
mike@mpc4:~$ cd mp.org/
mike@mpc4:~/mp.org$ git clone https://github.com/micropython/micropython
mike@mpc4:~/mp.org$ cd micropython/
mike@mpc4:~/mp.org/micropython$ git submodule update --init
mike@mpc4:~/mp.org/micropython$ cd ports/stm32/
mike@mpc4:~/mp.org/micropython/ports/stm32$ make BOARD=PYBV11 submodules
mike@mpc4:~/mp.org/micropython$ make BOARD=PYBV11 MICROPY_PY_WIZNET5K=5500 MICROPY_PY_LWIP=1
// there are more errors instead of fewer
For all boards, except for the PYBV11, I can create firmware without W5x00 in ~/micropython/ports/stm32 as well as in ~/mp.org/micropython/ports/stm32, flash it and get to the respective REPL prompt with Thonny. Unfortunately, I can't say why I can't generate any firmware for the PYBV11 and since when. The board had slipped between some LCDs and I only found it after an extensive search.

At some point I got into the habit of recording every step and in such cases I am extremely happy about it, even if I am actually too lazy to write so much and copy written as well as resulting messages.

bartag
Posts: 4
Joined: Sat Jan 16, 2021 9:33 pm

Re: [STM32] Errors when building with W5500

Post by bartag » Wed Dec 29, 2021 9:49 pm

Hi @SunWukong

Did you find a solution for this error?

Post Reply