AWS IoT Device SDK C  202011.00
SDK for connecting to AWS IoT from a device using embedded C.
clock_posix.c File Reference

Implementation of the functions in clock.h for POSIX systems. More...

#include <time.h>
#include "clock.h"

Macros

#define NANOSECONDS_PER_MILLISECOND   ( 1000000L )
 Nanoseconds per millisecond.
 
#define MILLISECONDS_PER_SECOND   ( 1000L )
 Milliseconds per second.
 

Functions

uint32_t Clock_GetTimeMs (void)
 The timer query function. More...
 
void Clock_SleepMs (uint32_t sleepTimeMs)
 Millisecond sleep function. More...
 

Detailed Description

Implementation of the functions in clock.h for POSIX systems.

Function Documentation

◆ Clock_GetTimeMs()

uint32_t Clock_GetTimeMs ( void  )

The timer query function.

This function returns the elapsed time.

Returns
Time in milliseconds.

◆ Clock_SleepMs()

void Clock_SleepMs ( uint32_t  sleepTimeMs)

Millisecond sleep function.

Parameters
[in]sleepTimeMsmilliseconds to sleep.