TOSHIBA B-SX Bar Code Printer is driver to communicate with equipment such as Bar Code Printer B-SX4T, B-SX5T, etc of Toshiba Co., in Japan.
<Figure 1> is read setting example of TOSHIBA B-SX Bar Code Printer communication driver.
<Figure 1> Read setting example of TOSHIBA B-SX Bar Code Printer communication driver |
Device part of <Figure 1> input Com Port(COM1), Baud Rate(9600), Parity Bit(0), Data Bit(8), Stop Bit(1) respectively, according to equipment.
TOSHIBA B-SX Bar Code Printer communication driver's read schedule
Read schedule setting parameters are as follows:
1) STATION – Don't care. Input as 0 or 1, etc.
2) Read Command – Enter read command of Blank, WS, WB, WV, WI, WG and WN. (Refer to <Table 1>)
3) Read Start Address – Don't care.
4) Save Start Address for Communication Server – Saving start address of Communication Server.
5) Read Size - Data size to read. Fixed to 1.
Read schedule example)
READ, 1, WS, 0, 0, 1,
<Table 1> is read command type and contents of TOSHIBA B-SX Bar Code Printer communication driver.
Read command | Contents |
Remarks |
Blank, Etc | It doesn't read, Write Bar Code data to Printer. |
|
WS, WB, WV, WI, WG, WN |
Printer status value read command |
Save read value to WORD/DWORD/FLOAT memory. Save each letter of read value by converting into decimal. Save read string to STRING memory. |
<Table 1> Read command type and contents of TOSHIBA B-SX Bar Code Printer communication driver |
If you click the icon in protocol option part, you can see the dialog box such as <Figure 2>. you can also set read schedule by using this part.
<Figure 2> TOSHIBA B-SX Bar Code Printer driver's Option dialog box |
You can set read schedule by using , , button and listbox of <Figure 2>.
<Figure 3> TOSHIBA B-SX Bar Code Printer driver's read schedule Add/Edit dialog box |
When you click Add button or Edit button in dialog box of <Figure 2>, dialog box of <Figure 3> is shown.
You can print Bar Code Printer by using write settings.
Digital Write
Digital write and analog write have the same setting parameters except output value(0 or 1).
Analog Write
Analog write setting parameters are as follows:
1) PORT Connected port number. (Not COM number)
2) STATION Don't care.
3) ADDRESS When Extra1 is read command : Memory address to save.
When Extra2 value is 1 : INI file number to read Printer command.
When Extra2 value is except 1 : Don't care.
4) Extra1 When Extra2 is 1 : Don't care.
Read command or Etc Printer command of WS, WB, WV, WI, WG and WN.
Etc Printer command : /e, /n, /r letters mean ESC, CR, LF control code respectively, and letter of /?? type are used when enter the control letter, etc.
(The type such as /00 = NULL letter, /1B = ESC control code, ¡¦ )
5) Extra2 Select whether to read Printer command from file.
Bring Printer command from 1 and file. (From WorkDirectory\SCAN\COMMAND_%05d.ini file)
Etc : Don't care.
<Table 2> is Printer data writing method when read Printer command from file.
File Name |
Writing Method |
WorkDirectory\SCAN\COMMAND_%05d.ini, %05d = File number between 0 and 99999 |
1) Enter one Printer command at one line. 2) Control command code of start and end isn't entered. 3) You can enter multiple-line Printer command. 4) /e, /n, /r commands mean ESC, CR, LF control code respectively. 5) Command of /?? type is used when enter the control letter, etc. (/00 = NULL letter, /1B = ESC control code, ¡¦ )
Input example) C PC001; 0200, 0300, 1, 1, C, 00, B; 01, 02 PV01; 0650, 0550, 0200, 0150, B, 33, B; 02 XB01; 0200, 0550, 3, 1, 02, 02, 06, 06, 02, 0, 0150; 01, 02 RC; S /r 001 XS; I, 0002, 0002C3000 |
<Table 2> Printer data writing method in case of reading Printer command from file |
Write example 1)
PORT : 0 STATION : 0 ADDRESS : 0000 EXTRA1 : RC000; ABC EXTRA2 : 0
The setting parameter shown above is example of Printer output by transferring Bitmap Font Data Command to Toshiba Bar Code Printer device connected with no.0 port. (But, when status of device Font, etc is normal)
Write example 2)
PORT : 0 STATION : 0 ADDRESS : 0000 EXTRA1 : WR EXTRA2 : 0
The setting parameter shown above is example of RESETTING Toshiba Bar Code Printer device connected with no.0 port.
Write example 3)
PORT : 0 STATION : 0 ADDRESS : 0000 EXTRA1 : EXTRA2 : 1
The setting parameter shown above is example of writing Printer output data which is entered at 'WorkDirectory\SCAN\COMMAND_00000.ini' file by reading from Toshiba Bar Code Printer device connected with no.0 port, to Printer. (But, when moderate Printer output data is written at ini file)
Write example 4)
PORT : 0 STATION : 0 ADDRESS : 0001 EXTRA1 : EXTRA2 : 1
The setting parameter shown above is example of writing Printer output data which is entered at 'WorkDirectory\SCAN\COMMAND_00001.ini' file by reading from Toshiba Bar Code Printer device connected with no.0 port, to Printer.
Printer output command example)
D0330,0500,0300
C
PC001;0010,0010,1,1,A,00,B,+0000000001
XB01;0010,0050,3,1,02,02,04,04,02,0,0100,+0000000001,1,00
RC001;A0001
RB01;B0001
XS;I,0003,0002C5200
Block Write
Block Write uses PlcScanWriteBlock function of script, as follows.
Script name and type : @PlcScanWriteBlock(int port, int station, int address, string extra1, string extra2, object array_value, int array_size);
Script writing example
@PlcScanWriteBlock(0, 1, 1, "", "", "C", 1);
@PlcScanWriteBlock(0, 1, 1, "", "", "PC001; 0200, 0300, 1, 1, C, 00, B; 01, 02", 200);
@PlcScanWriteBlock(0, 1, 1, "", "", "PV01; 0650, 0550, 0200, 0150, B, 33, B; 02", 200);
@PlcScanWriteBlock(0, 1, 1, "", "", "XB01; 0200, 0550, 3, 1, 02, 02, 06, 06, 02, 0, 0150; 01, 02", 200);
@PlcScanWriteBlock(0, 1, 1, "", "", "RC; S \r 001", 200);
@PlcScanWriteBlock(0, 1, 1, "", "", "XS; I, 0002, 0002C3000", 200);
Importance) Block Write is supported at over 10.2.0 version.
Communication cable of TOSHIBA B-SX Bar Code Printer is connected, as follows.
Communication cable connection
Connect supported communication cable to back side serial communication terminal, etc of TOSHIBA B-SX Bar Code Printer.
<Figure 4> Appearance of TOSHIBA B-SX Bar Code Printer |