This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

how to use sram

i am using nrf24le1 contyroller can anyone tell me how to use the 1k sram.what is the datatype for using this and what are the compiler settings in using this.i am using keil comipler

Parents
  • By default the Memory Model is Small:variable in DATA meaning all variable is in the internal RAM. If you want to put a variable/array into SRAM or XDATA you can simply add xdata as prefix when you declare.

    For example: xdata uint8_t payload[300];

    If you want to put everything in XDATA, you can select Large model. Then everything is slower as the CPU have to access SRAM.

Reply
  • By default the Memory Model is Small:variable in DATA meaning all variable is in the internal RAM. If you want to put a variable/array into SRAM or XDATA you can simply add xdata as prefix when you declare.

    For example: xdata uint8_t payload[300];

    If you want to put everything in XDATA, you can select Large model. Then everything is slower as the CPU have to access SRAM.

Children
No Data
Related