E1406A User Manual and SCPI Programing Guide307D Sending Binary Data Over RS-232About This AppendixThis appendix describes the procedure for sending pure binary data over anRS-232 interface. The formatting described is used in theDIAG:DOWN:CHEC[:MADD], DIAG:DOWN:CHEC:SADD, andDIAG:DRIV:LOAD:CHEC commands. This appendix contains the following mainsections.Formatting Binary Data for RS-232 Transmission page 307Sending Binary Data Over RS-232 page 309Formatting Binary Data for RS-232 TransmissionThe most straightforward way to send a block of data is to open the data file,read the next byte from the file, and send it to the System Instrument until youreach the end of file. However, binary data cannot be sent to the systeminstrument as is. It must be converted into a format that will not conflict with thespecial characters that the RS-232 interface recognizes. This is done by sendingonly one half byte (a nibble) at a time.To prevent this nibble from being confused with a special character, bit 7 of thenibble is set to one. This gives all data bytes in the block values greater than 127so they are not confused with ASCII characters. It also doublesthe size of the file to be sent and the transmission time for the file. Since atransmission error that required re-transmission of the entire data block would bevery time consuming, a 3-bit error code (which allows for correction of single biterrors) is added to the transmission byte. The following format is sent for eachnibble:Bit # 7 6 5 4 3 2 1 01 Correction Code Data