-->
Page 1 of 1

parse JSON larger than onboard memory? MicroPython

PostPosted: Tue Apr 23, 2019 7:47 pm
by derek bernsen
Hi all,

I am looking at different ways of storing settings for an ESP MicroPython MCU with the settings being larger than what can be stored in EEPROM.

My main question is: If I store the large JSON formatted settings file on an external server that the ESP can pull from, can the ESP parse settings from that JSON file even if the whole JSON file is larger than onboard memory?

I guess I am asking if MicroPython urequests library has a memory limit and does the MCU need to download the entire JSON file to onboard memory? Has this been done before?

Re: parse JSON larger than onboard memory? MicroPython

PostPosted: Wed Apr 24, 2019 3:17 am
by marcelstoer
Can you work with ujson.load(stream)? https://docs.micropython.org/en/latest/ ... ujson.load

Re: parse JSON larger than onboard memory? MicroPython

PostPosted: Wed May 01, 2019 12:29 pm
by derek bernsen
Solved it by developing a external backend for my esp8266 to poll that serves the Json in miniature sections.

https://github.com/donovanmagryta/trainable-esp8266-led