47
UBI EasyCoder 301 Direct Protocol – Programmer's Guide Ed. 1
Chapter 6 Setting Up the Printer
4. Date and Time
Format,
cont'd.
5. Separators
1
/. If you transmit a
FORMAT
INPUT
command containing
separators identical to any of the
separators already stored in the
printer's memory, an error will
occur unless you first enter
Immediate Mode.
The separators are not saved in
the printer's battery backed-up
memory, but must be transmitted
after each power-up.
In many cases,you may prefer to have the names of months and
weekdays printed in plain text rather than as a number. There are
two commands which allow you to assign names in any language
to months and weekdays:
NAME DATE$<No. of month>,"<name of month>"
<No. of month>
1–12.
<name of month>
the desired name enclosed by double quota-
tion marks.
The name of the month will be printed according to the format speci-
fied by
FORMAT
DATE$
and will be left justified.
NAME WEEKDAY$<No. of weekday>,"<name of weekday>"
<No. of weekday>
1 (Monday) – 7 (Sunday).
<name of weekday> the desired name enclosed by double quota-
tion marks.
Default:
Full English names, e.g. Monday.
When transmitting variable input data to a predefined layout, the
string must contain certain separating characters. By default, you
should use <STX> as start-of-text separator, <CR> as field separa-
tor and <EOT> as end-of-text separator(see chapter 6.5).
However, the
FORMAT
INPUT
command allows you to select other
characters as separators if the default separators for some reason
cannot be produced or will interfere with the host computer system.
Simply insert the desired separator characters (enclosed by double
quotation marks) into the
FORMAT
INPUT
command. Avoid using
characters like
XON/XOFF
or
ENQ/ACK
, which may interfere with
the communication between printer and host.
You must first leave Layout Mode by means of an
INPUT
OFF
command, change the separators using a
FORMAT
INPUT
com-
mand and then enter Layout Mode again by means of an
INPUT
ON
command
1
.
FORMAT INPUT "<start separator>","<end separator>","<field separator>"
Example:
INPUT OFF
↵
FORMAT INPUT "#","&",CHR$(13)
↵
INPUT ON
↵