Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: oldheating gps motorhome heating
clk/clktm.c@46:d3d56cb47940, 2019-01-08 (annotated)
- Committer:
- andrewboyson
- Date:
- Tue Jan 08 14:06:41 2019 +0000
- Revision:
- 46:d3d56cb47940
- Parent:
- clock/clktm.c@41:8cd859cd1475
- Child:
- 54:a3c018ceca77
Changed main name from clock to clk
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
andrewboyson | 37:330b844f54b6 | 1 | #include <stdint.h> |
andrewboyson | 26:0421132e6eaf | 2 | #include <time.h> |
andrewboyson | 26:0421132e6eaf | 3 | |
andrewboyson | 37:330b844f54b6 | 4 | #include "tm.h" |
andrewboyson | 37:330b844f54b6 | 5 | #include "clktime.h" |
andrewboyson | 26:0421132e6eaf | 6 | |
andrewboyson | 41:8cd859cd1475 | 7 | void ClkTimeToTmLocal(int64_t time, struct tm* ptm) { TmLocalFromTimeT(time >> CLK_TIME_ONE_SECOND_SHIFT, ptm); } |
andrewboyson | 41:8cd859cd1475 | 8 | void ClkTimeToTmUtc (int64_t time, struct tm* ptm) { TmUtcFromTimeT(time >> CLK_TIME_ONE_SECOND_SHIFT, ptm); } |
andrewboyson | 41:8cd859cd1475 | 9 | int64_t ClkTimeFromTmUtc( struct tm* ptm) { return ((int64_t)TmUtcToTimeT(ptm)) << CLK_TIME_ONE_SECOND_SHIFT ; } |