Hi ,
I am using PCA10001 board.
Now i want create 4k buffer in RAM. Which is good way allocate memory to 4k buffer.
Can i use dynamic(malloc function) or static memory allocation.
in my case code is also larger.
Regards Balaji
Hi ,
I am using PCA10001 board.
Now i want create 4k buffer in RAM. Which is good way allocate memory to 4k buffer.
Can i use dynamic(malloc function) or static memory allocation.
in my case code is also larger.
Regards Balaji
Now i want create 4k buffer in RAM. Which is good way allocate memory to 4k buffer.
Can i use dynamic(malloc function) or static memory allocation.
The SDK does not uses dynamic memory allocation, so if you wanted to use that you'd have to implement your own memory management scheme.
If you have enough room, you can simply statically define your buffer, but 4KB sounds a bit excessive.
I have some variables , and there contents should not delete even though
device is switched off. Can you say how can i achieve this .
Kindly give some examples.
Regards Balaji
If you need to keep data when the device is powered off, you have to write the data to flash. This has been covered quite extensively here on Developer Zone previously, so I'd recommend you to search around a little and have a look. Basically, you have to use the radio notification feature to avoid writing to flash when the softdevice needs to run the CPU.