Determining if it’s Daylight Savings time in Fingerprint

Although the current revision of PC and PM printer firmware supports time zones, any time arithmetic in Fingerprint is done in Greenwich Mean time, so you have to adjust your numbers according to your time zone and if it’s Standard or Daylight Savings time.

For example, if it’s five o’clock local time in the Eastern Time zone and you want to calculate an expiration time two hours later, your result will be two hours earlier than the current time during Daylight Savings, and three hours during Standard time. This isn’t a big deal, you only have to add the time offset, but determining if it’s DST or not isn’t obvious.

There’s a function in the Fingerprint language, WEEKDAY that returns a number for the day of the week where Sunday is 1, Monday is 2, etc. So you can get the number of the first day in November,  subtract it (plus  one) from 7 to calculate the first Sunday in November, when DST ends:

zDST$ = “F”
zCURRENTDATE$ = DATE$

REM WHEN DOES DST END?

A% = WEEKDAY(LEFT$(zCURRENTDATE$,2) + “1101”)
zSTOPDAY$ = RIGHT$((“0” + STR$(7-A%+1)),2)
zSTOPDST$ = LEFT$(zCURRENTDATE$,2) + “11” + zSTOPDAY$

Likewise you can calculate when DST begins (the second Sunday in March)with the same function:

REM WHEN DOES DST BEGIN?

A% = WEEKDAY(LEFT$(zCURRENTDATE$,2) + “0301”)
zSTARTDAY$ = RIGHT$((“0” + STR$(14-A%+1)),2)
zSTARTDST$ = LEFT$(zCURRENTDATE$,2) + “03” + zSTARTDAY$

IF zCURRENTDATE$ <= zSTOPDST$ AND zCURRENTDATE$ >= zSTARTDST$ THEN zDST$=“T”

Of course, Daylight Saving begins and ends at 2 in the morning, but the above should be sufficient for most applications.

 

Speeding up batch printing on an Intermec PM43

We recently wrote a Fingerprint application for a large snack food manufacturer. The application prompts the user for the item number they want to print and the number of labels. After printing a sample label for approval, the program prints the requested quantity. There are four different label formats, and the data for the label is retreived from a .CSV look up file.

We issue a “PRINT FEED” command for each label; the labels are serialized so each one is unique.

Here’s a video of the labels printing:   Video

Notice that the printer pauses after each label. On our next release we implemented the command “OPTIMIZE “BATCH” ON” with each of the label formats. According to the manual, this command means that “The program execution will not wait for the printing of the label to be completed, but proceeds executing next label image into the other of the two image buffers as soon as possible.”

The effect was to greatly speed up label printing: Video_1