Micropython on Sparkfun Thing Dev board

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
Sgtjake916
Posts: 3
Joined: Tue Aug 02, 2016 7:32 am

Micropython on Sparkfun Thing Dev board

Post by Sgtjake916 » Tue Aug 02, 2016 7:45 am

Hello,

Trying to flash the latest micropython to a Spark Fun Thing Dev board (esp8266). Everything builds without error and appears to flash fine, but when I try to connect via serial I get the below output.

I've try searching the forums and google not finding a fix. Can anyone assist?

Fatal exception 28(LoadProhibitedCause):
epc1=0x4024ff37, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00f90000, depc=0x00000000

ets Jan 8 2013,rst cause:1, boot mode:(3,6)

load 0x40100000, len 30816, room 16
tail 0
chksum 0x3e
load 0x3ffe8000, len 1044, room 8
tail 12
chksum 0x89
ho 0 tail 12 room 4
load 0x3ffe8420, len 3000, room 12
tail 12
chksum 0x97
csum 0x97
rnlbb8lllryr'bl8pp#l`rn8bblbbl`r8l #r8r8lrrlbrbb#nn llll;nbb>b|lrrrn<~6l8bl`l;#4 ets_task(40100368, 3, 3fff62f0, 4)


Thank you
J.

Sgtjake916
Posts: 3
Joined: Tue Aug 02, 2016 7:32 am

Micropython on SparkFun Thing Dev Board

Post by Sgtjake916 » Tue Aug 02, 2016 4:22 pm

Hello all,

I'm trying to get Micropython on a Sparkfun Thing Dev board based ESP8266. I can compile without error and flash the firmware to the board. Once flashed and I try to connect via serial at 115200 baud I get the following in the terminal. I've rebuild again and erased the flash before each time I flash the micropython bin. has anyone run into an issue like this?

Fatal exception 28(LoadProhibitedCause):
epc1=0x4024ff37, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00f90000, depc=0x00000000

ets Jan 8 2013,rst cause:1, boot mode:(3,6)

load 0x40100000, len 30816, room 16
tail 0
chksum 0x3e
load 0x3ffe8000, len 1044, room 8
tail 12
chksum 0x89
ho 0 tail 12 room 4
load 0x3ffe8420, len 3000, room 12
tail 12
chksum 0x97
csum 0x97
rnlbb8lllryr'bl8pp#l`rn8bblbbl`r8l #r8r8lrrlbrbb#nn llll;nbb>b|lrrrn<~6l8bl`l;#4 ets_task(40100368, 3, 3fff62f0, 4)

Thank you
J.

Sgtjake916
Posts: 3
Joined: Tue Aug 02, 2016 7:32 am

Re: Micropython on Sparkfun Thing Dev board

Post by Sgtjake916 » Mon Oct 03, 2016 6:27 am

So, I thought I would follow up my original post. Yes, it is possible to install Micropython on a Sparkfun ThingDev board. The issue was my compiled BIN file bigger then the 4 megabits of memory to the board. I found a small pre-compiled version in downloadsthat was smaller and it worked.

The question now is, how do you remove modules like neopixel and others I don't need and still be able compile a BIN small enough that includes my .py code to be run.

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

Re: Micropython on Sparkfun Thing Dev board

Post by Roberthh » Mon Oct 03, 2016 10:17 am

Hello @Sgtjake916, you have to buidl your own image & look at 3 places:
  • esp8266/modules and esp8266/scripts: These scripts are precompiled into the flash image. Remove everything you do not need and place your own scripts here. The stuff in esp8266/modules will be precompiled.
  • esp8266/Makefile: The biggest size reductin is achieved by setting: MICROPY_PY_BTREE = 0. This willl remove the btree database support and saves about 20k in the image.
  • esp8266/mpconfigport.h: Here are a lot of build options. If you set the one you do not need to 0, you'll save space. For instance you might not need APA102 support, and since the 4MBit flash has not file system, you might not need VFS_FAT. Doing that will drop the code size below 4 MBit. You may remove more packages since you will need space for your own modules in flash.

Post Reply