-1

enter image description here

In the above table there is a command "CLR" with Description(hex) "OC"

When I write that command to serial port I write "port.Write(new byte[]{ 0x0C } ) " and that works.

But I don't really understand how to write other commands in this list to serial port for example ESC DC1 command , ESC Q A...........CR command

Can someone please give me a bit of a explanation about these Code descriptions ? and how should I format them when I write to serial port ?

Please help me, I appreciate your help very much. :) Please be so kind enough to help me.

Real Programmer
  • 331
  • 2
  • 13

1 Answers1

1

Have you tried just doing the same thing for the other commands as you did for the CLR command? E.g. for ESC DC1:

port.Write(new byte[]{ 0x1B, 0x11 } );

Or for your other command:

port.Write(new byte[]{ 0x1B, 0x51, 0x41 } );

//Then write the 20 bytes that you want in your line,and then...

port.Write(new byte[]{ 0xD } );

Community
  • 1
  • 1
Eugene Osovetsky
  • 6,443
  • 2
  • 38
  • 59