Difference between revisions of "SHIP:System Variable:shiptime"

From Serious Documentation
Jump to: navigation, search
Line 1: Line 1:
 +
See [[SHIP:System_Variable|System Variables]] for a complete list of SHIP system variables.
 +
 +
 
{{SysVarTableStart|}}
 
{{SysVarTableStart|}}
 
|<onlyinclude>{{SysVar|shiptime}}||{{DataType|Time}}||Read/Write||This variable tracks the current system time.  You can change these values, but they are only retained across power cycles if the platform has battery-backed RTCC capabilities. </onlyinclude>
 
|<onlyinclude>{{SysVar|shiptime}}||{{DataType|Time}}||Read/Write||This variable tracks the current system time.  You can change these values, but they are only retained across power cycles if the platform has battery-backed RTCC capabilities. </onlyinclude>

Revision as of 10:05, 1 April 2014

See System Variables for a complete list of SHIP system variables.


System Variable Data Type Permissions Description
shiptime Time Read/Write This variable tracks the current system time. You can change these values, but they are only retained across power cycles if the platform has battery-backed RTCC capabilities.

It is very easy to create a clock in our GUI by listening to shiptime. The simple script

text.value = toString(shiptime.hour,2) + ":" + toString(shiptime.minute,2) ;

within a listener with the listeningto property set to "shiptime.minute" will automatically keep the text value updated every second.