SatDump 2.0.0-alpha-76a915210
Loading...
Searching...
No Matches
time.h File Reference

A collection of time-related utility functions. More...

#include <string>

Go to the source code of this file.

Functions

double satdump::getTime ()
 Get high-precision current UNIX time (milliseconds-level).
std::string satdump::timestamp_to_string (double timestamp, bool local=false)
 Format an unit timestamp to string.

Detailed Description

A collection of time-related utility functions.

Function Documentation

◆ getTime()

double satdump::getTime ( )

Get high-precision current UNIX time (milliseconds-level).

Returns
UNIX timestamps in seconds

◆ timestamp_to_string()

std::string satdump::timestamp_to_string ( double timestamp,
bool local = false )

Format an unit timestamp to string.

Parameters
timestampUNIX Timestamps in seconds
localformat to local time. UTC (false) by default
Returns
String in YYYY/MM/DD HH:MM:SS format