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

FDS error in FDS_VIRTUAL_PAGE_SIZE 1024 ?? (NRF51)

FDS error in FDS_VIRTUAL_PAGE_SIZE 1024 ?? (NRF51)

github.com/.../nRF52-fds-example

If I use FDS_VIRTUAL_PAGES 3, FDS_VIRTUAL_PAGE_SIZE 1024, then there comes FDS_ERR_BUSY. DO I HAVE TO GIVE DELAY BETWEEN fds_register fds_init??

(I'd like to save about 3KB size Structure. So, PAGE_SIZE(1024)*4byte = 4KB might be needed.)

(This Error doesn't occurs in FDS_VIRTUAL_PAGE_SIZE 512. Why this error happens?) (I've initialized FDS same as upper github example.)

My SDK is v12.2.0

(ps. how can I manually reset fds's record_desc.record_id of fds_record_desc_t?)
it's type is uint32_t, and it's increasing infinitely when I run this.
how can I reset this record_id to 0 ??

Parents
  • Hi,

    1. No, you don't need to wait after fds_register() before calling fds_init(): you can call fds_init() as soon as you have returned from fds_register().

    2. You understand correctly, the page size should be at least 1024 (4096 bytes) to store a 3KB structure.

    3. You cannot change or control the ID of a record in any way. It is assigned by fds automatically. However, you can control the record KEY and file ID.

    Where do you receive the FDS_ERR_BUSY return code? Does it come in an event? Is it returned by a function? If so which one?

  • Yeah, I've calculated as it is, from here : devzone.nordicsemi.com/.../

    and the code is 56kb, + Softdevice 107 kb so there will be more than 12kb space. (nRF51QFAC)

    and also, I thought If I set more size than the available size, than My FDS Pages will overwrite the code section. So in this point of view, Setting more than available size might occur errors with my source code, but It works well! (well I'm not sure it's running well, but I thought there might be some problem with running source code, so It might not be run at all but it works a bit.)

Reply
  • Yeah, I've calculated as it is, from here : devzone.nordicsemi.com/.../

    and the code is 56kb, + Softdevice 107 kb so there will be more than 12kb space. (nRF51QFAC)

    and also, I thought If I set more size than the available size, than My FDS Pages will overwrite the code section. So in this point of view, Setting more than available size might occur errors with my source code, but It works well! (well I'm not sure it's running well, but I thought there might be some problem with running source code, so It might not be run at all but it works a bit.)

Children
No Data
Related