MCPcopy Create free account
hub / github.com/RobTillaart/Arduino / millis2duration

Function millis2duration

libraries/dateTimeHelpers/dateTimeHelpers.h:187–207  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

185
186
187char * millis2duration(uint32_t millis)
188{
189 char * buf = __dateTimeHelperBuffer;
190
191 uint32_t t = millis / 1000;
192 seconds2duration(t, true);
193 uint8_t pos = strlen(buf);
194
195 uint16_t m = millis - t * 1000;
196 buf[pos++] = '.';
197 uint8_t d = m / 100;
198 buf[pos++] = d + '0';
199 m = m - d * 100;
200 d = m / 10;
201 buf[pos++] = d + '0';
202 d = m - d * 10;
203 buf[pos++] = d + '0';
204 buf[pos++] = '\0';
205
206 return buf;
207}
208
209
210char * millis2clock(uint32_t millis)

Callers

nothing calls this directly

Calls 1

seconds2durationFunction · 0.85

Tested by

no test coverage detected