Memmory issue

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
Jurkylius
Posts: 7
Joined: Fri Oct 02, 2020 11:46 am

Memmory issue

Post by Jurkylius » Sat Nov 07, 2020 9:03 pm

Hello,
I write some topic month ago of my problem with memory.
I using Esp32 Devkit v1.2 standard from aliexpress. First write code I use C with arduino. Now I rewrite code into python. Have uart display comunication and modules as DS3231, sdcard and others sensors (temperature, humidity, soil moisture, water level). All this information using control for relay module. Standard part of program working good but when I want use sd card or connect wifi program print error with memory allocation. I trying reduce code and less using lists but still have problem. I want ask you for any idea how I can doing. In web I find freezing code or I need buy better esp32 chip? I using to much time for this and really need help.
Thanks for any answers.

User avatar
pythoncoder
Posts: 5956
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: Memmory issue

Post by pythoncoder » Sun Nov 08, 2020 10:20 am

Have you read this doc? It has advice on avoiding RAM allocation issues.
Peter Hinch
Index to my micropython libraries.

Jurkylius
Posts: 7
Joined: Fri Oct 02, 2020 11:46 am

Re: Memmory issue

Post by Jurkylius » Sun Nov 08, 2020 5:39 pm

Yes I read this and applied everything what I know.
Now I need know what more can doing? Maybe I dont good understand all rule off this memmory saving.
It can be I want too many of this device.

User avatar
jimmo
Posts: 2754
Joined: Tue Aug 08, 2017 1:57 am
Location: Sydney, Australia
Contact:

Re: Memmory issue

Post by jimmo » Mon Nov 09, 2020 7:07 am

Freezing code will definitely help as it will no longer have to store the bytecode in RAM.

See my replies to this twitter thread earlier today for some more hints on avoiding memory fragmentation -- https://twitter.com/alexeckermann/statu ... 9415301120

Post Reply