Instructions
UM-0085-B09 DT80 Range User Manual Page 103
RG
Calculated times can be specified by replacing either or both of the date and time parts with channel variable
references, m
CVT hh:mm:ss.tt or
yyyy
-mm-ddTnCV or
m
CVTnCV
If a channel variable is used for the date part then the CV value should be in seconds since 1-Jan-1989. The current
date, in seconds since 1-Jan-1989, can be obtained using
D(=mCV).
If a channel variable is used for the time part then the CV value should be in seconds since midnight. The current time, in
seconds since midnight, can be obtained using T(=mCV).
For example:
Value
Description
1CVT2:30
2:30am on the date specified by 1CV
T22CV
the time specified by 22CV, today
7CVT8CV
the time specified by 7CV, on the date specified by 8CV
Unloading New Data Only
The start= option may also be set to the special value of new. This will unload all data logged since the last unload.
For example,
RA1H DO{COPYD start=new}
will, every hour, unload all data logged since the last unload.
Unload requests can come from users of the web interface, or users of the command interface, or from schedules in the
running job. If these requests specify
start=new then the question then arises: what was the "last unload"?
The DT80 is capable of tracking up to 40 "last unload" points – that is, the time at which a particular user last unloaded a
particular store. In order to identify the "user", the id= option is used. This is an arbitrary number which is used to track
when you
last unloaded data from a store. If this option is not specified then the default setting of id=0 will be used.
Thus start=new really means "unload all data logged since the last time this store was unloaded with this id value"
For example, suppose Fred has a USB memory device with the following command in its ONINSERT job (see
ONINSERT Job (P64))
COPYD start=new id=27 dest=a:
Every time Fred plugs his memory stick into the DT80, it will unload all data logged since he last plugged in his device.
Ginger's memory stick contains a similar ONINSERT job:
COPYD start=new id=111 dest=a:
Because Ginger has used a different id value, when she plugs in her USB device she will get the data logged since she
last plugged in her device.
(This may or may not be the desired behaviour. For example, suppose Fred and Ginger are employed to collect data
from the DT80 on alternate weeks, with both of them bringing the data back to the same central office. In this scenario
you would normally use the same
id value on each device.)
The value used for the id= option can be any integer; the only requirement is that it be different for each of the unload
"users" between which you want to distinguish. By default, the
COPYD command uses a setting of id=0. When an
unload is done using dEX (the web interface), it uses a value of
id=1. Thus if you choose to specify an id value,
choose a value other than 0 or 1.
Note: the DT80's set of stored "last unload" times will be retained following a hard reset. However, they will be cleared if a different job
is loaded.
Lost Unload Data
Suppose that after unloading all new data onto his memory stick, Fred then loses it on the way back to the office. When
he goes back to the DT80 with a new memory stick, he needs a way of repeating the last unload he did, so that he gets a
new copy of the data he lost, plus anything that has been logged since.
The start=new2 option can help here. This will unload all data logged since the second last unload command,
excluding any
start=new2 unloads.
So to recover the lost data, Fred would use the following command:
COPYD start=new2 id=27 dest=a:
which is the same as his normal command, except with new2 rather than new
If (perish the thought) this unload data was also lost, Fred can simply repeat the same command. This will work because
the unload will start from, as stated above, the second last non-start=new2 unload, which is the same starting point
as the original lost unload. Once he successfully gets the data to the office he can go back to using his regular
start=new command.