Tool/software: TI C/C++ Compiler
Hello experts,
I'm working on a software on a custom board that has CC2640. Our goal is to achieve 3 day run-time,however, we're only able to run it around~13 hours on 3.7V battery.
My code involves in sensor controller (SC) and the M3, where SC collects data from sensors and the cpu writes data to SD card. Through profiling, I notice the part that writes to SD card takes a lot of time. Specifically, after the SC collects 288 elements and put them into a buffer of size 288, the snprintf convert int to char array and write to SD card.
//for data from sensor 1 snprintf(value_arr_4b,5,"%04x",value); //for data from sensor 2 snprintf(value_arr_8b,9,"%08x",value);
The whole process (convert, write to SD card) for a cycle takes about 14 seconds to finish!! Is there anything I can do to speed up the process?
Also, I'm concerned about the power saving of the board, is there anything that people generally could do to save up more power?
Any help or pointer would be greatly appreciated