Time

time.last_set

Abbreviation

ti l

Access

get

Description

Return the number of seconds since the time was set or -1 if the time has never been set. Time can be set manually or via NTP.

Arguments

None

Default

None

Platforms

Gecko OS Plugin

Get example

> get ti l
R000005
239

time.rtc

Abbreviation

ti r

Access

get/set

Description

The local time. Read returns epoch seconds by default, or (optionally) epoch milliseconds or UTC. Write takes an <epoch seconds> argument.

Get arguments

[ms/utc]

Set arguments

<epoch seconds>

Default

None

Platforms

Properties

Gecko OS Plugin

Get example

> get ti r utc
R000029
2019-01-01-23T08:13:07.010248Z

Set example

> set ti r 1395562166
R000008
Set OK

time.uptime

Abbreviation

ti u

Access

get

Description

Returns the number of seconds since reset, guaranteed not to roll over in your lifetime!

Arguments

Default

None

Platforms

Gecko OS Plugin

Get example

> get ti u 
R000006
8576

time.zone

Abbreviation

ti z

Access

get/set

Description

Timezone offset from GMT in hours.

Arguments

[+/-]H[:M]

Offset ranges from -12:30 to 12:30.

where:

Default

0

Platforms

Properties

Gecko OS Plugin

Get example

> get ti z
R000007
-4:30

Set example

> set ti z -4:30
R000008
Set OK