External ram config explanation

snahmad75
Posts: 445
Joined: Wed Jan 24, 2018 6:32 pm

External ram config explanation

Postby snahmad75 » Sat Feb 09, 2019 1:34 pm

#
# SPI RAM config
#
CONFIG_SPIRAM_BANKSWITCH_ENABLE=y
CONFIG_SPIRAM_BANKSWITCH_RESERVE=8
CONFIG_SPIRAM_MALLOC_ALWAYSINTERNAL=4096
CONFIG_WIFI_LWIP_ALLOCATION_FROM_SPIRAM_FIRST=
CONFIG_SPIRAM_MALLOC_RESERVE_INTERNAL=45768
CONFIG_SPIRAM_ALLOW_STACK_EXTERNAL_MEMORY=
CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY=y


Can some one explain these settings. any recommended setting by default.

Ritesh
Posts: 1383
Joined: Tue Sep 06, 2016 9:37 am
Location: India
Contact:

Re: External ram config explanation

Postby Ritesh » Sun Feb 10, 2019 9:51 am

snahmad75 wrote:
Sat Feb 09, 2019 1:34 pm
#
# SPI RAM config
#
CONFIG_SPIRAM_BANKSWITCH_ENABLE=y
CONFIG_SPIRAM_BANKSWITCH_RESERVE=8
CONFIG_SPIRAM_MALLOC_ALWAYSINTERNAL=4096
CONFIG_WIFI_LWIP_ALLOCATION_FROM_SPIRAM_FIRST=
CONFIG_SPIRAM_MALLOC_RESERVE_INTERNAL=45768
CONFIG_SPIRAM_ALLOW_STACK_EXTERNAL_MEMORY=
CONFIG_SPIRAM_ALLOW_BSS_SEG_EXTERNAL_MEMORY=y


Can some one explain these settings. any recommended setting by default.
Hi,

Which ESP32 IDF you are using? Also are you trying to enable external SPI PSRAM?

First of all, try with default example provided into default config file then you can enable BSS, Stack and other sections as per your requirement.
Regards,
Ritesh Prajapati

snahmad75
Posts: 445
Joined: Wed Jan 24, 2018 6:32 pm

Re: External ram config explanation

Postby snahmad75 » Sun Feb 10, 2019 7:38 pm

Hi,

I am using latest ESP32 IDF version=3.2. Yes I know i am using external SPI PSRAM.


I am also tried with default example provided into default config file. After this remaining internal RAM is low about 50k. not enough for my application.

I changed to enable BSS, Stack then I got remaining internal RAM of about 70k. I wonder it cause slow processing of my application. as one of Task watch dog kicks in. not enough processing. It could be slow due to external ram usage.

Ritesh
Posts: 1383
Joined: Tue Sep 06, 2016 9:37 am
Location: India
Contact:

Re: External ram config explanation

Postby Ritesh » Mon Feb 11, 2019 1:12 am

snahmad75 wrote:
Sun Feb 10, 2019 7:38 pm
Hi,

I am using latest ESP32 IDF version=3.2. Yes I know i am using external SPI PSRAM.


I am also tried with default example provided into default config file. After this remaining internal RAM is low about 50k. not enough for my application.

I changed to enable BSS, Stack then I got remaining internal RAM of about 70k. I wonder it cause slow processing of my application. as one of Task watch dog kicks in. not enough processing. It could be slow due to external ram usage.
Would you please check CPU clock frequency at that time? Is it maximum after enabling SPI PSRAM?

I belive it should not impact into existing working system if you enable external RAM configuration. Still, Please make sure rest of configurations are proper or not.

Also would you please try with disabling external with same application and working fine as per your requirements?

If that is working then need to check into details specific to external RAM configuration and component section.
Regards,
Ritesh Prajapati

Who is online

Users browsing this forum: Bing [Bot] and 194 guests