2006/05/31
CHAPTER 2 "PCL" - 93
7. MACROS
7.1. The Purpose of a Macro
A macro is a sequence of commands that you wish to execute. You can specify the command sequence and
download it to the printer after which you can execute it with a single command. For example, you might wish
to draw a raster image at the top of each page you print. Rather than sending the same sequence of commands
every time you print a new page, it is more efficient to define a macro to draw the image and store the macro in
the printer’s memory. Having done this, you can draw the picture on each page simply by running the macro,
that is, with a single command.
Like downloaded fonts, macros take up printer memory. To alleviate this, some macros are available on
cartridges that can be plugged into the printer’s cartridge slots. A cartridge-based macro must have a unique ID
number or else you will not be able to access it. If a downloaded macro has the same ID number as a cartridge
macro, all references to the ID number will be interpreted as references to the downloaded macro. To access the
cartridge macro you would first have to delete the downloaded macro.
Another method of storing Macros is uniquely available on the HL-1660e/2060/2400C/2400Ce/3400CN/
2600CN/3450CN/2460/7050/3260N/6050/6050D/6050DN/8050N/2700CN printers. Macros can be saved to
these cards as required and then executed from the card. For the HL-2400Ce/3400CN/2600CN/3450CN/2460/
3260N printers, Macros can be also saved to and executed from the optional internal hard disk drive installed as
required. A delete facility is also included to allow the removal of macros when no longer required. The rules
for identifying and calling Macros from this card are exactly the same as for cartridge stored Macros detailed
above. For the HL-1270N/1470N/1650/1670N/
1850/1870N/5070N/5170DN/6050/6050D/6050DN/5270DN/5280DW printer, Macros can be stored in the
incorporated Flash memory.
One macro can call another, however, only two levels of nesting are permitted.
A printer reset will delete macros from the printer’s memory unless they have been explicitly designated as
permanent.
The PCL picture frame commands, the printer reset command and HP-GL/2 graphic language commands cannot
be invoked from within a macro.