Micropython esp8266 firmware build

C programming, build, interpreter/VM.
Target audience: MicroPython Developers.
Post Reply
Nikunj_Vadher
Posts: 13
Joined: Mon Dec 10, 2018 6:37 am

Micropython esp8266 firmware build

Post by Nikunj_Vadher » Sun Dec 16, 2018 7:36 am

Respected Forum Members,

I am looking for compiling micropython firmware guide for linux (Ubuntu). lots of guides available but every guide showing different error so not able to compile it properly.

I also want to know how to remove unnecessary packages ( modules) from firmware so I can free some more space and use memory for my modules.

I am using nodemcu with esp8266 4MB memory.

Thank You.

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

Re: Micropython esp8266 firmware build

Post by Roberthh » Sun Dec 16, 2018 8:43 am

The README.md in ports/esp8266 is sufficient. You only have to follow the instructions literally, not skipping a step or ignoring a word, including the README in the installed esp-idf.

About not installing modules:
in the esp8266 directory there is a file called mpconfigport.h, which includes defines for a lot of options. Other places to look for is the initial section of Makefile, where the support for BTREE, AXTLS and USSL is activated. Not building BTREE for instance saves about 25k flash space. You may also look into esp8266/modules and consider, which of them you need. Although there is little space to gather.

Nikunj_Vadher
Posts: 13
Joined: Mon Dec 10, 2018 6:37 am

Re: Micropython esp8266 firmware build

Post by Nikunj_Vadher » Tue Dec 18, 2018 4:53 am

Roberthh wrote:
Sun Dec 16, 2018 8:43 am
The README.md in ports/esp8266 is sufficient. You only have to follow the instructions literally, not skipping a step or ignoring a word, including the README in the installed esp-idf.

About not installing modules:
in the esp8266 directory there is a file called mpconfigport.h, which includes defines for a lot of options. Other places to look for is the initial section of Makefile, where the support for BTREE, AXTLS and USSL is activated. Not building BTREE for instance saves about 25k flash space. You may also look into esp8266/modules and consider, which of them you need. Although there is little space to gather.
Thank you for guiding and giving response. Compiled it sucessfully.

Post Reply