SysIo  1.9.0
Embedded Library and tools
Sysio::Clock Class Reference

Horloge. More...

#include <clock.h>

Public Member Functions

 Clock ()
 Constructor. More...
 
unsigned long micros ()
 Number of microseconds. More...
 
unsigned long millis ()
 Number of milliseconds. More...
 
virtual ~Clock ()
 Destructor.
 

Static Public Member Functions

static void delay (unsigned long ms)
 Pauses for the amount of milliseconds. More...
 
static void delayMicroseconds (unsigned long us)
 Pauses for the amount of microseconds. More...
 
static void sleep (unsigned long s)
 Pauses for the amount of seconds. More...
 

Detailed Description

Horloge.

Author
epsilonrt
Date
03/05/18

Definition at line 31 of file clock.h.

Constructor & Destructor Documentation

Sysio::Clock::Clock ( )

Constructor.

His call is the origin of the times provided by the millis() and micros() functions.

Member Function Documentation

static void Sysio::Clock::delay ( unsigned long  ms)
static

Pauses for the amount of milliseconds.

Pauses the thread for the amount of time (in milliseconds) specified as parameter.

Parameters
msthe number of milliseconds to pause, -1 deaden the thread until it is woken up by a signal
static void Sysio::Clock::delayMicroseconds ( unsigned long  us)
static

Pauses for the amount of microseconds.

Pauses the thread for the amount of time (in microseconds) specified as parameter.
Depending on the value provided, this function can wait for a loop or alarm (for short values) or put the thread into the corresponding number of us.

Parameters
usthe number of milliseconds to pause, -1 deaden the thread until it is woken up by a signal
unsigned long Sysio::Clock::micros ( )

Number of microseconds.

Returns the number of microseconds since began running the current program.

unsigned long Sysio::Clock::millis ( )

Number of milliseconds.

Returns the number of milliseconds since began running the current program.

static void Sysio::Clock::sleep ( unsigned long  s)
inlinestatic

Pauses for the amount of seconds.

Pauses the thread for the amount of time (in seconds) specified as parameter.

Parameters
msthe number of seconds to pause, -1 deaden the thread until it is woken up by a signal