mirror of
https://github.com/cesanta/mongoose.git
synced 2026-10-30 12:50:58 +00:00
add RT-Thread support
This commit is contained in:
1 parent
6794a89f79
commit
5be1c6381b
5 files changed
+58
No files matched your search
@@ -113,6 +113,8 @@ uint64_t mg_millis(void) {
|
||||
return (uint64_t)rt_time_get();
|
||||
#elif MG_ARCH == MG_ARCH_CMSIS_RTOS2
|
||||
return (uint64_t)((osKernelGetTickCount() * 1000) / osKernelGetTickFreq());
|
||||
#elif MG_ARCH == MG_ARCH_RTTHREAD
|
||||
return (uint64_t) ((rt_tick_get() * 1000) / RT_TICK_PER_SECOND);
|
||||
#elif MG_ARCH == MG_ARCH_UNIX && defined(__APPLE__)
|
||||
// Apple CLOCK_MONOTONIC_RAW is equivalent to CLOCK_BOOTTIME on linux
|
||||
// Apple CLOCK_UPTIME_RAW is equivalent to CLOCK_MONOTONIC_RAW on linux
|
||||
|
||||
Reference in new issue
Block a user