module xdc.runtime.Timestamp |
![](../../Arrow_left.png) |
![](../../Arrow_up.png) |
![](../../Arrow_right.png) |
Timestamp services
#include <xdc/runtime/Timestamp.h>
module-wide functions
module-wide built-ins
XDCscript usage |
meta-domain |
var Timestamp = xdc.useModule('xdc.runtime.Timestamp');
local proxy modules
module-wide config parameters
local proxy modules
module-wide config parameters
module-wide functions
}
DETAILS
This module provides
xdc.runtime.ITimestampClient APIs for
the xdc Runtime Support Library. Calls to these APIs are forwarded
to a platform specific
xdc.runtime.ITimestampProvider
implementation.
A user can attach their own ITimestampProvider module
using the following config file command:
xdc.runtime.Timestamp.SupportProxy = xdc.useModule("usersTimestampProvider");
If no such
SupportProxy initialization is done,
the
xdc.runtime.TimestampNull ITimestampProvider implementation,
which provides null stubs for the APIs, will be attached by default.
If the user is developing code using CCS, the
xdc.runtime.TimestampStd
ITimestampProvider implementation, which uses the ANSI C clock()
function, may provide a satisfactory timestamp source (remember to
enable the profile clock in CCS).
To use the TimestampStd implementation, add the following to
your config script:
xdc.runtime.Timestamp.SupportProxy = xdc.useModule("xdc.runtime.TimestampStd");
proxy Timestamp.SupportProxy |
![](../../Arrow_up.png) |
User supplied time stamp provider module
XDCscript usage |
meta-domain |
// explicit access to the currently bound delegate module
DETAILS
The SupportProxy module provides application/platform
specific implementations of the
xdc.runtime.ITimestampProvider APIs.
If not explicitly supplied by the user, this proxy defaults to
xdc.runtime.TimestampNull,
which provides null stubs for all of the ITimestampProvider APIs.
metaonly config Timestamp.common$ // module-wide |
![](../../Arrow_up.png) |
Common module configuration parameters
XDCscript usage |
meta-domain |
DETAILS
All modules have this configuration parameter. Its name
contains the '$' character to ensure it does not conflict with
configuration parameters declared by the module. This allows
new configuration parameters to be added in the future without
any chance of breaking existing modules.
Timestamp.get32( ) // module-wide |
![](../../Arrow_up.png) |
Return a 32-bit timestamp
Bits32 Timestamp_get32( );
RETURNS
Returns a 32-bit timestamp value.
Use
getFreq to convert this value into units of real time.
SEE
Timestamp.get64( ) // module-wide |
![](../../Arrow_up.png) |
Return a 64-bit timestamp
ARGUMENTS
result
pointer to 64-bit result
This parameter is a pointer to a structure representing a 64-bit
wide timestamp value where the current timestamp is written.
If the underlying hardware does not support 64-bit resolution, the
hi field of
result is always set to 0; see
xdc.runtime.Types.Timestamp64. So, it is possible for
the
lo field to wrap around without any change to the
hi field.
Use
getFreq to convert this value into units of real
time.
SEE
Timestamp.getFreq( ) // module-wide |
![](../../Arrow_up.png) |
Get the timestamp timer's frequency (in Hz)
ARGUMENTS
freq
pointer to a 64-bit result
This parameter is a pointer to a structure representing a 64-bit
wide frequency value where the timer's frequency (in Hz)
is written; see
xdc.runtime.Types.FreqHz.
This function provides a way of converting timestamp
values into units of real time.
SEE
module-wide built-ins |
![](../../Arrow_up.png) |
// Get this module's unique id
Bool Timestamp_Module_startupDone( );
// Test if this module has completed startup
// The heap from which this module allocates memory
generated on Thu, 25 Jun 2009 21:46:16 GMT