Hi,I am working with nrf9160 and I am trying to get unix time in a user-readable form. I found this code online that helps me do that (github.com/.../main.c) but the header file <time.h> on zephyr was empty. Can someone help me with the source file/contents for time.h?
Hello, Can you provide some more information? What version of NCS are you running? Have a look at the Getting Started Guide and the nRF Connect SDK Tutorial. Kind regards,Øyvind
I'm using version 0.4.0. The time.h file that I'm referring to is at "ncs\zephyr\lib\libc\minimal\include\time.h". It's on github (https://github.com/zephyrproject-rtos/zephyr/blob/master/lib/libc/minimal/include/time.h).
Fundamentally what we want to do is take a unix time and convert is to the format used for the modem. As required here https://infocenter.nordicsemi.com/pdf/nrf91_at_commands_v0.9.1.pdf, the format needs to be changed to this "yy/MM/dd,hh:mm:ss±zz". What is your recommendation for the best method to do this?
I am looking for something like strftime
They're is an example here starting at line 45 but I can't get it to work github.com/.../main.c