Part Number: CC2642R
Other Parts Discussed in Thread: UNIFLASH
Hello,
I am using CC2642R1 with latest ble 5 sdk. In my project I need to save datas in flash for all users. I tried to use osal_snv_read/write functions and also I tried to nvs functions.
- When I use osal_snv_read/write functions; it writes datas end of last data. I am calling osal_snv_write function with same page ID more than once and datas are written and the address of new data starts after where last one ends.
Here the problem is, let's say I have 2 data (x and y). First I am writing x ( osal_snv_write(0x101,sizeof(x),&x) ) then I am writing y ( osal_snv_write(0x101,sizeof(y),y) ). x and y are in non volatile memory end to end. The problem is when I call osal_snv_read function it starts to read the adress of beginning of where y is written. I tried to call a few times but every time it starts to read from where y is starting. So I can only read y and after y. How can I read x, then?