esp32 with 8mb spiram only 4mb detected

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
seandepagnier
Posts: 15
Joined: Tue Feb 25, 2020 5:10 pm

esp32 with 8mb spiram only 4mb detected

Post by seandepagnier » Fri Mar 20, 2020 4:43 pm

ips6404l-sq 8 meg ram chip

import gc
>>> gc.mem_free()
4093264
>>>


How do I get more ram?

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

Re: esp32 with 8mb spiram only 4mb detected

Post by jimmo » Fri Mar 20, 2020 11:57 pm

This is a limitation of the way the memory controller works -- there's more info in this thread from a few weeks ago: viewtopic.php?f=18&t=7843

seonr
Posts: 43
Joined: Mon Sep 10, 2018 6:54 am

Re: esp32 with 8mb spiram only 4mb detected

Post by seonr » Mon Mar 23, 2020 1:07 am

There are folks that develop with the IDF that do some RAM bank switching to get access to the entire 8MB, but we can't do that with MP when we are using the PSRAM for the heap as your heap would disappear ;)

This memory address space limitation is fixed in the new ESP32-S2 and newer chips.

Cheers,
Seon
Unexpected Maker

Post Reply