Hi everyone,
I'd like to implement RTC with calendar (I'm using TMS570LS0432). I did a brief search and I failed to find any example code.
So maybe someone could point me some literature and code example.
Thanks in advance, cheers.
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi everyone,
I'd like to implement RTC with calendar (I'm using TMS570LS0432). I did a brief search and I failed to find any example code.
So maybe someone could point me some literature and code example.
Thanks in advance, cheers.
Hello,
There is no example code that exists today that you can readily modify for your use. However, the concepts are fairly straightforward to implement. There is a low-power mode, termed as "doze mode", that you can use to keep track of real time even when the CPU and a significant amount of the MCU is disabled (clocks only).
The doze mode keeps the RTI module clocked using the main oscillator so that it can keep counting even when the rest of the clock domains and clock sources are disabled. The RTI can also generate periodic wake ups for the CPU to update the date/hour/minute/second/millisecond counters.
The low-power mode functionality is defined in the technical reference manual. Please let me know if you have trouble locating this information.
Regards,
Sunil
Hello,
Thank you for reply. I just want brief answer.
Does tick counter has to be made manually or is there a library? (If I'd like a calendar for upcoming 5 years, with all exceptions on different months lengths and so on..)
You can use HALCoGen to configure the RTI module to generate the required periodic interrupt using the main oscillator (OSCIN) as source for the RTICLK. You will need to create the software to manage the counters in RAM. We do not have any library code for this.
Regards, Sunil