Can't build the ESP8266 port

All ESP8266 boards running MicroPython.
Official boards are the Adafruit Huzzah and Feather boards.
Target audience: MicroPython users with an ESP8266 board.
Post Reply
gscofano
Posts: 3
Joined: Wed Dec 22, 2021 4:13 am

Can't build the ESP8266 port

Post by gscofano » Wed Dec 22, 2021 4:55 am

Greetings,

I need to load a Python module in a Wemos ESP8266 wi-fi board with 4kB of Flash. The module in question is Tronpy. I'm facing some memory allocation errors and, reading https://docs.micropython.org/en/latest/ ... kages.html, I understood that I should compile my module into bytecode. Such procedure would shrink the module size, making it easier to fit inside my device. I understand that, in order to do that, I need mpy-cross and the ESP8266 port.

I downloaded the micropython-1.17 source code from Github and I'm following the instructions on the README files. I understood that the first thing I should do was to compile mpy-cross. So I entered the comands:

Code: Select all

cd mpy-cross/
make 
mpy-cross was compiled without problems.

My next step was to compile ports/esp8266. According to the README.md file in such directory, the recomnended approach was to use a docker image. On the root directory of the project, I entered the following commands:

Code: Select all

docker run --rm -v $HOME:$HOME -u $UID -w $PWD larsks/esp-open-sdk make -C ports/esp8266 submodules 
After this, I'm getting the following error messages:

Code: Select all

make: Entering directory '/home/gscofano/Documentos/dev/micropython/micropython-1.17_2/ports/esp8266'
make: stat: Makefile: Permission denied
make: *** No rule to make target 'submodules'.  Stop.
make: Leaving directory '/home/gscofano/Documentos/dev/micropython/micropython-1.17_2/ports/esp8266'
My docker seems to be correctly configured. When I issue

Code: Select all

 docker run hello-world 
docker sends me a message indicating that it was able to connect to the image from the Docker Hub ("Hello from Docker! This message shows that your installation appears to be working correctly. etc.")

I belive I followed all the instructions on the README files correctly. What could I possibly be missing? Is there any easier way to load a module in Micropython?

Thank you very much in advance.

wr300000
Posts: 32
Joined: Sun Jan 14, 2018 3:54 pm

Re: Can't build the ESP8266 port

Post by wr300000 » Sat Feb 26, 2022 2:15 pm

Try this from jimmo
viewtopic.php?f=15&t=7136#p40603
BTW, It's working on amd64 CPU

Post Reply