Namespaces | Typedefs | Functions
uuid Namespace Reference

Common utilities. More...

Namespaces

 console
 Console shell.
 
 log
 Logging framework.
 
 syslog
 Syslog service.
 
 telnet
 Telnet service.
 

Typedefs

using flash_string_vector = std::vector< const __FlashStringHelper * >
 Type definition for a std::vector of flash strings. More...
 

Functions

uint64_t get_uptime_ms ()
 Get the current uptime as a 64-bit milliseconds value. More...
 
void loop ()
 Loop function that must be called regularly to detect a 32-bit uptime overflow. More...
 
size_t print_to_string (const Printable &printable, std::string &output)
 Append to a std::string by printing a Printable object. More...
 
std::string printable_to_string (const Printable &printable)
 Create a std::string from a Printable object. More...
 
std::string read_flash_string (const __FlashStringHelper *flash_str)
 Read a string from flash and convert it to a std::string. More...
 

Detailed Description

Common utilities.

Typedef Documentation

◆ flash_string_vector

using uuid::flash_string_vector = typedef std::vector<const __FlashStringHelper*>

Type definition for a std::vector of flash strings.

Since
1.0.0

Definition at line 71 of file common.h.

Function Documentation

◆ get_uptime_ms()

uint64_t uuid::get_uptime_ms ( )

Get the current uptime as a 64-bit milliseconds value.

Returns
The current uptime in milliseconds.
Since
1.0.0

Definition at line 25 of file get_uptime_ms.cpp.

◆ loop()

void uuid::loop ( )

Loop function that must be called regularly to detect a 32-bit uptime overflow.

Since
1.0.0

Definition at line 23 of file loop.cpp.

◆ print_to_string()

size_t uuid::print_to_string ( const Printable &  printable,
std::string &  output 
)

Append to a std::string by printing a Printable object.

Parameters
[in]printablePrintable object.
[in,out]outputString to append to.
Returns
The number of bytes that were written.
Since
1.1.0

Definition at line 49 of file printable_to_string.cpp.

◆ printable_to_string()

std::string uuid::printable_to_string ( const Printable &  printable)

Create a std::string from a Printable object.

Parameters
[in]printablePrintable object.
Returns
A string containing the printed output.
Since
1.1.0

Definition at line 55 of file printable_to_string.cpp.

◆ read_flash_string()

std::string uuid::read_flash_string ( const __FlashStringHelper *  flash_str)

Read a string from flash and convert it to a std::string.

The flash string must be stored with appropriate alignment for reading it on the platform.

Parameters
[in]flash_strPointer to string stored in flash.
Returns
A string copy of the flash string.
Since
1.0.0

Definition at line 27 of file read_flash_string.cpp.