6.5.3 Sending Data
Communication with external devices is handled through the data registers.
Data to be output is stored in the data register used as the send buffer (DT), and when the F159 (MTRN)
instruction is executed, the data is output from the communication port.
Data table for transmission (send buffer)
Sample program for sending data
The following program transmits the characters "ABCDEFGH (Hex)" to an external device using the
communication port.
The program described above is executed in the following sequence.
1) "ABCDEFGH" is converted to an ASCII code and stored in a data register.
2) The data is sent from the communication port using the F159 (MTRN) instruction.
Explanatory diagram
Phone: 800.894.0412 - Fax: 888.723.4773 - Web: www.clrwtr.com - Email: info@clrwtr.com