02.10.2012 Views

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

Programmer's Reference Manual Intermec Fingerprint® v8.70.0 ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

TIME$<br />

Purpose Variable for setting or returning the current time.<br />

Syntax Setting the time: TIME$=<br />

Chapter —Program Instructions<br />

sets the current time by a 6-digit number specifying Hour, Minute<br />

and Second.<br />

Reading the time: =TIME$[()]<br />

returns the current time according to the printer’s clock.<br />

is an optional flag "F", indicating that the time will be returned<br />

according to the format specified by FORMAT TIME$.<br />

Remarks This variable works best if a real-time clock circuit (RTC) is fitted on the<br />

printer’s CPU board. The RTC is battery backed-up and will keep record<br />

of the time even if the power is turned off or lost.<br />

If no RTC is installed, the internal clock will be used. After startup, an<br />

error will occur when trying to read the date or time before the internal<br />

clock has been manually set using either a DATE$ or a TIME$ variable.<br />

If only the date is set, the internal clock starts at 00:00:00 and if only the<br />

time is set, the internal clock starts at Jan 01 1980. After setting the internal<br />

clock, you can use the DATE$ and TIME$ variables the same way as<br />

when an RTC is fitted, until a power off or REBOOT causes the date and<br />

time values to be lost.<br />

Time is always entered and, by default, returned as HHMMSS, where:<br />

HH = Hour Two digits (00-23)<br />

MM = Minute Two digits (00-59)<br />

SS = Second Two digit (00-59)<br />

Time is entered as a 24-hour cycle, for example 8 o’clock pm is entered as<br />

"200000".<br />

The clock will be reset at the exact moment, when the appending carriage<br />

return character is received, for example when you press the Return key<br />

(Immediate Mode and <strong>Intermec</strong> Direct Protocol), or when the instruction<br />

is executed (Programming Mode).<br />

The format for how the printer will return time from a TIME$("F") variable<br />

can be changed using a FORMAT TIME$ statement.<br />

Example Setting and reading the time, then printing it on the screen of the host:<br />

10 TIME$ = "154300"<br />

20 FORMAT TIME$ "HH.MM"<br />

30 PRINT "Time is "+TIME$("F")<br />

RUN<br />

yields:<br />

Time is 15.43<br />

<strong>Intermec</strong> Fingerprint <strong>v8.70.0</strong>/v10.0.0 Programmer´s <strong>Reference</strong> <strong>Manual</strong> 7

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!