22.5.3.4 PINIT (User Defined Function)

Completed Script

_strset(databuf0, "") // Clear data buffer 0.
_strset(databuf0, 0x1B) // Set ASCII code "ESC".
_strset(databuf1, "") // Clear data buffer 1.
_strset(databuf1, 0x40) // Set ASCII code "@".
_strcat(databuf0, databuf1) // Append data buffer 1 to end of data buffer 0.
_strlen([t:0000], databuf0) // Save data length to temporary address.
// Send data to serial port.
IO_WRITE_EX([p:EXT_SIO], databuf0, [t:0000]) // Send the amount indicated by temporary address from buffer 0.

Function Summary

Initializes the printer. Send the ESC/P command "ESC+@" to the printer.