I want to write numbers in my flash memory so I used this function "nrf_nvmc_write_words" but in it couldn't save float numbers in my flash memory
it is like that in nrf_nvmc.c file:
void nrf_nvmc_write_words(uint32_t address, const float * src, uint32_t num_words)
{
uint32_t i;
// Enable write.
NRF_NVMC->CONFIG = NVMC_CONFIG_WEN_Wen;
__ISB();
__DSB();
for (i = 0; i < num_words; i++)
{
((uint32_t*)address)[i] = src[i];
wait_for_flash_ready();
}
NRF_NVMC->CONFIG = NVMC_CONFIG_WEN_Ren;
__ISB();
__DSB();
}
I did some modification and wrote float instead of uint32_t but it couldn't work so have you any suggestion please?