CORDET Framework - C2 Implementation
|
Interface through which framework components access the current time. More...
Go to the source code of this file.
Functions | |
CrFwTime_t | CrFwGetCurrentTime () |
Return the current application time in standard format. More... | |
CrFwTimeStamp_t | CrFwGetCurrentTimeStamp () |
Return the current time in the format used for the command and report time-stamp. More... | |
CrFwTimeCyc_t | CrFwGetCurrentCycTime () |
Return the current time in "cycle format" (integer number of cycles elapsed since some event). More... | |
CrFwTimeStamp_t | CrFwStdTimeToTimeStamp (CrFwTime_t stdTime) |
Convert a time value from standard time format to time-stamp format. More... | |
CrFwTime_t | CrFwTimeStampToStdTime (CrFwTimeStamp_t timeStamp) |
Convert a time value from time-stamp format to standard time format. More... | |
Interface through which framework components access the current time.
Framework component need access to the current time to time-stamp out-going command and report packets.
This interface recognizes three formats for the application time:
This interface offers functions to retrieve the current time in all three formats and it offers function to convert times between standard and time-stamp format.
All applications must support the time-stamp format (because this is needed for the time-stamping of commands and reports) but support for the other two time formats is optional.
The implementation of this interface is entirely application-specific. A simple default implementation is provided in CrFwTime.c
. This default implementation is primarily intended for testing and demonstration purposes.
This file is part of the CORDET Framework.
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
For information on alternative licensing, please contact P&P Software GmbH.
Definition in file CrFwTime.h.
CrFwTimeCyc_t CrFwGetCurrentCycTime | ( | ) |
Return the current time in "cycle format" (integer number of cycles elapsed since some event).
If the host application does not support the "cycle format", this function returns zero.
Definition at line 51 of file CrFwTime.c.
CrFwTime_t CrFwGetCurrentTime | ( | ) |
Return the current application time in standard format.
If the host application does not support this time format, then this function is implemented to return zero.
Definition at line 46 of file CrFwTime.c.
CrFwTimeStamp_t CrFwGetCurrentTimeStamp | ( | ) |
Return the current time in the format used for the command and report time-stamp.
Definition at line 40 of file CrFwTime.c.
CrFwTimeStamp_t CrFwStdTimeToTimeStamp | ( | CrFwTime_t | stdTime | ) |
Convert a time value from standard time format to time-stamp format.
stdTime | the time in standard format |
Definition at line 56 of file CrFwTime.c.
CrFwTime_t CrFwTimeStampToStdTime | ( | CrFwTimeStamp_t | timeStamp | ) |
Convert a time value from time-stamp format to standard time format.
timeStamp | the time in time-stamp format |
Definition at line 61 of file CrFwTime.c.