PC communication module/utility Working under

PC communication module/utility
Working under Windows for
QT-6000/6100, QT-6600
SE series
Ver4.30 Jan 29 2010
Revision History of this document
Document Ver4.30 rev1.0
New features
Support SE-C6000/S6000.
Document Ver4.20 rev1.0
New features
Support XZ file format including AUTOPGM Fields.
Document Ver4.10 rev1.0
New features
Support SE series.
Up to Ver4.01, the key “PASSIVE=ON” is required define at [FILE_INF] and [FTP] section.
Ver4.10+ is required define only [FTP] section.
New JOB command.
JobNo=0016:Build ScanPLU Index File
JobNo=0025:Consolidation Report
JobNo=0026:Indirect Programming
Document Ver4.01 rev1.0
New features
Support QT-6000/6100.
Document Ver4.0 rev1.0
New features
Support expand data format for QT-6600 which is available over 65,535 records.
Support new machine ID for QT-6600 No.36.
FTP port number can be specified by INI file.
[TCP/IP] section.
FTPPORTnn=ppp
Support Remote IPL operation via FTP, and JOB 24/90.
-1-
INDEX
CHAPTER 1. OVERVIEW OF THE COMMUNICATION MODULE/UTILITY.............................4
1-1. OVERVIEW. ............................................................................................................................... 4
1-2. COMMUNICATION PROTOCOL ..................................................................................................... 5
1-2-1. RS232C(ONLINE) ....................................................................................................... 5
1-2-2. TCP/IP (Inline) ................................................................................................................. 6
1-2-5. CF..................................................................................................................................... 6
1-2-6. FTP................................................................................................................................... 6
1-3. OTHERS .................................................................................................................................... 7
1-3-1. Data 90/92/900 text data.................................................................................................. 7
1-3-2. Eight comports in PC ....................................................................................................... 7
1-3-3. Temporary file .................................................................................................................. 7
CHAPTER 2. EXECUTING C_COMW.EXE UNDER THE WINDOWS........................................8
2-1. HOW TO USE ............................................................................................................................. 8
CHAPTER 3. EXECUTING C_COMW.EXE BY DOS COMMAND ..............................................9
3-1. HOW TO USE (SINGLE COMMAND) .............................................................................................. 9
3-2. HOW TO USE (MULTI COMMAND) ............................................................................................. 10
CHAPTER 4. USAGE OF THE COMMUNICATION DLL BY SOFTOWARE............................. 11
4-1. HOW TO USE C_COMW.DLL UNDER C/C++ LANGUAGE ENVIRONMENT ................................... 11
4-2. HOW TO USE C_COMWX.DLL UNDER C/C++ LANGUAGE ENVIRONMENT ................................ 12
CHAPTER 5. C_COMW.EXE/DLL COMMAND LINE/DLL PARAMETER................................. 13
5-1. OUTLINE................................................................................................................................. 13
5-2. FILE RECEIVE/SEND OPERATION (SINGLE COMMAND). .............................................................. 13
5-3. FILE RECEIVE/SEND OPERATION (MULTI COMMAND). ............................................................... 19
5-4. JOB COMMAND OPERATION ...................................................................................................... 22
5-5. COMMUNICATION DIALOG ....................................................................................................... 28
5-5-1. Dialog example............................................................................................................... 28
5-5-2. INI file setting................................................................................................................ 29
CHAPTER 6. MODEM COMMUNICATION............................................................................ 30
6-1. HOW TO USE MODEM COMMUNICATION .................................................................................... 30
CHAPTER 7. ERROR CODE .................................................................................................. 32
-2-
7-1. THE TYPE OF ERROR ................................................................................................................ 32
7-2. PC ERROR CODE ..................................................................................................................... 33
CHAPTER 8. PROFILE (INI FILE) AND MACHINE ID .......................................................... 36
8-1. INI FILE ................................................................................................................................. 36
8-2. MACHINE ID........................................................................................................................... 44
CHAPTER 9. FILE FORMAT.................................................................................................. 45
9-1. OUTLINE................................................................................................................................. 45
9-2. TEXT DATA FORMAT ................................................................................................................. 46
9-3. PGM_1000.XXX FILE FORMAT (CE/TK/TE-M ONLY)............................................................... 51
9-4. BINARY DATA FORMAT ............................................................................................................. 52
CHAPTER 10. ERROR LOG FILE (ECR.LOG) FORMAT ......................................................... 57
CHAPTER 11. PROTOCOL .................................................................................................... 59
11-1. PROTOCOL TYPE. ................................................................................................................... 59
11-2. RF PROTOCOL ....................................................................................................................... 60
11-3. XMODEM CRC1024 ............................................................................................................ 62
11-4. XMODEM SUM128 ............................................................................................................. 65
11-5. CF CARD ............................................................................................................................... 66
11-5-1. S command – PC to CF card with TEXT to BINARY convert. ..................................... 66
11-5-2. R command – CF card to PC, with TEXT converts. ..................................................... 66
11-5-3. X and Z command – CF card to PC. ............................................................................. 66
11-5-4. JOB, IPL, Create. ......................................................................................................... 66
11-5-5. CF card folder............................................................................................................... 67
11-5-6. CF card file name ......................................................................................................... 67
11-5-7. Different format between ECR type............................................................................. 68
11-5-8. QT CF converts flow. .................................................................................................... 69
11-5-9. QT CF converts sample. ............................................................................................... 70
11-5-10. MID-Low CF converts sample. ................................................................................... 71
11-6. FTP...................................................................................................................................... 72
-3-
Chapter 1. Overview of the communication module/utility
1-1. Overview.
CASIO communication modules/utilities supply data transfer with CASIO ECR/POS, conversion into text
format and other useful functionality to you and your original application working under the Windows
2000/XP/2003 Server © environment.
There are three ways to communicate with the ECR/POS by the modules/utilities.
1) To use c_comw.exe under the Windows (Communication menu)
2) To use c_comw.exe by the DOS command line
3) To use your local application designed based on c_comw.dll/c_comwx.dll
3) Your local application
1) C_comw.exe under Win
2) C_comw.exe by Dos
Profiles (INI files)
C_comw.dll / C_comwx.dll
Other DLL: Your application is not allowed access to
directory.
Text data for
Output use.
Input/
XMODEM protocol for QT2000/2100.
RF/N protocol for CE/TK/TE-M† series.
To QT/TE-H.
To CE/TK/TE-M †
series.
Which is the best way for you?
1) C_comw.exe under Win
Easy file transfer operation.
Purpose
Simply backup file.
Usage
Click c_comw.exe
Windows.
under
the
2) C_comw.exe by Dos
3) Call DLL
Execute full functionality of
Communication utility.
For your application.
Open DOS window and enter
operation parameters.
Call from your Application with
operation parameters.
* QT/MID-HIGH online password is not available.
-4-
1-2. Communication protocol
1-2-1. RS232C(ONLINE)
Protocol
Protocol name: QT/TE-H: CASIO original XMODEM protocol.
CE/TK/TE-M† : CASIO original RF/N protocol.
Communication:
Half duplex.
Start bit:
1 bit.
Stop bit:
1 bit.
Parity:
NONE
Control:
CS(CTS)/DR(RTS) and DR(DSR)/ER(DTR)
Cabling.
Direct PC – ECR connection. (Use cross cable)
PC (Default COM1)
1.
2.
3.
4.
5.
6.
7.
8.
9.
CD
RD (RXD)
SD (TXD)
ER (DTR)
SG
DR (DSR)
RS (RTS)
CS (CTS)
CI
ECR
1. CD
2. RD (RXD)
3. SD (TXD)
4. ER (DTR)
5. SG
6. DR (DSR)
7. RS (RTS)
8. CS (CTS)
9. CI
DSUB 9 Pin
DSUB 9 Pin
Modem – ECR connection. (Use straight cable)
Modem
1. FG
2. SD (TXD)
3. RD (RXD)
4. RS (RTS)
5. CS (CTS)
6. DR (DSR)
7. SG
8. CD
ECR
1. CD
2. RD (RXD)
3. SD (TXD)
4. ER (DTR)
5. SG
6. DR (DSR)
7. RS (RTS)
8. CS (CTS)
9. CI
20.ER (DTR)
DSUB 9 pin
22.CI
DSUB 25 Pin
-5-
1-2-2. TCP/IP (Inline)
QT Inline protocol is based on XMODEM packet.
1-2-5. CF
CF AUTOPGM data convert to/from TEXT file. Now you can read CF AUTOPGM data to
PC as TEXT file, modify preset value and write to CF card again.
CF X/Z data receive to PC. CF X/Z data is TEXT file but format is different between
MID-Low and other models which are CASIO standard format. Now c_comw can convert
MID-Low X/Z format to CASIO standard format for standard PC application.
1-2-6. FTP
QT support FTP protocol.
・ Login/Password is depending on ECR program.
・ ECR connect maximum number is 1.
・ In case of communication error, time out value is depending on ECR I/O parameter program. Default is
60 sec.
FTP protocol level send/receive data can be set ”S” record. This is used for check if FTP transfer data is
correct or not. If you do not know send data size, please not add “S” record.
If use c_comw, the “S” record is eliminated.(same as online received data)
Please set ECR as “use FTP server”, otherwise communication library can not connect by FTP.
-6-
1-3. Others
1-3-1. Data 90/92/900 text data
DLL can receive the data 90, 92 and 900 by test format in a PC with “-T” switch and also send
their text data back to the ECR. When sending their text data to the ECR, information of the
file memory allocation is also sent to the QT/TE-H with “–S0” command but not sent to the
TK7000/TE-M† class ECR. So you need to allocate the same memory in each file before
sending the file 90, 92 and 900 to the TK7000/TE-M† ECR.
1-3-2. Eight comports in PC
Com 1 to 8 at the PC side is supported. Specify an appropriate com port between 1 and 8 at the
line “COM=” in the section [ONLINE] in the initial file.
1-3-3. Temporary file
In case of illegal terminate, temporary files cannot be erased.
・ In DLL current folder, there are “*.tmp” files.
・ In DLL current folder, there are “$*$” files.
・ In DLL drive root folder, there are temporary files.
DLL outputs error log file. Please erase the error log file if it becomes bigger.
-7-
Chapter 2. Executing c_comw.exe under the Windows
2-1. How to use
Communication Dialog
How to use:
(1) Enter/Select most a suitable profile name at [Profile name] box. This should be done as first operation.
(2) Select job type with [Com Direction] check box.
“Send”
“Receive”
“X Receive”
“Z Receive”
“IPL”
: Sending ECR program data file to the ECR
: Receiving ECR program data file from the ECR
: Receiving ECR sales data without Z clear
: Receive ECR sales data with Z clear
: Sending IPL data to the ECR
(3) Select communication line type with [Communication Line] check box. If you want to use online, select
“ONLINE”.
When QT INI file and IN-LINE is selected, the communication becomes TCP/IP.
(4) If you want to convert a received file into TEXT file, check “Output Text Type” check box. This check box is
available with “Receive”, “X Receive” and “Z Receive”.
(5) Select an operation code in [Operation code] select window. This operation automatically sets [DOS File
name]. This check box is available with “Receive”, “X Receive” and “Z Receive”.
(6) In case of IPL,select IPL file name at [DOS File name] box.
(7) Press [Add] button. This operation automatically puts a command set by the above procedure in “Com
Direction/Operation code/File Name” window. If you want to eliminate a command already set in the
window, adjust the blue bar to the command and press [Delete] button.
(8) Press [OK] button to start communication.
*If you want to use modem, please check [Dial Modem] button and set [Dial Number].
*This is simple use then you can not all functions by this dialog.
-8-
Chapter 3. Executing c_comw.exe by DOS command
3-1. How to use (Single command)
This executes c_comw.dll and passes parameter to c_comw.dll.
(1) Load DOS window.
(2) Execute a command with c_comw.exe.
USG>C_comw.exe [R/S/S0/X/Z/I/C/etc] [filename] [fileno/xzcode] [switches] …
Example: Receive PLU file from TK7000 via online direct communication.
>C_comw R file0004.txt 4 ‒ lo ‒ dc:¥cvw¥tk7000.ini -T
(3) Check communication log file “ecr.log”.
The detail of command line parameter is mentioned on other chapter.
(Chapter 5. C_comw.exe/DLL command line/DLL parameter.)
<Easy enter parameter>
You can execute c_comw.exe without specifying “-lo” option and full path for the “-d” option.
1. You do not have to enter “–lo” option for online communication. Without “-l” option in the command
line, the c_comw.exe works as “–lo”.
2. You do not have to enter full path with “–d” option. Entering INI file name without path name,
c_comw.exe searches it in the current directory.
Of course, you can enter full path with “–d” option, if you want.
Example:
>c_comw R file0004.txt 4 -dQT6600.ini -T
Instead of
>c_comw R file0004.txt 4 -lo ‒ dc:¥cvw¥QT6600.ini -T
<Support space-include folder>
Now filename can has space-include folder name.
Example:
>c_comw R c:¥Program Files¥casio¥f.txt
4 -lo -d
-9-
c:¥Program Files¥casio¥qt6600.ini
3-2. How to use (Multi command)
This executes c_comwx.dll and passes parameter to c_comwx.dll with script file.
(1) Load DOS window.
(2) Execute command with c_comw.exe.
USG>c_comw.exe [script file name] [switches] ………
Example: Receive PLU file from TK7000 via ONLINE.
Script file: mycmd.txt -> Inside of mycmd.txt: S,0000,FILE004P.TXT
>c_comw mycmd.txt -lo -dc:¥cvw¥tk7000.ini -T
(3) Check communication log file “ecr.log”.
-
Don’t suppress line parameter, such as –lo, with multi command.
Don’t suppress INI file path name with –d option, full path name is required.
[Script file name] and INI file path with –d option can have space-include path name.
Example: >c_comw “c:¥Program Files¥casio¥cmd.txt” -lo -d“c:¥Program Files¥casio¥qt6600.ini”
How to C_comw.exe judge execute single command or multi command is as follows.
- If first parameter is 2 characters or less, execute c_comw.dll.
- If first parameter is more than 3 characters, execute c_comwx.dll.
Please use script file name more than 3 characters.
About switches, please refer another chapter.
- 10 -
Chapter 4. Usage of the communication DLL by softoware
4-1. How to use C_COMW.DLL under C/C++ language environment
The c_comw.dll executes a single communication command in one connection line such like c_comw.exe.
<Usage>
DLL File Name:
Function Name:
Parameter:
Return value:
C_COMW.DLL
InitC_COMW
LPSTR prt, int mess
Prt
string defined like "C_Comw.dll". Refer to <Parameter list> section
Mess
To display result dialog of the communication result.
0 is not displayed result, 1 is displayed result.
int
result
// This return value is int.(32bit)
result - 0: Normal end.
Others: Error end error code.
<Example of coding>
typedef int (*PROCCER1)(LPSTR,int);
PROCCER1 lpfnInitC_Comw;
// This return value is int.(32bit)
HINSTANCE hinstSamp = ::LoadLibrary("C_COMW.DLL");
if (hinstSamp == NULL)
MessageBox("LoadLibrary failed");
else
{
lpfnInitC_Comw = (PROCCER1)::GetProcAddress(hinstSamp,"InitC_COMW");
if (lpfnInitC_Comw == NULL)
MessageBox("GetProcAddress failed");
else
{
int Ret = 0;
// This return value is int.(32bit)
Ret = lpfnInitC_Comw("R FILE001P.TXT 1 -lo -dc:¥¥c_util.ini -i -T",1);
CString str; str.Format("Error : %d", Ret);
MessageBox(str);
}
::FreeLibrary(hinstSamp);
}
The detail of command string/parameter, please see other chapter.
(Chapter 5. C_comw.exe/dll command line/Dll parameter.)
- 11 -
4-2. How to use C_COMWX.DLL under C/C++ language environment
Using C_COMWX.DLL, a PC will make multiple steps operation in one connection line. Especially it will
be recommended to be used with the modem communication. Multiple files can be taken from the ECR by
one time dial-up for example.
<Usage>
DLL File Name:
Function Name:
Parameter:
Return value:
C_COMWX.DLL
InitC_COMWX
LPSTR prt, int mess
prt - string defined like "C_Comw.dll". Refer to <Parameter list> section
mess - to display result of the communication, 0 is not displayed, 1 is displayed.
int result
// This return value is int.(32bit)
result - 0: Normal end.
Others: Error end error code.
<Example>
typedef int (*PROCCER1)(LPSTR,int);
PROCCER1 lpfnInitC_Comwx;
// This return value is int.(32bit)
HINSTANCE hinstSamp = ::LoadLibrary("C_COMWX.DLL");
if (hinstSamp == NULL)
MessageBox("LoadLibrary failed");
else
{
lpfnInitC_Comwx = (PROCCER1)::GetProcAddress(hinstSamp,"InitC_COMWX");
if (lpfnInitC_Comwx == NULL)
MessageBox("GetProcAddress failed");
else
{
FILE * fp = fopen("c:¥¥Filelist.txt","w");
if(fp == NULL)
MessageBox("File list creation failed");
else
{
fputs("J,0002", fp); // 1st file to job cmd fputs("¥n",fp);
fputs("Z,0001,File001z.txt", fp); // 2nd file to receive fputs("¥n",fp);
fputs("Z,0002,File002z.txt", fp); // 3rd file to receive fputs ("¥n",fp);
fputs("S,0000,File005p.txt", fp); // 4th file to send fputs ("¥n",fp);
fputs("J,0003", fp);
// 5th file to job cmd fputs("¥n",fp);
fclose(fp);
int Ret = FALSE;
// This return value is int.(32bit)
Ret = lpfnInitC_Comwx("c:¥¥Filelist.txt -lo -dc:¥¥Tk7000.ini -i -T",0);
CString str;
str.Format("Error : %d", Ret);
MessageBox(str);
// The filelist file is deleted.
remove("c:¥¥Filelist");
}
}
::FreeLibrary(hinstSamp);
}
- 12 -
Chapter 5. C_comw.exe/DLL command line/DLL parameter
5-1. Outline
Before use communication DLL, please set correct values for INI file for detail see INI file explanation.
・ If use RS232C, set COM= and SPEED=.
・ If use TCP/IP, set ECRnn= IP address.
NOTE 5-1: Before starting PC communication, please set correct value for Connection table. (for
CE/TK/TE-M† is FILE091, QT/TE-H is FILE901) Otherwise some command does not work, for
example Z receive, Job command.
5-2. File receive/send operation (Single command).
This is used for c_comw.exe or c_comw.dll parameter.
USG: "[R/S/S0/X/Z/C] [PC FileName] [ECR File Number] [switches…….]"
[R/S/S0/X/Z/C]
R: Receive PGM data from ECR
S: Send PGM data to ECR
(S0 is allocating records in files with auto program 90 for QT/TE-H)
X: Receive sales data from ECR
Z: Receive sales data from ECR and make RESET operation for ECR
QT/TE-H series ECR will automatically Z clears if Z receives.
CE/TK/TE-MID series PC receive as X and send JOB Z command after received.
C: Create File or expand the number of record for existed file. (CE/TK/TE-M† only)
[PC FileName]
In case of R/X/Z/C, PC filename is used for save received data.
In case of S/S0, PC filename is used for send data.
See Note 5-2, regarding with the case of C.
See Note 5-5, regarding with QT IPL file.
[ECR File Number]
Incase of R/X/Z, File number of ECR to be received.
Incase of S, this value is invalid.
Incase of CF card file, this value is CF card file name with INI file [CF] section path name.
[switches…..]
-l Specify the communication line.
-lo: Use Online communication.
-li: Use Ethernet communication
-lc: Use CF card file. See NOTE5-3.
-lf: Use FTP. See NOTE5-4.
-d Specify the profile name with path. For example,
-dc:¥Cvw¥Tk7000.ini
-d c:¥Cvw for win¥Tk7000.ini
For space directory, please use
.
-i Specify to initialize the profile (Ini file) file format section.
This switch update [FILExxxx] section. (Ex. [FILE0004])
In case of use CF card file, this switch is available when receive binary file.
- 13 -
-T
-w
-u
-m
-o
-t
-n
-p
Specify to store the received file as Text. This is available only for R/X/Z.
This switch is not available for data file (Ex.90), journal memory file for
QT/TE-H.
In case of send, DLL automatically judge text or binary file.
CF card X/Z file receive is always TEXT even if no -T switch.
Specify to display the data to text conversion window.
Specify to confirm profile update. This switch is available with use ‒ i switch.
Specify to have modem dial connection, available only for -lo, ie; Online.
For example, -m042-5135-2265 .
When you use modem communication, please refer Chapter 6.Modem communication.
Specify the response file name, if available job command.
The response file name must not have extended name like res.dat .
For example, -ores.dat does not work, but
-ores
works.
CE/TK/TE-M† is available with J 401 command.
QT/TE-H is available with J 2,4,6 and 23 command.
Specify the terminal designation. (Ver.3.10)
Ethernet :1~[TCP/IP] Detailed IP address calculation by section settings
Detailed address designation setting is possible. :-t132.1.2.171
FTP login name.
Please set same login name at ECR program. See NOTE5-4.
FTP password.
Please set same password at ECR program. See NOTE5-4.
The order of parameters is not defined. But parameter without "-" has order as follows.
[R/S/S0/X/Z] [PC FileName] [ECR File Number]
Note 5-2: Explanation of file structure for C command; Create File and expand record.
“Control code”
……………… the first line
File No, No of Record, File Name
……………… the second line
File No, No of Record, File Name
……………… the third line
|
File No, No of Record, File Name
……………… the last line
Control Code:
A: Initialization (Control Code must be “INIT” )
Purpose: Use it for installation
Action: Delete all of files in ECR and recreate files defined
as the following lines.
B: Normal operation for creating files and expanding record of files ( Control Code is not “INIT” )
Purpose: Maintenance of ECR. Adding the new files, maintenance the number of records, etc.
Action: If there exist a file, resize number of record of that file.
If not, create a file for new file defines as file No and No of Record
parmes.
- 14 -
Example:
Prepare text file named as “creinfo.txt”.
Inside data of “creinfo.txt” is following.
UPDATE
0004,100,FILE0004
0005,50,FILE0005
0006,20,FILE0006
Send this information to ECR
>c_comw C creinfo.txt ‒ lo ‒ dc:¥cvw¥tk7000.ini
With this operation, ECR recreate FILE0004,0005 and 0006 as defined record number.
After this operation you can send your preset data (If prepared FILE0004.txt,
FILE0005.txt and FILE0006.txt files with your data) with S command to ECR like this.
>c_comw S FILE0004.txt 4 ‒ lo ‒ dc:¥cvw¥tk7000.ini
>c_comw S FILE0005.txt 5 ‒ lo ‒ dc:¥cvw¥tk7000.ini
>c_comw S FILE0006.txt 6 ‒ lo ‒ dc:¥cvw¥tk7000.ini
…..This ‘C’ command is named “FILE1000” at inside of TK/CE ECR.
Note 5-3: Support CF card file.
CF card file convert target is CF AUTOPGM file and CF X/Z file.
CF card means AUTOPGM file convert to/from TEXT and X/Z file convert to general CASIO X/Z format.
Before use CF card file convert, you need to set CF card drive and path name at INI file [CF] section. Target file
name is generated by command line file name (at file number parameter area) and INI file drive and path name.
Also need to set [CF] section DATE order by “DATE=” key, like MMDDYY or DDMMYY.
Example 1) AUTOPGM
INI file [CF] section:FOLDER_X=G:¥CASIO¥QT6600¥AUTOPGM
CF card file:G:¥CASIO¥QT6600¥AUTOPGM¥FILE001P.901
This case command line should be below. – convert FILE001P.901 to F.TXT.
>c_comw R F.TXT FILE001P.901 -lc -dQT6600.INI -T
Example 2) X/Z
INI file [CF] section: FOLDER_X=G:¥CASIO¥QT6600¥XZ
CF card file: G:¥CASIO¥QT6600¥XZ¥060508¥X001T01.TXT
This case command line should be below. – convert 060508¥X001T01.TXT to X.TXT.
>c_comw X X.TXT 060508¥X001T01.TXT -lc -dQT6600.INI
Note 5-4: FTP.
FTP required ECR terminal ID (IP address), login/password.
Same login/password must be set ECR program.
>c_comw R F.TXT 4 -lf -dQT6600.INI -t1 -nLOGIN -pPASS -T
In case receive Fixed Tantalizer X/Z data from FTP -lf, GT does not come.
Please receive GT data with X/Z code 30.
In case receive PLU X/Z data from FTP -lf, Shift PLU does not come with PLU data.
Please receive Shift PLU data with X/Z code 65. PLU Z receive clear Shift PLU also, then if you want to Z
receive both PLU and Shift PLU, first X receive Shift PLU and second Z receive PLU.
- 15 -
Note 5-5: Send IPL file.
ECR will receive IPL file via FTP which suffix is "*.IPL", ignore file number parameter.
ECR receive IPL file from PC (Communication Library) and works depend on ECR models as below.
(PC only can send IPL file to ECR but can not receive IPL file from ECR.)
[QT-6600]
PC send IPL file to ECR and ECR write to CF card root folder, which file name is same as PC send.
PC must send file name "QT6600.IPL" to execute JOB 90 (Execute IPL).
[SE-C6000/SE-S6000]
SE-C6000 series has no CF/RAC device then IPL file (which PC sends) write to RAM area.
Once finished all IPL data write to RAM area, ECR execute IPL from RAM area.
Send file name must be "SE6000.IPL".
1. Reserve RAM area for IPL
Before send IPL file, ECR need to be prepared RAM area for receive file same size of IPL file on PC.
This command should be sent from PC as JOB 91.
2. Send IPL file
Send IPL file "SE6000.IPL" from PC to ECR.
3. Execute IPL
PC sends JOB 90 to start IPL on ECR.
Note 5-6:”-i” Parameter in QT-6X00
- 16 -
About TCP/IP and FTP communication.
<Operation>
Example 1) PLU file receiving from QT TCP/IP communication terminal 2.
>c_comw R FILE004.TXT 4 -t2 -li -dQT6600.INI -T
Example 2) PLU file receiving from QT TCP/IP communication address 132.1.2.170.
>c_comw R FILE004.TXT 4 -t132.1.2.170 -li -dQT6600.INI -T
<INI File>
Add ini file section by TCP/IP communication.
・When QT ini file is selected, the software recognizes that TCP/IP communication is used.
Regulate the In-line communication type for [INLINE] section.
LINE=TCP/IP
← If this designation exists, the communication becomes TCP/IP.
PORT=<N>
← Offset value of PORT No. (Same setting with QT terminal.)
・ [TCP/IP] Section
Terminal IP address designation
Form:(Terminal No) = (IP address)
[TCP/IP]
ECR01=192.168.0.1
ECR02=192.168.0.50
ECR03=192.168.0.51
ECR04=192.168.0.52
DELAY=10 <-- Transmission delay time in mS for each packet. Default is 10mS
Depend on the performance of your PC but slower PC could increase this
value to gives sufficient processing time to PC, faster PC could set shorter
time to increase efficiency of communication.
FTP communication can be defined FTP connect port number.
Form:(Terminal No)=(FTP Connect Port No)
[TCP/IP]
FTPPORT01=21
FTPPORT02=500
Without this definition, FTP use default port number 21.
<How to know IP address of each ECR from PC>
Refer individual ECR designation of INI File [TCP/IP] session.
<Collection / Consolidation / Auto PGM for TCP/IP communication>
QT TCP/IP enables to communicate each terminal directory from PC.
In case collection, consolidation or auto PGM is necessary by several terminals which are connected by
In-line, please access each terminal directly from PC by designating IP address (Terminal ID)
- 17 -
not use the In-line job command and send/receive the necessary PGM/sales data by the communication
between PC and each QT terminal.
Only following Job commands are supported to use by DLL TCP/IP communication for QT.
Job No.=0001 : Send date / clock time information
Job No.=0002 : Z lock
Job No.=0003 : Z unlock
Job No.=0004 : Z lock status check
Job No.=0006 : Z reset
Job No.=0013 : Main display remote ON
Job No.=0014 : Main display remote OFF
- 18 -
5-3. File receive/send operation (Multi command).
This is used for c_comw.exe with script file name or c_comwx.dll parameter.
USG: "[Script filename] [switches…]"
[Script filename]
Specify script text file name.
Script text File describes how to execute Receive and Send of AUTOPGM, Receive Sales data, JOB
command and control command.
AUTOPGM, XZ: [R/S/S0/X/Z],[ECR File No],[PC FileName]
[R/S/S0/X/Z]:
R: Receive AUTOPGM data from ECR
S: Send AUTOPGM data to ECR. (S0 is allocating records in files with auto program 90 for QT/TE-H)
X: Receive sales data from ECR
Z: Receive sales data and execute reset on ECR
[ECR File No]:
To select a File on ECR, they are defined under ECR.
[PC FileName]:
File name in PC folder will be used for destination file of receiving AUTOPGM or X/Z and source file of
sending AUTOPGM.
If PC folder has space character, use “”.
JOB command: J Job No, [param1] [param2] …….[param N]
Job command send to ECR
Detail of JOB command, refer other chapter.
Control command: Specify sequence control command.
Wait command
The C_COMWX can execute multiple commands defined in a script file during one
communication line is connected without cutting the line. Each command line was
executed one by one at a time interval.
The new DLLs can stop moving on next command by new "wait" command that is put in
the script file. It is possible to specify how long the DLL processing is stopped.
A format of the wait command line is;
$WAIT,xxxxxxx
Note:
1) $WAIT and $wait are both OK.
2) "xxxxxxx" is the wait time (sec) and leading zero's are not be required. Example
"$WAIT,60" stops next command line execution for 60 sec.
3) The "$WAIT" should be inserted between command lines in the text file called by
c_comwx.dll.
4) The command line of the "$WAIT" does not need any option like "-T" and definition
of the initial file such as "-dc:tk7000.ini". You should mention only "$WAIT,xxxxxxx"
at the line.
“If” command and jump to a label
- 19 -
The following commands are newly available for the new DLLs so that the DLL can move
on different command lines according to a result of the communication.
“if” command
Label function
“End” command
TK7000/TE-M† series: response file (Verify the value that is stored for a specified ECR no.
in a specified file)
$if –r”¥cvw¥res.dat”[1]=0,NEXT
$if –r”res.dat”[1]=43,NEXT
QT/TE-H series: response file (Verify the value that is stored at first byte in a specified file)
$if –r”c:¥Programs Files¥cvw¥res.dat”=0,NEXT
$if –r”res.dat”=0,NEXT
Error log file (Verify the value that is stored in the last error log data)
$if –l”..¥cvw¥ecr.log”=0,NEXT
$if –l”ecr.log”=0,NEXT
a) If verified value is equal to a specified value at the right hand, then jump to a specified label.
If verified value is not equal, move to next command line.
b) The both “=” and “!=” can be used for equal character.
c) Specify a response file name in “” by using –r
d) Specify an error log file name in “” by using –l
e) It is possible to specify a location (directly) for the response file and the error log file
f) File format of the response file is different between the TK7000/TE-M† series and
QT/TE-H, however the DLL can detect the model by a definition line for ECR model in initial
file.
TK7000/TE-M † series: ECR no. is specified by adding [n] definition in the
command line. Without the definition, syntax error will happen.
QT/TE-H: The value stored in the first byte is always used for the verification.
g) If a specified file is nothing, the verification is always judged as equal. Then jump to a
specified label.
h) If an output label is nothing, the dll communication becomes error end.
An example for TK7000/TE-M† series
J,2
R,4,File004.txt
$if,-l"g:¥last¥ecr.log"=0,NEXT
R,2,File002.txt
$WAIT,10
R,5,File005.txt
J,3
$END
$,NEXT
X,15,File015x.txt
J,3
- 20 -
Example of how to make Filelist.
Expected function as follows.
1st line: Send Z lock Job command
2nd line: Receive the Fixed transaction data and Z operation
3rd line: Receive the Free Function file data and Z operation
4th line: Send PLU program data to ECR
5th line: Send Z unlock Job command
Contents of Filelist:
J,0002
Z,0001,File001z.txt
Z,0002,File002z.txt
S,0000,File004p.txt
J,0003
Example of space folder.
Z,0001,”c:¥Program Files¥CASIO¥ECR¥File001z.txt”
Z,0002,”c:¥Program Files¥CASIO¥ECR¥File002z.txt”
S,0000,”c:¥Program Files¥CASIO¥ECR¥File004p.txt”
- 21 -
5-4. Job command operation
USG: ”J JobNo [param1] [param2] ………[ParamN] switches”
JobNo=0001:
Send clock time information.
[QT/TE-H]
Param1: yymmdd information.
Param2: hhmmss information.
Param3: Send target terminal number.
Example. Set ECR time as 2001/February/03rd 23:59:00.
J 1 010203 235900 1 –dc:¥cvw¥qt2000.ini
JobNo=0002:
Z lock command
[CE/TK/TE-M†] No parameters expected
[QT/TE-H/SEC6000/SES6000]
Param1: Z lock terminal number.
Param2: Response result save file name with –o switch.
Example. Z Lock terminal 1.
J 2 1 –ores –dc:¥cvw¥qt2000.ini
JobNo=0003:
Z unlock command
[CE/TK/TE-M†] No parameters expected
[QT/TE-H/SEC6000/SES6000]
Param1: Z unlock terminal number.
Example. Z Unlock terminal 2.
J 3 2 –dc:¥cvw¥qt2000.ini
JobNo=0004:
Z lock status check
[QT/TE-H]Param1: Status check terminal number.
Param2: Response result save file name with –o switch.
Example. Z Lock status check of terminal 1 and save to “res” file if Z Lock
was successfully completed or not.
J 4 1 –ores –dc:¥cvw¥qt2000.ini
JobNo=0005:
Z Reset command
[CE/TK/TE-M†] Param1: X/Z select code
JobNo=0006:
Z Reset command.
[QT/TE-H/SEC6000/SES6000]
Param1: Z Reset Terminal number
Param2: X/Z select code
Param3: Start record (If put 0, from start record)
Param4: End record (If put 0, until end record)
Param5: Response result save file name with –o switch.
Example. Z Reset terminal 1 PLU file for all record.
J 6 1 14 0 0 –ores –dc:¥cvw¥qt2000.ini
JobNo=0013:
LCD Remote ON.
[QT/TE-H]Param1: LCD ON Terminal number
Example. LCD turn on for terminal 1.
J 13 1 –dc:¥cvw¥qt2000.ini
JobNo=0014:
LCD Remote OFF.
[QT/TE-H]Param1: LCD OFF Terminal number
Example. LCD turn off terminal 1.
- 22 -
J 14 1 –dc:¥cvw¥qt2000.ini
JobNo=0020:
Collection job among ECR start
[QT/TE-H]Param1: Target terminal number.(see NOTE 5-4)
Param2: 0=’X’,
1=’Z’
Param3: X/Z select code
Param4: Consolidation status.(see below)
Example. X Collect PLU file for all terminal.
J 20 0 0 14 81 –dc:¥cvw¥qt2000.ini
QT/TE-H collection/consolidation status value.
x80: Collection/consolidation does not include PC connected terminal.
x81: Collection/consolidation include PC connected terminal.
1xx: Ignore printer error.
2xx: Does not report print.
JobNo=0021:
Consolidation job among ECR start
[CE/TK/TE-M†] Param1: Select terminal (see NOTE 5-3)
Param2: 0=’X’,
1=’Z’
Param3: X/Z select code
Param4: 0=not issuing report 1=issuing report
Example. X Consolidation PLU file for all terminal.
J 21 A 0 14 1 –lo –dc:¥cvw¥tk7000.ini
[QT/TE-H]
Param1: Target terminal number.(see NOTE 5-4)
Param2: 0=’X’,
1=’Z’
Param3: X/Z select code
Param4: Consolidate n status.(see J 20)
Example. Z Consolidate Batch2 file for all terminal without print report.
J 21 0 1 1 281 –dc:¥cvw¥qt2000.ini
JobNo=0022:
Collection/Consolidation job among ECR start
[QT/TE-H]Param1: Target terminal number.(see NOTE 5-4)
Param2: 0=’X’,
1=’Z’
Param3: X/Z select code
Param4: Consolidation status.(see J 20)
Example. X Collect/Consolidate Fixed Totalizer file of terminal 1 and
ignore printer error.
J 22 1 0 11 181 –dc:¥cvw¥qt2000.ini
JobNo=0023:
Last Collection/Consolidation result status check.
[QT/TE-H]Param1: Target terminal number.(see NOTE 5-4)
Param2: Response result save file name with –o switch.
Example. Collection/Consolidation status check of terminal 1 and save
to “res” file.
J 23 1 -ores –dc:¥cvw¥qt2000.ini
“res” has 1 byte binary response data.
0: Normal end.
1: Busy working now.
Else: Error code.
Type of error.
1. Online communication error between PC and ECR.
This is fatal error and this error will be logged in “ecr.log” file. But there
is a possibility that this error happens under correct hardware condition.
- 23 -
2.
3.
4.
5.
JobNo=0024:
ECR’s CPU is for example too busy to communicate with a PC because
of another task.
Inside ECR. (Online communication is working)
For example Z lock request command is sent to the ECR while
registration. With CE/TK/TE-M† series, this error can not be logged in
“ecr.log” file because of single task machine. With QT/TE-H this error
can not be also logged in “ecr.log” file but can receive by response file
with –o parameter, because of multi task machine.
This is fatal error of ECR.
ECR’s CPU is too busy.
For example J 23 command is sent to the ECR while the ECR is
consolidating sales data (CPU is busy for the consolidation). This error
can be logged in “ecr.log” file, but this is not actual error. This just
indicates that the ECR can not reply to the J 23 at this moment. Please
try the J 23 once again, if possible.
Inline error between ECR and ECR.
With CE/TK/TE-M† series, this error can be received by J 401
command.
With QT/TE-H, this error can be received by response file with –o
parameter. This is fatal error for inline communication.
Inside another ECR which is not connected via online but inline.
With CE/TK/TE-M† series, this error can be received by J 401
command.
With QT/TE-H, this error can be received by response file with –o
parameter. This is fatal error.
Last remote IPL status check.
[QT6600]Param1: Target terminal number.(see NOTE 5-6)
Param2: Response result save file name with –o switch.
Example. J 24 1 -ores -lf -dQT6600.INI -t1 -nL -pP
JobNo=0016:
Build ScanPLU Index File
[QT6600] Param1: Build ScanPLU index file
Example Build ScanPLU index file at terminal number 1
J 16 1 -dC:¥CVW¥QT6000.ini
JobNo=0025:
Consolidation Report
[QT6600] Param1: Cumulate the Scan PLU daily X-reports of the slave terminals
to the master terminal and set the slave terminal X-reports to zero.
Example Cumulate the Scan PLU daily x-reports of slave terminals to
terminal number 1
J 25 1 -dC:¥CVW¥QT6000.ini
JobNo=0026
Indirect Programming
[QT6600/SEC6000/SES6000]Param1: Assume data from Scan PLU file (#70) to
Scan PLU file (#16)
Example Assume data from ScanPLU file (#70) at terminal number 1
J 26 1 -dC:¥CVW¥QT6000.ini
- 24 -
JobNo=0050:
Job start send auto program.
[QT/TE-H]Param1: Target terminal number.(see NOTE 5-4)
Param2: Target file number.
Param3: Always 0
Param4: Start record number. (If put 0, from start record)
Param5: End record number. (If put 0, until end record)
Example. J 50 2 0 0 0 –dc:¥cvw¥qt2000.ini
JobNo=0051:
Job start receive auto program.
[QT/TE-H]Param1: Target terminal number.(see NOTE 5-4)
Param2: Target file number.
Param3: Always 0
Param4: Always 0
Param5: Always 0
Example. J 51 3 0 0 0 –dc:¥cvw¥qt2000.ini
JobNo=0090:
Job start IPL
[QT6600/SEC6000/SES6000]Param1: Target terminal number.(see NOTE 5-6)
Example. J 90 1 -lf -dQT6600.INI -t1 -nL -pP
JobNo=0091:
Reserve IPL area on RAM.
[SEC6000/SES6000]
Param1: Target terminal number.(see NOTE 5-6)
Param2: IPL file bytes
Param3: Type of job
0: Reserve specified bytes.
1: for future expand.
Example. J 91 1 1862278 0 -lf ‒ dSEC6000.INI -t1 -nL -pP
File size of the IPL module may be changed in the future version.
JobNo=0215:
Not Fund PLU(NFP) file clear
[CE/TK/TE-M†] No parameters expected
JobNo=0216:
NFP maintenance file clear
[CE/TK/TE-M†] No parameters expected
JobNo=0217:
NFP or Batch maintenance file update
[CE/TK/TE-M†] Param1: file number ‘70’ for Batch maintenance file and ‘72’ for
NFP
Example. J 217 70 –dc:¥cvw¥tk7000.ini
JobNo=0300:
Auto program start command
[CE/TK/TE-M†] Param1: Auto Program select code
Param2: Select terminal ( see NOTE 5-3)
JobNo=0302:
NFP clear start command
[CE/TK/TE-M†] No parameters expected
JobNo=0303:
NFP maintenance file clear start command
[CE/TK/TE-M†] No parameters expected
- 25 -
JobNo=0304:
NFP or Batch maintenance file update start command
[CE/TK/TE-M†] Param1: file number ‘70’ for Batch maintenance file and ‘72’ for
NFP
JobNo=0305:
Z lock start command
[CE/TK/TE-M†] Param1: Select terminal (see NOTE 5-3)
JobNo=0306:
Z unlock start command
[CE/TK/TE-M†] Param1: Select terminal (see NOTE 5-3)
JobNo=0307:
Z clear start command
[CE/TK/TE-M†] Param1: X/Z select code
Param2: 0
Param3: Select terminal (see NOTE 5-3)
Example. J 307 11 0 A –lo –dc:¥cvw¥tk7000.ini
JobNo=0308:
NFP collection start command
[CE/TK/TE-M†] Param1: 0=issuing report 1= not issuing report
JobNo=0400:
Password for Online.
[CE/TK/TE-M†] Param1: Password within 8 letters
You do not have to use this job command normally, because the communication module
automatically executes Password command before starting another type of
communication and then it proceeds with the process after the password command is
performed.
If using programming tool “CVW” expect this Password, [PASSWORD] definition has
to be programmed with 8 letters profile (ini file).
The definition line in the profile (ini file) is shown below.
[PASSWORD]
password=CASIOXYZ
Caution: On CE/TK/TE-M† series, the password must be 8 character.
JobNo=0401:
Status read for all of slave terminals
[CE/TK/TE-M†] switches: -o[Response file name]
Example. J 401 –ores -lo –dc:¥cvw¥tk7000.ini
A file defined as [Response file name] will be destination written the status
of communication.
Response file format:
Header
11bytes
Example. 6E
My ID
1byte
Example. 01
Date: yy/mm/dd 3bytes
Example. 01
Time: hh/mm
2bytes
Example. 11
Exe Number
Intel short 2bytes Example. 30
Result of Term 1 Intel short 2bytes Example. 00
Result of Term 2 Intel short 2bytes Example. F4
till
Result of Term 31
Intel short 2bytes
- 26 -
3A 4A 30 34 30 31 3A 00 00 3A
01 09 (2001.Jan.09th)
56 (11:56)
01 (Job 304. Because 0130 hex)
00 (Result is 0. Normal end)
87 (Result 87F4 is 2036 error)
Result of Term 32
Intel short 2bytes
You do not have to care Header area.
Date/Time is the date/time when job has been executed.
Exe Number is internal execution Job number. NOTE 5-5
Intel short is converted hi-low byte like AA BB means BBAA hex
For example, 12 34 is 3412 hex.
Result of Terminal has code like follows.
0 is normal end
1 is before or waiting execution.
2 is not target terminal of the last job command.
8xxx is error end. (Error code body is specified at xxx).
For example 87F4 is error 7F4 hex /2036 decimal.
Terminal 32 result is available (V2.45).
NOTE 5-3:Refer to the following selecting method
Specified terminal : T[n] …… n will be 1 to 32
Select group
: G[n]……. n will be 1 to 9
All terminals
:A
When use this switch, please set connection table at ECR side, even if stand alone.
NOTE 5-4: QT/TE-H Terminal number.
0: All terminal for Collection/Consolidation (JOB 21,22,23)
1-32: Specified terminal number.
NOTE 5-5: Exe Number is available for these Job command..
Job 21 Exe Number is 21.
Job 300 Exe Number is 300.
Job 302 Exe Number is 5.
Job 303 Exe Number is 5.
Job 304 Exe Number is 304.
Job 305 Exe Number is 305.
Job 306 Exe Number is 306.
Job 307 Exe Number is 5.
Job 308 Exe Number is 308.
Other Jobs are not set in response file.
Also operated by ECR is set in response file.
NOTE 5-6: Remote IPL target terminal number.
Target terminal number need to be same as -t option.
Available line is FTP -lf only.
- 27 -
5-5. Communication Dialog
Communication Dialog is shown when communicating.
The communication title – Up load/Down load and type – can be changed by INI file.
5-5-1. Dialog example
File receive – R/X/Z command – Dialog.
File send – S command – Dialog.
JOB command Dialog.
File create command – C command – Dialog.
Multi command $WAIT Dialog.
- 28 -
5-5-2. INI file setting.
[COMDIALOG] Sectoin.
SHOWDIALOG=ON
Select show dialog (ON) or not (OFF). No definition means ON.
CANCELCAPTION=Cancel
Cancel button caption. No definition shows "Cancel".
MESSJ=Command execute
JOB command title. No definition shows "Job Command".
loMESSU=Online Uploading
Online uploading title. No definition shows "Online Uploading". STDPORT is same.
loMESSD=Online Downloading
Online downloading title. No definition shows "Online Downloading". STDPORT is same.
loMESSC=Online Creating
Online creating title. No definition shows "Online Creating". STDPORT is same.
liMESSU=INLINE File send
INLINE send title. No definition shows “Inline Uploading”.
liMESSD=INLINE File receive
INLINE receive title. No definition shows “Inline Downloading"..
lfMESSU=FTP File send
FTP send title. No definition shows “FTP Uploading”.
lfMESSD=FTP File receive
FTP send title. No definition shows “FTP Downloading”.
llMESSU= Japanese only.
llMESSD= Japanese only.
lcMESSU=CF Uploading
CF receiving. No definition shows "CF Uploading".
lcMESSD=CF Downloading
CF sending. No definition shows "CF Downloading".
* CANCELCAPTION is used when $WAIT Dialog.
- 29 -
Chapter 6. Modem communication
Communication utility has a function to dial.
This function works with Windows TAPI set on “control panel” – “ modem”, this means that you have to
choose a modem working under the Windows and to set appropriate conditions to the modem by the
“modem function”.
6-1. How to use modem communication
1. Prepare appropriate modems for the both PC side and ECR side. CASIO guarantees US Robotics 56K
FAXMODEM 5676 for Windows.
2. Install modem software in a PC. Normally it is installed with “control panel” – “modem”. It is also
important to refer to the modem manual.
3. Use a straight cable between a PC and the modem.
4. Preset ECR programming for connecting with the modem. (see NOTE 6-1)
5. Set appropriate programmable conditions to the modem at ECR side. (see NOTE 6-2)
IfTK7000/TE-M† series, you can set the modem with the ECR command via com port.
6. Set PC side parameters, like COM port, etc.
7. Run your software with modem parameter (-m option), you can see c_comw.dll calls Windows TAPI,
dial and communicate via modem. (For multiple commands in one connection line, see NOTE 6-3)
NOTE 6-1: How to preset ECR. (See also ECR manual)
If you use CE/TK/TE-M† series, set “3000” at the FILE0098 / Record number 1 for 19200bps. The
procedure for setting the parameter is; PGM3 198 [#2] 3000 [#1] [#2].
If you use QT/TE-H, please set “Activation signal” to “CI” in the I/O parameter.
NOTE 6-2: How to set the modem.
If you use CE/TK/TE-M† series, you can set the modem from ECR. First connect the modem to the
ECR via com 1 port, then operate, PGM7 4301 [#2] [#1]. If your modem command is not same as
CASIO standard, modify FILE0096 as your suitable preset.
If you use QT/TE-H, connect the modem to a PC, then set the modem by a PC. An important point is
to set as auto answer mode. About detail, refer to the modem manual.
NOTE 6-3: How to use multiple commands via modem.
C_comw.exe/dll open/close a connection line per one command. This means dial/close modem one by
one command. If you want to send multiple commands in one connection line, , please do like this.
ForTK7000/TE-M† series:
Use c_comwx.dll. (Please refer to c_comwx explanation)
For QT/TE-H:
As the C_comwx.dll does not support QT/TE-H, make the modem communication with disable
DTR control.
- 30 -
Direct and modem communication condition.
Subject
Direct communication
Communication condition.
Cabling
Com port setting
Baud rate setting
Modem
communication
Data bits: 8
Data bits: 8
Parity : NONE
Parity : NONE
Stop bits : 1
Stop bits : 1
Cross connection between PC Straight connection between PC
and ECR.
and modem, ECR and modem.
Set profile (Ini file)
Set both profile (Ini file) and
modem properties.
Set profile (Ini file)
Set modem properties.
How to use with DOS Without -m option.
c_comw.exe
or
DLL For example,
c_comw/x.dll
“R f.txt 4 -lo -dtk7000.ini -T”
With -m option.
For example,
“R f.txt 4 -lo –dtk7000.ini –T
-m012-345-6789”
See NOTE6-4.
How to use with Windows Off check Dial modem.
Dialog c_comw
Check Dial modem and set Dial
number.
Ex. [012-345-6789]
See NOTE6-4.
How to use with profile (INI [ONLINE] section, set as TEL=0.
file) preset.
Always
use
modem
communication.
[ONLINE] section, set as TEL=1
and
set
as
DIAL_COM=ATDxxxx
xxxx is dial number..
It is also important to refer to the modem manual for modem connection.
NOTE 6-4: If you use modem with c_comw –m option or c_comw Dialog, please set INI file as
not use modem, [ONLINE] section TEL= keyword as 0.
[ONLINE]
TEL=0
- 31 -
Chapter 7. Error code
7-1. The type of error
There are three types of error available for the communication.
1. PC side error
For example, when a communication error happens between PC and ECR, DOS file does not exist. This
kind of error logs into the “ecr.log” file. Refer to the “PC Error code map” shown below for each code.
2. ECR side error
For example, ECR file does not exist. This kind of error is logged into the “ecr.log” file. Refer to ECR
manual for each code.
3. Job response error
For example, ECR can not make Z lock because registration is busy. This kind of error responses to
response file (-o option). Refer to the ECR manual.
- 32 -
7-2. PC Error code
PC Error code map
Error Message string
code
0 Normal End
1 Normal Terminate.
2 Breaked by User.
4 Windows resource
100 from ECR. Illegal data.
101 from ECR. Illegal data type.
102 from ECR. Com char in bottom of packet.
103 from ECR. Over 0 count.
104 from ECR. Different machine.
105 from ECR. Memory over flow.
106 from ECR. Break end.
107 from ECR. PC disk write error.
108 from ECR. Sequence error.
128 CNET Reset error
129 CNET Reset RI error
130 CNET Reset ID error
131 CNET no token error
132 CNET packet size error
133 CNET TA retry error
144 TP NCB number over
145 TP Open error
146 TP Close error
147 TP Bind error
148 TP Heatbeat error
149 TP Not SYN received
150 TP Not connect
151 TP Not disconnect
152 TP Not NCB area
153 TP Retry over
154 TP RSPRETRY
155 TP Sequence error
156 TP ECR No port
157 TP Memory full
158 TP WAK Retry over
159 TP No active NCB
160 Terminal Busy
197 NO TARGET QUE
198 Communication time out
203 NO TARGET DSA
235 Inline protocol error
1002 No File information in the profile
Error Name
source
on Windows Message ID Win Comment
ID
No.
CERR_NONE
IDCERR_NONE
CERR_TERMINATE
IDCERR_TERMINATE
CERR_BREAK
IDCERR_BREAK
CERR_WinRESOUCE
IDCERR_WinRESOUCE
CERR_fECR_RECV
IDCERR_fECR_RECV
CERR_fECR_DTYPE
IDCERR_fECR_DTYPE
CERR_fECR_BTMP
IDCERR_fECR_BTMP
CERR_fECR_OVR0
IDCERR_fECR_OVR0
CERR_fECR_DIFF
IDCERR_fECR_DIFF
CERR_fECR_MEM_OVER
IDCERR_fECR_MEM_OVER
CERR_fECR_BREAK_BY_ECR
IDCERR_fECR_BREAK_BY_ECR
CERR_fECR_PCDISK
IDCERR_fECR_PCDISK
CERR_fECR_SEQ
IDCERR_fECR_SEQ
CERR_ARC_RESET_POR
IDCERR_ARC_RESET_POR
CERR_ARC_RESET_RI
IDCERR_ARC_RESET_RI
CERR_ARC_RESET_ID
IDCERR_ARC_RESET_ID
CERR_Arc_Send_NoToken_Err
IDCERR_Arc_Send_NoToken_Err
CERR_Arc_Send_Size_Err
IDCERR_Arc_Send_Size_Err
CERR_Arc_Send_TA_Retry_Err
IDCERR_Arc_Send_TA_Retry_Err
CERR_TP_NCB_OVER
IDCERR_TP_NCB_OVER
CERR_TP_OPEN
IDCERR_TP_OPEN
CERR_TP_CLOSE
IDCERR_TP_CLOSE
CERR_TP_BIND
IDCERR_TP_BIND
CERR_TP_HBEAT
IDCERR_TP_HBEAT
CERR_TP_NOTSYNRECV
IDCERR_TP_NOTSYNRECV
CERR_TP_NOTCONNECT
IDCERR_TP_NOTCONNECT
CERR_TP_NOTDISCONNECT
IDCERR_TP_NOTDISCONNECT
CERR_TP_NOTNCB
IDCERR_TP_NOTNCB
CERR_TP_RETRYOVER
IDCERR_TP_RETRYOVER
CERR_TP_RSPRETRY
IDCERR_TP_RSPRETRY
CERR_TP_SEQERR
IDCERR_TP_SEQERR
CERR_TP_NOPORT
IDCERR_TP_NOPORT
CERR_TP_MFULL
IDCERR_TP_MFULL
CERR_TP_WAK_RETRY_OVER
IDCERR_TP_WAK_RETRY_OVER
CERR_TP_NO_ACTIVE_NCB
IDCERR_TP_NO_ACTIVE_NCB
CERR_TP_TERMBUSY
IDCERR_TP_TERMBUSY
CERR_NOTGET_QUE
IDCERR_NOTGET_QUE
CERR_TIME_OUT
IDCERR_TIME_OUT
CERR_NOTGET_DSA
IDCERR_NOTGET_DSA
CERR_PC_NOT_IN_INI
IDCERR_PC_NOT_IN_INI
(c_util.ini)
- 33 -
10001
10002
10003
10004
10005
10006
10007
10008
10009
10010
10011
10012
10013
10014
10015
10016
10017
10018
10019
10020
10021
10022
10023
10024
10025
10026
10027
10028
10029
10030
10031
10032
10033
10034
10035
10036
10037
10038
10039
10041
CERR_PC_BREAK_BY_ECR
1007 Terminated by ECR.
CERR_PC_CNVERT
1008 Impossible to convert data
CERR_PC_FMT
1009 Illegal Format data
CERR_PC_NO_DATA
1015 No data record in the specified file.
CERR_PC_DOS_OPEN
1020 Can't open/create dos file
CERR_PC_DOS_READ
1021 Can't read Dos File.
CERR_PC_DOS_WRITE
1022 Can't write Dos File.
CERR_PC_DOS_SEEK
1023 Can't seek dos file
CERR_PC_DOS_NO_END
1026 End Of Line not found in DOS file
CERR_PC_NO_DRIVER
1027 C_NETDRV not resident
CERR_PC_DO_NOT_CNV_MEM
1031 Can't Convert Memory Data
CERR_PC_REC_LEN
1032 Record length don't match
CERR_PC_RETRYOVER
1034 Com_ReTryOver
CERR_ON_PORT_OPEN
1040 Can not open windows serial port
CERR_ON_PARAM_OPEN
1041 Windows serial port initialize error
1045 Online overlapped I/O event creation failed CERR_OS_EVNT_CREATE
1046 Online overlapped I/O secondary thread CERR_ON_THREAD_CREATIO
N
IDCERR_PC_BREAK_BY_ECR
IDCERR_PC_CNVERT
IDCERR_PC_FMT
IDCERR_PC_NO_DATA
IDCERR_PC_DOS_OPEN
IDCERR_PC_DOS_READ
IDCERR_PC_DOS_WRITE
IDCERR_PC_DOS_SEEK
IDCERR_PC_DOS_NO_END
IDCERR_PC_NO_DRIVER
IDCERR_PC_DO_NOT_CNV_MEM
IDCERR_PC_REC_LEN
IDCERR_PC_RETRYOVER
IDCERR_ON_PORT_OPEN
IDCERR_ON_PARAM_OPEN
IDCERR_OS_EVNT_CREATE
IDCERR_ON_THREAD_CREATION
10046
10047
10048
10054
10059
10060
10061
10062
10065
10066
10070
10071
10073
10079
10078
10094
10095
creation failed
2049 Abrupt file end
2050 No change in file
2051 No change in record
2052 Not enough memory available
3001 Unknown line kinds.
3002 Unknown Receive/Send mode.
3003 Not defined file number.
3004 Not defined file name.
3005 Not found profile (c_util.ini)
3006 Not found terminal number
4001 Invalid com port specified in INI file
4002 Invalid baud rate specified in INI file
4003 Invalid parity specified in INI file
4004 Invalid byte length specified in INI file
4500 Received SYN
4501 Received FIN
4502 End of File on rf_read()
4503 Parameter Error
4504 Timeout Error (User Timer)
4505 ID Error
4506 Packet or protocol error
4507 Other ID Error
4508 Wak Receive Error
4509 Other Data Receive Error
4510 Sequence Error
4511 Length Error
4512 XMODEM 5Sec Timer Error
4513 Time Out Error
4514 Re-transmission failure(by Sequence No.)
4515 SYN Receive Error
4516 FIN Receive Error
CERR_END_OF_FILE
IDCERR_END_OF_FILE
CERR_FILE_NO_CHANGE
IDCERR_FILE_NO_CHANGE
CERR_RECD_NO_CHANGE
IDCERR_RECD_NO_CHANGE
CERR_PC_NO_MEMORY
IDCERR_PC_NO_MEMORY
CERR_LINEKINDS
IDCERR_LINEKINDS
CERR_RSMODE
IDCERR_RSMODE
CERR_NOFILENO
IDCERR_NOFILENO
CERR_NOFILENAME
IDCERR_NOFILENAME
CERR_PROFILENAME
IDCERR_PROFILENAME
CERR_NOTERMNO
IDCERR_NOTERMNO
CERR_INVALID_COM_PORT
IDCERR_INVALID_COM_PORT
CERR_INVALID_SPEED
IDCERR_INVALID_SPEED
CERR_INVALID_PARITY
IDCERR_INVALID_PARITY
CERR_INVALID_BYTE_LENGT IDCERR_INVALID_BYTE_LENGTH
H
CERR_NET_SYN_RECV
IDCERR_NET_SYN_RECV
CERR_NET_FIN_RECV
IDCERR_NET_FIN_RECV
CERR_NET_EOF
IDCERR_NET_EOF
CERR_NET_ERR_PARAM
IDCERR_NET_ERR_PARAM
CERR_NET_ERR_TIMEDOUT
IDCERR_NET_ERR_TIMEDOUT
CERR_NET_ERR_IDOVER
IDCERR_NET_ERR_IDOVER
CERR_NET_ERR_OTHERPKT
IDCERR_NET_ERR_OTHERPKT
CERR_NET_ERR_OTHERSID
IDCERR_NET_ERR_OTHERSID
CERR_NET_ERR_WAK
IDCERR_NET_ERR_WAK
CERR_NET_ERR_OTHERDATA
IDCERR_NET_ERR_OTHERDATA
CERR_NET_ERR_SEQERR
IDCERR_NET_ERR_SEQERR
CERR_NET_ERR_PKFMT
IDCERR_NET_ERR_PKFMT
CERR_NET_ERR_5SEC
IDCERR_NET_ERR_5SEC
CERR_NET_ERR_NTIMER
IDCERR_NET_ERR_NTIMER
CERR_NET_ERR_RETRY
IDCERR_NET_ERR_RETRY
CERR_NET_ERR_SYN
IDCERR_NET_ERR_SYN
CERR_NET_ERR_FIN
IDCERR_NET_ERR_FIN
- 34 -
10075
10076
10077
10093
10081
10082
10083
10084
10085
10086
10087
10088
10089
10090
10096
10097
10098
10099
10100
10101
10102
10103
10116
10104
10105
10106
10107
10108
10109
10110
10111
CERR_NET_ERR_RFSEQ
4517 Not Used
CERR_NET_ERR_RFCMDRCV
4518 Received RF Command error
CERR_NET_ERR_FINSTAT
4519 Disable Transmit Error
CERR_NET_ERR_RFFMT
4520 Length Error (rf data)
4521 Socket Connect Error.
4522 Socket Receive Error.
CERR_RES_STS_BUSY
4600 JobCommand : ECR is busy
CERR_RES_STS_ZLOCK
4601 JobCommand : ECR Z locked
CERR_RES_STS_CONSOL_BUS
4602 Job Command : Console Busy
Y
CERR_RES_STS_CMDERR
4603 Job Command : Command Error
CERR_RES_STS_FILEERR
4604 Job Command : File Error
6001 Not defined Job Number
CERR_NOT_DEFINED_JOBNO
6002 XZ mode should be either 0(x mode) or CERR_XZMODE
IDCERR_NET_ERR_RFSEQ
IDCERR_NET_ERR_RFCMDRCV
IDCERR_NET_ERR_FINSTAT
IDCERR_NET_ERR_RFFMT
IDCERR_RES_STS_BUSY
IDCERR_RES_STS_ZLOCK
IDCERR_RES_STS_CONSOL_BUSY
IDCERR_RES_STS_CMDERR
IDCERR_RES_STS_FILEERR
10112
10113
10114
10115
10117
10118
10119
10120
10121
1(zmode).
6003 Master status should be either 81 or 80
6004 Date should be yymmdd format.
6005 Time should be hhmmss format.
6500 FTP Connect error
6501 FTP ECR file can not open error
6502 FTP Read communication error
6503 FTP Write communication error
6505 FTP Password error
6506 FTP server error (Normaly bad login name)
6507 FTP Response error by ECR
9996 DLL load failed
9997 Unknown Machine type or no profile.
9998 Unknown parameters
9999 Unknown error code or environment error
CERR_MASTER_STATUS
CERR_INVALID_DATE
CERR_INVALID_TIME
CERR_FTP_CONNECT
CERR_FTP_FILE_OPEN_ERROR
CERR_FTP_READ
CERR_FTP_WRITE
CERR_FTP_INCORRECT_PASS
WORD
CERR_FTP_INTERNET_EXTEN
D_ERR
CERR_FTP_RESPONSE
*1
*1
CERR_DLL_LOAD
CERR_UNKNOWN_MACHINE
IDCERR_UNKNOWN_MACHINE
CERR_UNKNOWN_PARMS
IDCERR_UNKNOWN_PARMS
CERR_PC_UNKNOWN
IDCERR_PC_UNKNOWN
10122
10091
10092
*1:QT response login or password error takes 2 seconds. If INI file section [FTP], key RW_TIMEOUT= or key
CTRL_TIMEOUT= is too small, ftp connection goes error 6500.
- 35 -
Chapter 8. Profile (INI file) and Machine ID
8-1. INI file
Profile values are very important for communication utility and CV10. Some value you can change for your
environment, but some values must not be changed.
Profile section and keyword.
Section
Key word
data sample data sample Explanation
for QT/TE
for
TK7000/TEM†
[DLL_NAMES]
C_COMW=
JOBCMD=
c_comw.dll
jobcmd.dll
475jcmd.dll
C_COMWX=
C_PARM_RG=
C_COM_BDY=
C_CNVW=
c_comwx.dll
c_parmrg.dll
c_combdy.dll
c_cnvw.dll
c_parmrg.dll
c_combdy.dll
c_cnvw.dll
C_ADDW=
c_addw.dll
c_addw.dll
Internal DLL file name. Do not change this value.
Internal DLL file name for Job command. Do not
change this value.
Internal DLL file name. Do not change this value.
Internal DLL file name. Do not change this value.
Internal DLL file name. Do not change this value.
Internal DLL file name for Text conversion. Do not
change this value.
Internal DLL file name. Do not change this value.
[PASSWORD]
PASSWORD=
Password string, if you want to use. Please care
also ECR side preset.
[SYSTEM]
MACHINE_TYPE 32
=
LOG=
ECR.LOG
LANGUAGE=
4
23
ECR Machine type. See another matrix.
ECR.LOG
4
STRATREC=
1
1
COMPRESS=
ONLINE=
STDCOM=
ON
ON
ON
ON
ON
ON
DOS result Log file name.
Character type of ECR. 0:CASIO, Do not change
this value. For reference..., 1:CASIO(Japan),
2:CASIO(Japan/TK5100)
3:CASIO(Korea),
4:ASCII(New CASIO), 5:ASCII(Shift JIS Non
support).
Start Rec No. for TEXT file. Normally from record
number 1.
Compress received (communication) data.
Use Online system.
Use Standard COM port system. (Just compatible
with VHS system)
Use PC-ECR INLINE system.
INLINE=
ON
COMMUNICATIO 1
N=
nmh=
1
OFF
1
PLU_SHIFT=
0
1
DISPTYPE=
X_START=
Y_START=
X_WIDTH=
Y_WIDTH=
0
10
3
50
5
-
0
Location of PGM1000.900.(TK7000)
0=CVW root,1=STORE¥PROGRAM
Scanning PLU shift function.
0=not available,1=available
Just compatible with DOS c_online.exe. No
meaning for Windows tool.
No meaning now.
No meaning now.
No meaning now.
No meaning now.
No meaning now.
[DISPLAY]
- 36 -
[ONLINE]
TARGET=
COM=
1
1
1
SPEED=
115200
19200
PC RS232C Port. COM=1 or COM=2. In case of
use mode, please set this value also as modem port.
Please change for your PC environment.
Select online communication baud rate. Please
change for your PC environment. If you
change this value, please care ECR preset value
also.
SPEED is valid for IPL.
USED for Uploading only
DIAL_COM For dialing modem. 0: Direct
communication or part time use modem (with –m
option). 1: Always use modem. Please change
DELAY=
TEL=
5
0
0
DIAL_COM=
ATDxxxxxx
012-345-6789
CTS_FLOW=
OFF
OFF
DSR_FLOW=
OFF
OFF
CD_FLOW=
OFF
OFF
for your modem system environment.
AT Command For dialing modem. (Available in
case of TEL=1). Please change for your
modem system environment.
XMODEM active CTS line control. Do not change
this value.
XMODEM active DSR line control. Do not change
this value.
XMODEM active CD line control. Exist only
compatible with DOS c_online.exe and modem
communication. Do not change this value.
PARITY=
BYTE_LENGTH= XMODE=
CRC1024
0
8
-
BUSYRETRY=
-
ON
TARGET=
ECRS=
1
32
-
Default inline target ECR terminal number.
Number of ECRS in inline. Use for define terminal
number as ALL
ECRnn=
192.168.0.n
192.168.0.n
DELAY=
FTPPORTnn=
10
21
-
ECR terminal No and IP address. This is reference
value when –t option used.
Defined from ECR01= to ECR32=
Send packet interval. Msec unit.
ECR terminal No and FTP Connect Port No.
This is reference value when –t option used with
FTP communication.
MenuDirectory=
-
MenuRcvSnd=
MenuFileNo=
MenuLinekinds=
MenuTermNo=
MenuFilename=
MenuConsolidate=
MenuInit=
MenuText=
MenuFileNoED=
MenuTermNoED=
-
C:¥CVW¥TK70
00.INI
1
1
0
XMODEM
Check
SUM
=
CRC1024(VHS/QT/TE-H) or SUM128(CE4000)
RF JOB Command check and wait busy status.
Also available for Z receive.
[INLINE]
[TCP/IP]
[Com default]
FILE001P.DAT
2
0
0
0
2
- 37 -
[FTP]
PASSIVE=
-
OFF
RW_TIMEOUT=
-
100000
100000
CTRL_TIMEOUT=
FTP passive mode ON/OFF.
Up to Ver4.01, this key is required also define at
[FILE_INF] section.
Ver4.10+ is not required define at [FILE_INF]
section, but only [FTP] section.
Data port timeout (msec)
Control port timeout (msec)
[CF]
FOLDER_AUTO D:¥CASIO¥QT
6600¥AUTOPG
PGM=
M
D:¥CASIO¥QT
FOLDER_X=
6600¥XZ
Z=D:¥CASIO¥
FOLDER_Z=
QT6600¥XZ
“Z”
Z=
=”精算”
MMDDYY
DATE=
=YYMMDD
CF AUTOPGM folder name
DIALOG_FONT=
SHOWDIALOG=
CANCELCAPTIO
N=
MESSJ=
loMESSU=
loMESSD=
loMESSC=
liMESSU=
liMESSD=
liMESSC=
lfMESSU=
lfMESSD=
llMESSU=
llMESSD=
lcMESSU=
lcMESSD=
Show font
Show dialog sw
Cancel button message
CF X folder name
CF Z folder name
MID-Low XZ Z string
MID-Low XZ date order
[COMDIALOG]
ON
JOB Command message
Online upload message
Online download message
Online create message
Inline upload message
Inline download message
Inline create message
Ftp upload message
Ftp download message
Local upload message
Local download message
CF upload message
CF download message
[TABLE]
ssH=
ddH
ddH
Use for conversion tool with special character. ss is
ECR character code. dd is PC character code.
When converting binary to text, convert ss code to
dd code. When converting text to binary, convert
dd code to ss code. The code which is not defined
by this section, no special character conversion
works.
ADD_MODE =
2
2
Add mode used for PRICE field. Specify an
appropriate value to your country.
QTYFIELDS=
1,5,17
1,9,124
CHARFIELDS=
6,88,89,200
13
PRICEFIELDS=
8,15,17
15
QTY Field names (n1,n2,n3,...nn). Do not change
the default values.
Character Field names (n1,n2,n3,...nn). Do not
change the default values.
Price Field names. (n1,n2,n3,...nn). Do not change
the default values.
Do not change the default values.
[MAC_CODE]
[FIELD_INF]
PLUCODEFIELDS =
34
- 38 -
BITFIELDS=
XZ_NONFIELDS=
14,27,33,...
-
XZ_NUMFIELDS 11,86
=
XZ_PGMFIELDS= 19,59,73,74
-
RECEIVEFILE=
SENDFILE=
DATAFILES=
1
1
90,92,93,47
1
1
900
MEMORY=
PGMICONS=
XZICONS=
SPECIALFILES=
PASSIVE=
90
1,2,3,...
0,1,2,3,...
-
900
1,2,3,...
11,12,13...
22,98
OFF
(file number)=
(Explanation)
(Explanation)
(file number)=
(Explanation)
(Explanation)
(XZ code)=
(Explanation)
(Explanation)
(XZ code)=
-
(File number)
(Explanation)
(Explanation)
Do not change the default values.
▲Ver4.20
The PGM field name defined here is excluded from
X/Z text file.
(See NOTE A2-2)
▲Ver4.20
The PGM field name defined here is displayed in
the X/Z text file without double quotation marks.
(See NOTE A2-2)
▲Ver4.20
The PGM field name defined here is displayed in
the X/Z text file with double quotation marks.
(See NOTE A2-2)
[FILE_INF]
[PGMICONTITL
E]
[PGMFILES]
[XZFILES]
[XZCNV_TABL
E]
[FIELD_TITLES]
(Field number)=
[ZCLR_TABLE]
[(file name)] (Example FILE0004)
Do not change the default values.
Do not change the default values.
Data(Binary) files. The files defined at this
parameter can not be converted to text.
Do not change the default values.
Do not change the default values.
Do not change the default values.
Do not change the default values.
FTP passive mode ON/OFF.
Up to Ver4.01, This definition is required both
[FTP] and [FILE_INF] section.
Ver4.10+ is required only [FTP] section.
Used for CV10.
Do not change the default values.
Presentable files.
Do not change the default values.
X/Z calculation code. (Normally, file number + 10)
Do not change the default values.
Convert X/Z code and file number. Used for
CE/TK/TE-M† series.
Do not change the default values.
Used for CV10.
Do not change the default values.
This section will be automatically updated with -i
option when converting binary to text.
ALL_FIELD_NU Number of all Number of all You do not have to update manually.
M=
fields.
fields.
PGM_FIELD_NU Number
of Number
of You do not have to update manually.
M=
presentable
presentable
fields.
fields.
STK_FIELD_NU Number of stock Number of stock You do not have to update manually.
M=
fields.
fields.
CAL_FIELD_NU Number
of Number
of You do not have to update manually.
M=
calculation
calculation
fields.
fields.
FnnN =
Field
Field
You do not have to update manually.
number, ,P/S/C/ number, ,P/S/C/
D
D
FnnL =
Field
length Field
length You do not have to update manually.
(bytes)
(bytes)
- 39 -
[(file name)_XZ]
(Example, FILE0016_XZ)
XZ_ADD_FIELD= (Non support)
01,03
[LANGUAGE]
JAPANESE=
[G_LOGO]
FILE47_D=
FILE47_S=
FILE67=
0411, M S ゴ シ
ック
432,208
432,104
432,168
FILE68=
432,168
Append
location.
Header file name=width,height(QT/TE-H)
FILE47=
[IPL]
[JMEMO]
This section will be automatically updated with -i
option when converting binary to text.
field If you want to append extra fields to X/Z receive
data, please set extra field location. For example,
1 means most left field. (See NOTE A2-1)
Font(PGMEDIT.EXE)
Country name=Country code,Font
STARTWAIT=
130
Header file name=width,height(384,168 for TE100
series.)
Wait time from cnnection to communication start.
SENDWAIT=
0
Wait time from packet to packet.
ENDWAIT=
5000
FLOW_CTRL=
NO
Wait time from communication end
disconnection. (QT/TE-H)
Flow control “YES” or “NO” (QT/TE-H)
JMEMOCMD=
0058
EJ file No.
JMEMOCNV=
OFF
Do convert received file to EJ view format.
Do not use this keyword with CV-10.
- 40 -
to
NOTE A2-1
It is not possible to append fields of a file to X/Z sales data of a different file. Only fields in the same file
can be appended by this function.
Standard X receive for FILE0016
"C","n:X0026:"
"H","27","01","0000","010201","1912","0001","01","02","00003","00000","00000","00000"
"F","FILE016","X","D"
00001,4.0000,196.00
00002,10.0000,23.00
00003,8.0000,240.00
X receive with PLU code for FILE0016
Preset as.
[FILE0016_XZ]
XZ_ADD_FIELD=01
"C","n:X0026:"
"H","27","01","0000","010201","1913","0001","01","02","00003","00000","00000","00000"
"F","FILE016","X","D"
00001,"4900000000016E",4.0000,196.00
00002,"4900000000023E",10.0000,23.00
00003,"4900000000030E",8.0000,240.00
X receive with PLU code and character for FILE0016
Preset as.
[FILE0016_XZ]
XZ_ADD_FIELD=01,03
"C","n:X0026:"
"H","27","01","0000","010201","1913","0001","01","02","00003","00000","00000","00000"
"F","FILE016","X","D"
00001,"4900000000016E","SCAN PLU 4916 ",4.0000,196.00
00002,"4900000000023E","SCAN PLU 4923 ",10.0000,23.00
00003,"4900000000030E","SCAN PLU 4930 ",8.0000,240.00
- 41 -
NOTE A2-2
These items are effective to X/Z text files with RS232C or TCP/IP. Only QT-6000, QT-6100 and QT-6600
support these items. If you want to change format, you can change like examples.
example 1.
Preset as.
[FIELD_INF]
XZ_NONFIELDS=
XZ_NUMFIELDS=11,86
XZ_PGMFIELDS= 19,59,73,74
(1)FILE002
FUNCTION CODE=86
000001,72,0.0000,0.00
000002,148,0.0000,0.00
(2)FILE004
RANDOM CODE=11
000001,123456,0.0000,0.00,0.00,0.0000,0.0000
000002,0,0.0000,0.00,0.00,0.0000,0.0000
(3)FILE005
000001,111111,0.0000,0.00,0.00
000002,0,0.0000,0.00,0.00
(4)FILE016
OBR CODE=19, CLK No=59, Time in=73, Time out=74
000001,"49177008EEEE",2.0000,2.40,0.00,"00",
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,"000000","000000"
(Each parameter is consecutive in the actual file.)
- 42 -
example 2.(german format)
Preset as.
[FIELD_INF]
XZ_NONFIELDS=
XZ_NUMFIELDS=19,11,86
XZ_PGMFIELDS= 73,74
(1)FILE002
00001,72,0.0000,0.00
00002,72,0.0000,0.00
(2)FILE004
00001,123456,2.0000,24.68,0.00,0.00,0.0000
00002,987654,1.0000,0.12,0.00,0.00,0.0000
(3)FILE005
00001,111222,1.0000,1.50,0.00
(4)FILE016
000001,49177008EEEE,2.0000,2.40,0.00,"00",
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,0.00,0.00,
0.0000,"000000","000000"
(Each parameter is consecutive in the actual file.)
- 43 -
8-2. Machine ID
Machine ID value.
Machine ID Product name
01
02
03
04
05
06
07
08
09
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
35
36
37
254
CE-4700
TK-2300
TK-2700
TK-5100
CE-4300
CE-4800
TK-1400
TK-1300
TK-2400
CE-6000 Japanese
CE-7000/7500 Japanese
TK-6000 Japanese
TK-7000/7500 Japanese
CE-4000
CE-300/TE-100/TE-2000
TK-800/TKT200/TKT-500
FE-800
CE-6000/6100
CE-7000
TK-6000
TK-7000
TK-6500
TK-7500
CE-T300/TE3000S/
TE-2200/TE-2400/TK3200
TK-T500/TE4000F/4500F
FE-500
TE-100/TE-2000 Japanese
TKT200/TKT-500 Japanese
QT-2000/2100/6000/
TE-7000S/8000F/8500F
TE-900/1500/TK-950/1550/SE-S3
00/2000/SE-C300/2000
QT-6600
SE-C6000/SE-S6000
Caution:
This chart just explains the internal ECR ID number and it does not indicate that all models can be
communicated.
- 44 -
Chapter 9. File Format
9-1. Outline
There are three types of data, which you get in a PC with the communication DLL.
1. Text data (Received data from ECR with –T option)
This type of data is created in a PC when receiving a program or a sales data from the ECR with –T
option. You can open the text data in a PC by text editor and can send back the data to the ECR.
2. Binary data (Received packed data without –T option)
This type of data is created in a PC when receiving a program or sales data from the ECR without –T
option. As the binary data requires lesser capacity than the text data, you can economize disk space.
FILE90/900:
These files should be basically received as binary data, not text data. Once you receive them as text
data (with –T option), they cannot be sent back to the ECR.
FILE90 is all of file/data with the QT/TE-H.
FILE90 is all of file/data except system files and FILE900 is all of file/data with CE/TK/TE-M†
models.
3. PGM_1000.XXX file (Created file when receiving the FILE90/900/92. CE/TK/TE-M† only)
The PGM_1000.XXX file is created in a PC when receiving the FILE90, 900 or 92. “Pgm_1000.090” is
created for FILE90. “Pgm_1000.900” file for FILE900 and “Pgm_1000.092” file for FILE92.
The file includes information on records, which are reserved in each file inside the ECR. The ECR
automatically allocates records in each file according to the information when receiving the FILE90 or
900 from a PC. The record allocating is not made with the FILE92.
As the PGM_1000.XXX file is updated every time a PC receives the FILE90, 900 or 92, keep each
PGM_1000.XXX file. This is because the PGM_1000.XXX that you got in a PC when receiving the
FILEXXX should be used for sending the FILEXXX back the ECR.
Example)
When backup from ECR
Connect with TK7000/TE-M†
>C_comw R f900tk7.dat 900 –lo –dc:¥cvw¥tk7000.ini
>copy pgm_1000.900 pgm_1000.tk7
Connect with CE6000
>C_comw R f900ce6.dat 900 –lo –dc:¥cvw¥ce6000.ini
>copy pgm_1000.900 pgm_1000.ce6
When send back to ECR.
Connect withTK7000/TE-M†
>copy pgm_1000.tk7 pgm_1000.900
>C_comw S f900tk7.dat 900 –lo –dc:¥cvw¥tk7000.ini
- 45 -
9-2. Text data format
Structure of text data.
1st line: ‘C’ Command header line
2nd line: ‘H’ Data header line
3rd line: ‘F’ File xx header line
4th line: Record number 1 data line.
5th line: Record number 2 data line.
6th line: Record number 3 data line.
until
m0 line: Record number n data line.
m1 line: ‘F’ File yy header line
m2 line: Record number 1 data line.
until
mn line: Record number n data line.
Command header
"C","n:P0004:"
File number/XZ code.
P: Program data.
X: X data.
Z: Z data.
Compress mode (No meaning)
Data header
"H","25","01","0000","001128","1144","0004","01","02","00000","00000","00000","00000"
Reserved (CE/TK/TE-M† only)
Add mode.
CHR (Normal:01/Scanning PLU:00)
System Z counter (not used)
Received Time (HH/MM)
Received Date (YY/MM/DD)
Store No
Machine ID
Machine Type
[QT-6600/SE-C6000/SE-S6000]
"h","36","01","0000","001128","1144","0004","01","02","1234"
ECR Version code
Add mode.
CHR (Normal:01/Scanning PLU:00)
System Z counter (not used)
Received Time (HH/MM)
Received Date (YY/MM/DD)
Store No
Machine ID
Machine Type
- 46 -
File header
"F","FILE004","P","P",”0001”
Z No.
"P" PGM Only
"D" CAL Only
"S" Stock
"W" WORK Area (CE/TK/TE-M† only)
Mode:
"P" PGM Mode
"X" X Mode
"Z" Z Mode
File number (File name)
Data type:
[QT-6600/SE-C6000/SE-S6000]
"f","FILE004","P","P",”0001”
Z No.
"P" PGM Only
"D" CAL Only
"S" Stock
"W" WORK Area (CE/TK/TE-M† only)
Mode:
"P" PGM Mode
"X" X Mode
"Z" Z Mode
File number (File name)
Data type:
File size (FTP protocol level only, not c_comw output file)
"S","
1361"
This file size (bytes)
This is used for check received file size is correct or not.
- 47 -
Sample PGM Text data of TK7000 PLU
"C","n:P0004:"
"H","25","01","0000","001128","1144","0004","01","02","00000","00000","00000","00000"
"F","FILE004","P","P",”0001”
00001,"PLU0001
","00000000000000","000000","000000","000100","000001",...
00002,"PLU0002
","00000000000000","000000","000000","000200","000002",...
00003,"PLU0003
","00000000000000","000000","000000","000000","000003",...
00004,"PLU0004
","00000000000000","000000","000000","000000","000004",...
00005,"PLU0005
","00000000000000","000000","000000","000000","000005",...
00006,"PLU0006
","00000000000000","000000","000000","000000","000006",...
00007,"PLU0007
","00000000000000","000000","000000","000000","000007",...
00008,"PLU0008
","00000000000000","000000","000000","000000","000008",...
00009,"PLU0009
","00000000000000","000000","000000","000000","000009",...
(until end of record…..)
Sample X Text data of TK7000 PLU.
"C","n:X0014:"
"H","25","01","0000","001128","1145","0004","01","02","00000","00000","00000","00000"
"F","FILE004","X","D",”0001”
00001,1,20.0000,20.00,0.00,0.00,0.00
00002,2,3.0000,6.00,0.00,0.00,0.00
00003,3,0.0000,0.00,0.00,0.00,0.00
00004,4,0.0000,0.00,0.00,0.00,0.00
00005,5,0.0000,0.00,0.00,0.00,0.00
00006,6,0.0000,0.00,0.00,0.00,0.00
(until end of record…..)
Sample Z Text data of TK7000 PLU.
"C","n:Z0014:"
"H","25","01","0000","001128","1145","0004","01","02","00000","00000","00000","00000"
"F","FILE004","Z","D",”0001”
00001,1,20.0000,20.00,0.00,0.00,0.00
00002,2,3.0000,6.00,0.00,0.00,0.00
00003,3,0.0000,0.00,0.00,0.00,0.00
00004,4,0.0000,0.00,0.00,0.00,0.00
00005,5,0.0000,0.00,0.00,0.00,0.00
(until end of record…..)
- 48 -
Sample PGM Text data of QT/TE-H PLU
"C","c:P0004:"
"H","32","01","0000","081128","1234","0000","00","02"
"F","FILE004","P","P","0001"
00001,"PLU001
","00000000000000","000000","000000","000.....
00002,"PLU002
","00000000000000","000000","000000","000.....
00003,"PLU003
","00000000000000","000000","000000","000.....
00004,"PLU004
","00000000000000","000000","000000","000.....
00005,"PLU005
","00000000000000","000000","000000","000.....
[QT-6600]
"C","c:P0004:"
"h","36","01","0000","081128","1234","0000","00","02","4541"
"f","FILE004","P","P","0001"
000001,"PLU001
","00000000000000000000","000000","000000","000.....
000002,"PLU002
","00000000000000000000","000000","000000","000.....
000003,"PLU003
","00000000000000000000","000000","000000","000.....
000004,"PLU004
","00000000000000000000","000000","000000","000.....
000005,"PLU005
","00000000000000000000","000000","000000","000.....
Sample Z Text data of QT/TE-H PLU
"C","c:X0014:"
"H","32","01","0000","081128","1309","0000","00","02"
"F","FILE004","X","D","0001"
00001,0.0000,0.00,0.00,0.00,0.0000
00002,0.0000,0.00,0.00,0.00,0.0000
00003,0.0000,0.00,0.00,0.00,0.0000
00004,0.0000,0.00,0.00,0.00,0.0000
00005,0.0000,0.00,0.00,0.00,0.0000
[QT-6600]
"C","c:X0014:"
"h","36","01","0000","081128","1308","0000","00","02","4541"
"f","FILE004","X","D","0001"
000001,0.00,0.0000,0.00,0.00,0.00,0.00
000002,0.00,0.0000,0.00,0.00,0.00,0.00
000003,0.00,0.0000,0.00,0.00,0.00,0.00
000004,0.00,0.0000,0.00,0.00,0.00,0.00
000005,0.00,0.0000,0.00,0.00,0.00,0.00
000006,0.00,0.0000,0.00,0.00,0.00,0.00
- 49 -
NOTE A3-1
If you prepare text program data with non-sequential record, you can send only existing record for auto
program.
For example send (S command) the following text file, PC sends only No.2,3,5 and No.7 records to ECR.
"C","n:P0004:"
"H","25","01","0000","001128","1144","0004","01","02","00000","00000","00000","00000"
"F","FILE004","P","P",”0001”
00002,"PLU0002
","00000000000000","000000","000000","000200","000002",...
00003,"PLU0003
","00000000000000","000000","000000","000000","000003",...
00005,"PLU0005
","00000000000000","000000","000000","000000","000005",...
00007,"PLU0007
","00000000000000","000000","000000","000000","000007",...
- 50 -
9-3. PGM_1000.XXX file format (CE/TK/TE-M only)
The PGM_1000.XXX file is saved as binary format.
The file includes consists of the
[FILENAME (ASCII 11bytes)]
[File creation (ASCII 1byte)]
[Number of record (Intel long 4bytes)]
[Machine ID (Binary 1byte)]
FILENAME:
File name used at ECR inside, for example, FILE0004
File creation:
“C” is stored in this field in Pgm_1000.090 and Pgm_1000.900. If “C” is in the field, the ECR creates the
file with records specified in the [Number of record] field when the file 90/900 is sent back from a PC.
No “C” is stored in the field in Pgm1000.092. Without the “C”, the ECR does not perform the file
creation.
Number of record:
When a PC receives the file 90, 900 or 92 from the ECR, the same number is automatically stored in this
field as it is allocated in the ECR.
Machine ID:
Target Machine ID. Please see Appendix 2.
- 51 -
9-4. Binary data format
Binary data file has following structure.
Header
(128 bytes)
DATA1 ‘H’,’I’,’F’
(Variable size)
DATA2 ‘I’,’F’
(Variable size)
………………………………….
DATAn ‘I’,’F’
(Variable size)
Header:
Header size is 128bytes fixed. Header has compress information, AUTOPGM/XZ, file number or XZ code.
This area will be text converted as “C” line.
Data Example: ”n:P0004:”……..”P0n”
DATA:
DATA has sections H, I and F.
ECR record data is F section.
(1) H section: Data total header.
This area will be text converted as “H” line.
QT/MID-HIGH/LOWEND series
‘H’
MC
ID
Store No
1byte 1byte
1byte 2 byte
DateTime
Notuse
5 bytes
2 bytes
QT-6600/SE-C6000/SE-S6000
‘h’
MC
ID
Store No
1byte 1byte
1byte 2 byte
DateTime
Notuse
5 bytes
2 bytes
DateTime
5 bytes
Notuse
2 bytes
MID-MID series
‘H’
MC
1byte
1byte
ID
1byte
Sinf-1
Sinf-2
Sinf-3
2bytes
2bytes
2bytes
MC:
ID:
Store No.:
DateTime (BCD/5):
CHAR:
ADD:
Store No
2 byte
Sinf-4
2 bytes
CHAR
1 byte
ADD
1byte
Notuse
2 byte
CHAR
1 byte
ADD
1byte
Notuse
2 byte
ADD
1byte
Notuse
2 bytes
CHAR
1 byte
ECR type id defined ECR mode. Some ECR has same MC.
Machine number. Specified by ECR preset.
Specified by ECR preset.
YYMMDDHHMM date time data. BCD type.
Character length. Set 0.
Add mode for amount.
- 52 -
ECRver
16 byte
Sinf-1:
Sinf-2:
Sinf-3:
Sinf-4:
ECRver:
Scanning PLU information. (Variable record size).
Scanning PLU information. (Deleted record size).
Scanning PLU information for NFP. Not used.
Scanning PLU information for NFP. Not used.
ECR application R&D version number.
(2) I section: File field information.
No text convert.
But with –I option, update INI file field information.
‘I’
LEN
FNO
CLEN
ALL
PGM
STK
CAL
F1N
F1L
F2N
F2L
1byte
Bin/2bytes
2bytes
1byte
1byte
1byte
1byte
1byte
1byte
1byte
1byte
1byte
*
FnL
1byte
LEN size area (Field information)
QT-6600/SE-C6000/SE-S6000
‘i’
LEN
FNO CLEN
1byte
Bin/2bytes
2bytes
1byte
ALL
PGM
STK
CAL
F1N
F1L
F2N
F2L
1byte
1byte
1byte
1byte
2byte
1byte
2byte
1byte
LEN size area (Field information)
LEN(BIN/2):
FNO(2):
CLEN:
ALL:
PGM:
STK:
CAL:
FnN:
FnL:
Field information size.
File number.
Character length. Not used.
Number of all fields.
Number of PGM fields.
Number of Stock fields.
Number of calculation fields.
N field ID (name).
N field length (bytes)
Field order is PGM/STK/CAL/WORK.
- 53 -
*
FnL
1byte
(3) F section: Record data.
This area will be text converted as “F” and records lines.
‘F’
FNO
Type
1byte 2bytes
1byte
Record data (Start Rec)
Record data (Start Rec+1)
Record data (Start Rec+2)
*************
Record data (End Rec)
Z counter
2bytes
LEN
2bytes
Start Rec
2bytes
End Rec
2bytes
Start Rec
4bytes
End Rec
4bytes
LEN size area (1 record size)
QT-6600/SE-C6000/SE-S6000
‘f’
FNO
Type
Z counter
1byte 2bytes
1byte
2bytes
Record data (Start Rec)
Record data (Start Rec+1)
Record data (Start Rec+2)
*************
Record data (End Rec)
LEN
4bytes
LEN size area (1 record size)
FNO (BIN/2):
Type (1):
File number..
Contents.
=1: PGM data only.
=2: Stock data only.
=3: Calculation data only.
=4: Unit price data only.
=5: All fields.
=6: Random code and character and calculation.
=7: Character and calculation.
Z counter (BCD/2): File Z counter.
LEN (BIN/2):
1 record size.
Start Rec. (BIN/2): Data start record number.
End Rec. (BIN/2): Data end record number.
- 54 -
(4) Binary data compress.
Binary data can be compressed 0 data.
How to compress is as follows.
1. Compress is done by elements.
Elements:
'H' + 15
'I' + 2 + i
i: Field information.
'F' + 11 + r * n
r: Record size. n: Number of record.
2. Compress is done by packet.
3. Compress or not.
“n:" is non compress.
"c:" is compress.
4. How to compress.
If there is series n bytes 0 (x00h) data, convert to FE, n.
If n is 1, output 0.
If FE is there, convert to FE,0.
Others output as there.
Data sample.
EX820 JP (RF) PLU
000000:
000010:
000020:
000030:
000040:
000050:
000060:
000070:
000080:
000090:
0000A0:
0000B0:
0000C0:
0000D0:
0000E0:
0000F0:
000100:
6E
00
00
00
00
00
00
00
48
00
10
16
04
22
00
00
00
3A
00
00
00
00
00
00
00
1A
00
0C
03
05
50
00
00
00
50
00
00
00
00
00
00
00
01
00
00
18
03
4C
00
00
00
30
00
00
00
00
00
00
00
00
00
03
03
05
55
00
00
00
30
00
00
00
00
00
00
00
00
00
0D
19
46
30
00
00
00
30
00
00
00
00
00
00
00
06
00
10
03
00
30
00
00
50
34
00
00
00
00
00
00
00
03
00
0E
1A
04
30
00
00
4C
3A
00
00
00
00
00
00
00
03
00
07
01
01
31
00
00
55
0D
00
00
00
00
00
00
00
13
00
10
1B
00
22
00
00
30
0A
00
00
00
00
00
00
00
33
00
06
03
02
20
00
00
30
1A
00
00
00
00
00
00
00
00
49
26
15
00
20
00
00
30
00
00
00
00
00
00
00
00
02
00
03
02
35
20
00
00
32
00
00
00
00
00
00
00
50
01
27
0F
01
00
20
00
00
20
00
00
00
00
00
00
00
4F
00
00
03
05
01
20
00
00
20
00
00
00
00
00
00
00
6E
00
04
14
02
03
20
00
00
20
00
00
00
00
00
00
00
00
00
00
03
05
E8
20
00
00
20
n:P0004:........
................
................
................
................
................
................
............POn.
H........3......
..........I.'...
..........&.....
................
....F......5....
PLU0001"
................
................
.....PLU0002
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
00
c:P0004:........
................
................
................
................
QT-6000 (XMODEM CRC1024) PLU compressed.
000000:
000010:
000020:
000030:
000040:
63
00
00
00
00
3A
00
00
00
00
50
00
00
00
00
30
00
00
00
00
30
00
00
00
00
30
00
00
00
00
34
00
00
00
00
3A
00
00
00
00
0D
00
00
00
00
0A
00
00
00
00
1A
00
00
00
00
00
00
00
00
00
- 55 -
000050:
000060:
000070:
000080:
000090:
0000A0:
0000B0:
0000C0:
0000D0:
0000E0:
0000F0:
00
00
00
48
00
03
02
05
01
20
30
00
00
00
20
35
0B
38
04
03
20
30
00
00
00
02
00
03
06
05
84
20
32
00
00
00
FE
04
51
6E
14
50
20
20
00
00
00
02
00
03
01
05
4C
20
20
00
00
00
06
17
0D
6F
1D
55
20
20
00
00
00
03
11
03
01
05
30
20
20
00
00
00
03
01
0A
70
46
30
20
20
00
00
00
11
05
02
01
00
31
20
20
00
00
00
59
06
30
71
04
20
20
20
00
00
00
FE
18
03
01
01
20
20
20
00
00
00
03
07
36
03
00
20
FE
20
00
00
50
02
07
01
05
03
20
29
20
00
00
4F
FE
27
37
01
00
20
50
20
00
00
63
02
03
01
05
41
20
4C
20
00
00
00
49
08
31
02
00
20
55
20
................
................
............POc.
H .......Y.....I
.5...........'..
...Q.....0.6.7.1
.8.n.o.p.q......
.......F......A.
..ПLU001
.)PLU
002
34
00
00
00
00
00
00
00
03
04
00
55
30
00
3A
00
00
00
00
00
00
00
03
04
01
30
30
00
0D
00
00
00
00
00
00
00
13
00
00
30
30
50
0A
00
00
00
00
00
00
00
30
00
15
30
32
4C
1A
00
00
00
00
00
00
00
00
07
00
00
20
55
00
00
00
00
00
00
00
00
00
0C
01
00
20
30
00
00
00
00
00
00
00
50
00
08
02
00
20
30
00
00
00
00
00
00
00
4F
00
05
58
00
20
30
00
00
00
00
00
00
00
6E
00
0A
82
00
20
33
00
00
00
00
00
00
00
00
00
01
A0
00
00
20
n:P0004:........
................
................
................
................
................
................
............POn.
H........0......
I...............
..F..........X あ
かさ PLU000......
...PLU0002
.
........PLU0003
EX274 (XMODEM SUM128) PLU
000000:
000010:
000020:
000030:
000040:
000050:
000060:
000070:
000080:
000090:
0000A0:
0000B0:
0000C0:
0000D0:
6E
00
00
00
00
00
00
00
48
49
09
82
00
00
3A
00
00
00
00
00
00
00
1D
00
03
A9
00
00
50
00
00
00
00
00
00
00
00
0F
46
82
00
00
30
00
00
00
00
00
00
00
00
00
00
B3
50
00
30
00
00
00
00
00
00
00
00
04
04
50
4C
00
30
00
00
00
00
00
00
00
06
00
01
4C
55
00
- 56 -
Chapter 10. Error log file (ECR.log) format
You can check ECR.log file for communication utility errors.
All of command appends at bottom of ECR.log file.
Basic format for R/S/S0/X/Z command.
1st line: Command line
2nd line: Result line
Basic format for Job command.
1st line: Job command line.
2nd line: Result line.
1.R/S/S0/X/Z Command line format.
[yy:mm:dd]-[hh:mm:ss] > C_COMBDY.DLL / <<<< parameters >>>>
<<<parameters>>>>
R/S[1]
0:Send / 1:Receive / 2:X receive / 3:Z receive.
Fno[4]
Target file number or X/Z code.
FNAME[file0004.txt]
Target DOS file name
Line[0]
0:Online / 1:Inline / 2:Standard port.
Term[0]
Target terminal number.
PROF[C:¥Cvw¥tkt500.ini]
Ini file name.
Init[0]
0:Without –i option / 1:With –i option.
Text[1]
0:Without text convert / 1:With text convert.
Consol[0]
Now, does not use.
2.Job command, Command line format.
[yy:mm:dd]-[hh:mm:ss] > JOBCMD.DLL / JOBNUMBER[<Job number>]
+ JOBSTRING[<no meaning>]
3.R/S/S0/X/Z and Job command, Result line format
[yy:mm:dd]-[hh:mm:ss] < [Error code] – [Explanation]
Explanation of error code, please see another section.
- 57 -
<Examples>
This page explains ecr.log data sample by each command.
Receive auto program:
c:¥cvw>c_comw R file0004.txt 4 -lo -dc:¥cvw¥tkt500.ini -T
01:02:01-17:57:17 > C_COMBDY.DLL / R/S[1] Fno[4] FNAME[file0004.txt] Line[0]
Term[0] PROF[C:¥Cvw¥tkt500.ini] Init[0] Text[1] Consol[0]
01:02:01-17:57:21 < 0 - Normal End
Send auto program:
c:¥cvw>c_comw S file0004.txt 4 -lo -dc:¥cvw¥tkt500.ini
01:02:01-17:59:00 > C_COMBDY.DLL / R/S[0] Fno[4] FNAME[file0004.txt] Line[0]
Term[0] PROF[C:¥Cvw¥tkt500.ini ] Init[0] Text[0] Consol[0]
01:02:01-17:59:04 < 0 - Normal End
Receive X data:
c:¥cvw>c_comw X x0004.txt 14 -lo -dc:¥cvw¥tkt500.ini -T
01:02:01-18:03:58 > C_COMBDY.DLL / R/S[2] Fno[14] FNAME[x0004.txt] Line[0]
Term[0] PROF[C:¥Cvw¥tkt500.ini] Init[0] Text[1] Consol[0]
01:02:01-18:04:01 < 0 - Normal End
Receive Z data:
c:¥cvw>c_comw Z z0004.txt 14 -lo -dc:¥cvw¥tkt500.ini -T
01:02:01-18:04:56 > C_COMBDY.DLL / R/S[3] Fno[14] FNAME[z0004.txt] Line[0]
Term[0] PROF[C:¥Cvw¥tkt500.ini] Init[0] Text[1] Consol[0]
01:02:01-18:04:59 < 0 - Normal End
01:02:01-18:04:59 > JOBCMD.DLL / JOBNUMBER[5]
+ JOBSTRING[ ]
01:02:01-18:05:00 < 0 - Normal End
* Receive Z data for CE/TK/TE-M† works Z clear job command internally.
Job command
c:¥cvw>c_comw J 21 A 0 11 0 -lo -dc:¥cvw¥tkt500.ini
01:02:01-18:06:47 > JOBCMD.DLL / JOBNUMBER[21]
+ JOBSTRING[ ]
01:02:01-18:06:48 < 0 - Normal End
- 58 -
Chapter 11. Protocol
This chapter explains communication protocol for reference.
Please Do Not Use ECR protocol directory, but use communication module.
CASIO will change protocol without notice for upgrade or bug fix.
11-1. Protocol type.
CASIO ECR has following protocols.
・ RF Protocol (RS232C)
・ XMODEM Protocol (RS232C,TCP/IP)
・ CF card file
- 59 -
11-2. RF Protocol
Outline:
RF (remote file) protocol is designed for EX445 JP Model. For international, it is updated for MID range
models. RF has RF layer and N layer.
ECR:
International and Japanese MID range models.
DATA:
N Layer
STX
SID
DID
LEN
PKT
PKS
SEQ
RF DATA
LRC
1 byte
1 byte
1 byte
2 bytes
1 byte
1 byte
1 byte
N bytes
1 byte
RF
LEN
CMD
STS
TXT
DATA
2 bytes
1 byte
1 byte
1 byte
N bytes
STX: AAH fixed
SID: Source terminal ID
DID: Destination terminal ID
LEN: Data size (from PKT to LRC)
PKT: Packet type.
00H: Connection type (with ACK response)
01H: Connection less type (without ACK response)
02H: ACK
03H, 05H to FFH: WAK
04H: Command response type (with response)
PKS: Packet status.
SEQ: Sequence counter.
01H: SYN
02H to FFH: Sequence counter.
00H: FIN
LRC: Sum o f STX to RFDATA.
- 60 -
Example of handshake (RF): Receive Fixed totalize from TE2400 via RS232C.
PC→ECR / SYN
AA FD 01 0400 04 00 01 57
PC←ECR /
AA 22 FD 0500 01 00 01 [52] 22
R
PC→ECR / APLRF_RD_FINF(0x09)
AA FD 01 1B00 04 00 02 [1500¦09¦00¦81¦6E3A2A3A46494C45303030312020203A003A] B5
( n : * : F I L E 0 0 0 1 …)
PC←ECR /
AA 22 FD A400 01 00 02 [9E00¦09¦00¦81¦6E3A88003A481B01000006030214530001010200....2020] 63
( n :
: …)
PC→ECR / SYN
AA FD 01 0400 04 00 01 57
PC←ECR /
AA 22 FD 0500 01 00 01 [52] 22
PC→ECR / APLRF_OPEN(0x02)
AA FD 01 3100 04 00 02 [2B00¦02¦00¦81¦633A443A2A3A010000003AFFFFFFFF3A813A013A46494C4530....00] F0
(c : D : * :
:
:
: : F I L E 0…)
PC←ECR /
AA 22 FD 0900 01 00 02 [0300¦02¦00¦81] FF
PC→ECR / APLRF_DATA(0x03)
AA FD 01 0900 04 00 03 [0300¦03¦00¦81] D9
PC←ECR /
AA 22 FD E901 01 00 03 [E301¦03¦00¦01¦47524F5353202020202020204E455420202020202020202043....20] 68
(G R O S S
N E T
)
PC→ECR / APLRF_DATA(0x03)
AA FD 01 0900 04 00 04 [0300¦03¦00¦81] DE
PC←ECR /
AA 22 FD E901 01 00 04 [E301¦03¦00¦00¦46534944202020202020202046534341434720202020202045....20] 63
( F S I D
F S C A C G
E B…)
PC→ECR / APLRF_DATA(0x03)
AA FD 01 0900 04 00 05 [0300¦03¦00¦81] DF
PC←ECR /
AA 22 FD ED00 01 00 05 [E700¦03¦00¦80¦54413520202020202020202054583520202020202020....58202020] EE
(T A 5
T X 5…… )
PC→ECR / APLRF_CLOSE(0x04)
AA FD 01 0B00 04 00 06 [0500¦04¦00¦81¦0000] DF
PC←ECR /
AA 22 FD 0B00 01 00 06 [0500¦04¦00¦81¦0000] F9
- 61 -
11-3. XMODEM CRC1024
Outline:
XMODEM CRC1024 protocol is designed for VHS, based on standard XMODEM protocol and fixed for
ECR. XMODEM CRC1024 Works on RS232C and Inline (TCP/IP).
ECR:
QT and MID-HIGH range.
DATA:
There is two phase and inline end phase.
Command phase.
Send request command from PC to ECR.
LEN
CMD
STS
TEXT
Command
2 bytes
1 byte
1 byte
1 byte
n byte
Data phase.
If command is send request, send data from PC to ECR. If command is receive, PC receive data
from ECR. Data is basically binary, which is before text converted.
If command is JOB, send JOB command from PC to ECR.
LEN
CMD
STS
TEXT
DATA
2 bytes
1 byte
1 byte
1 byte
n byte
End phase (Inline only)
If PC is send mode, send end data from ECR to PC.
If PC is receive mode, send end data from PC to ECR.
LEN
CMD
STS
TEXT
2 bytes
1 byte
1 byte
1 byte
LEN: Data size from CMD to DATA.
CMD: Packet command.
1: Command phase.
2: Data phase.
3: End phase (Inline only)
STS: Status
0: Normal.
Others: Something error depend on CMD.
TEXT: First/Last
bit0: First packet.
bit7: Last packet.
DATA: Command or record data.
Basically binary data without 128bytes header.
- 62 -
Example of handshake (XMODEM CRC1024): Receive Fixed totalize from QT via RS232C.
PC→ECR / DTR ON
PC←ECR / C (Command phase)
43
PC→ECR / COMMAND
01 01FE [0D00¦01¦00¦81¦633A50303030313A00FF1A1A1A1A1A1A1A1A1A1A1A1A1A1A1A...1A] CBE9
c : P 0 0 0 1 :
PC←ECR / ACK
06
PC→ECR / EOT
04
PC←ECR / ACK
06
PC→ECR / C (Data phase)
43
PC←ECR / DATA1
02 01FE [FE03¦02¦00¦01¦482002FE020603021551FE0302FE0249000D000100030100020610....00] 2DC4
PC→ECR / ACK
06
PC←ECR / DATA2
02 02FD [8301¦02¦00¦80¦544135202020202020202020202020205458352020202020202020....1A] 2DC4
PC→ECR / ACK
06
PC←ECR / EOT
04
PC→ECR / ACK
06
In case of PC send mode, C is sent from ECR first and data is sent from PC.
- 63 -
Example of handshake (XMODEM Inline): Receive Fixed totalize from QT via Inline.
PC→ECR / COMMAND
[0E00¦01¦00¦81¦63 3A 50 30 30 30 31 3A 0D 0A 1A]
c : P 0 0 0 1 :
PC←ECR / DATA
[EE01¦02¦00¦01¦48 20 01 FE 02 06 03 06 11 35 FE 03 …]
[E301¦02¦00¦80¦…………………]
* TCP/IP is stream protocol, then actual monitor data is not same.
PC→ECR / END
[0300¦03¦00¦81]
Example of handshake (XMODEM Inline): Send PLU to QT via Inline.
PC→ECR / COMMAND
[0E00¦01¦00¦81¦63 3A 53 30 30 30 30 3A 0D 0A 1A]
c : S 0 0 0 0 :
PC→ECR / DATA
[F101¦02¦00¦01¦48 20 01 FE 02 06 03 06 11 35 FE 03 …]
[nnnn¦02¦00¦00¦…………………]
[nnnn¦02¦00¦80¦…………………]
* TCP/IP is stream protocol, then actual monitor data is not same.
PC←ECR / END
[0300¦03¦00¦81]
- 64 -
11-4. XMODEM SUM128
Outline:
XMODEM SUM128 Protocol is designed for low-end models based on XMODEM CRC1024. XMODEM
SUM128 is same as CRC1024, except data size, C/NAK and check sum.
ECR:
LOW-END ECR.
DATA:
Same as CRC1024
Example of handshake (XMODEM SUM128): Send Fixed tantalizer to TE300 via RS232C.
PC→ECR / DTR ON
PC←ECR / NAK (Command phase)
15
PC→ECR / COMMAND
01 01FE [0D00¦01¦00¦81¦6E3A53303030303A00F11A1A1A1A1A1A1A1A1A1A1A1A1A1A1A1A....1A] EF
n : S 0 0 0 0 :
PC←ECR / ACK
06
PC→ECR / EOT
04
PC←ECR / ACK
06
PC←ECR / NAK (Data phase)
15
PC→ECR / DATA
01 01FE [7E00¦02¦00¦01¦4811000000000000000000000002000049000900010000000000...20] 0F
PC←ECR / ACK
06
PC→ECR / DATA
01 02FD [7E00¦02¦00¦00¦2020202020202020202020202020202020202020202020202020....C1] 21
PC←ECR / ACK
06
PC→ECR / DATA
01 03FC [7E00¦02¦00¦00¦94EF90C59399202020208FC194EF90C58D878C76202094F189DB....8F] 54
PC←ECR / ACK
06
PC→ECR / DATA
01 04FB [1600¦02¦00¦80¦912088F38E862097CC8EFB8F912020202020201A1A1A1A1A1A1A....1A] 54
PC←ECR / ACK
06
PC→ECR / EOT
04
PC←ECR / ACK
06
- 65 -
11-5. CF card
CF card means AUTOPGM file convert to/from TEXT and X/Z file convert to general CASIO X/Z format.
11-5-1. S command – PC to CF card with TEXT to BINARY convert.
>c_comw
S myfile.txt cffile.001 -lc -dQT6600.INI
Action:
C_comw read “myfile.txt” which is specified command filename, and output “cffile.001” under folder
specified on INI file [CF] section. If “myfile.txt” is TEXT file, output with binary convert.
Caution:
・
・
・
・
・
・
“myfile.txt” is CASIO standard TEXT format file.
“myfile.dat” is also OK if CASIO standard binary format which works as COPY.
RF protocol create AUTOPGM (9xx) is not supported.
QT/HIGH S0 command is same as S command. (No meaning).
If specified output file already exist, C_comw override that file.
RF protocol scanning PLU index is also appended automatically.
11-5-2. R command – CF card to PC, with TEXT converts.
>c_comw
R myfile.txt cffile.001 -lc -dQT6600.INI -T
Action:
C_comw read “cffile.001” under folder specified on INI file [CF] section, TEXT convert if –T option and
output to “myfile.txt”.
Caution:
・ RF protocol scanning PLU index is not output.
11-5-3. X and Z command – CF card to PC.
>c_comw X myfile.txt 060811¥cffile.txt -lc -dQT6600.INI
>c_comw Z myfile.txt 2006¥06¥cffile_11.csv -lc -dTE2200.INI
Action:
C_comw read “060811¥cffile.txt” under folder specified on INI file [CF] section, copy or convert and
output to “myfile.txt”. If CF file is not CASIO standard X/Z format witch is same as QT, convert CASIO
standard format.
Caution:
・ ECR preset should not be “Append character or scanning code”.
11-5-4. JOB, IPL, Create.
No support CF command.
- 66 -
11-5-5. CF card folder
CF card folder name has “CASIO”, machine name and AUTOPGM or XZ.
AUTOPGM:
Preset file is under AUTOPGM folder.
Example) ¥CASIO¥BT4000¥AUTOPGM¥[file]
X/Z – QT series:
X/Z file is under XZ¥[yymmdd] folder.
Example) ¥CASIO¥BT4000¥XZ¥060210¥[file]
X/Z – TE-Low:
X/Z file is under XZ¥[yyyy]¥[mm] folder.
Example) ¥CASIO¥TE2224¥XZ¥2006¥02¥[file]
11-5-6. CF card file name
File name includes file number, type and terminal number.
AUTOPGM:
filename.kkk
kkk:File number. Also 9xx possible.
Example) FILE001P.001
Example) mypluP.904
Example) backup.900
XZ CASIO standard – QT series
XkkkTtt.TXT
X:XorZ
kkk:File number,
tt:Terminal number.
If same file number is exist, append A,B,C,etc on file name.
Example) X001T01.TXT
Example) Z004T01.TXT
Example) Z005T01B.TXT
XZ TE-Low
Xkkk_dd.CSV
X:X or Z
kkk:File number.
dd:Day
If same file number is exist, append A,B,C,etc on file name.
Example) X001_10.CSV
Example) Z004_21.CSV
Example) Z005_31B.CSV
- 67 -
11-5-7. Different format between ECR type
CF card AUTOPGM file is same binary format for all of CASIO ECR models.
CF card X/Z file is not same format between different ECR models.
AUTOPGM:
CASIO standard binary format.
X/Z file for QT – CASIO standard X/Z format.
"C","n:X0015"
"H","32","01","0000","060210","1616","0000","00","02"
"F","FILE005","X","D","0001"
00001,0.0000,0.00,0.00
00002,0.0000,0.00,0.00
00003,0.0000,0.00,0.00
00004,0.0000,0.00,0.00
XZ file for TE-Low
"MODEL
"MACHINE
"REPORT
"FILE
"MODE
"Z COUNTER
"DATE
"TIME
","TE-2400
","MC#01 "
","DEPT
"
","FILE005"
","X "
","0001"
","02-28-2006"
","14:19"
"
"RECORD
","QUANTITY
","RED AMOUNT
",
"0001","0","0.00","0.00","0.00","0.00"
"0002","0","0.00","0.00","0.00","0.00"
","AMOUNT
","DISCOUNT
","OLD AMOUNT
X/Z text file is specified if top of file is ”C”, it is CASIO standard format, another format is
TE-Low.
CASIO standard X/Z format is same as received by ONLINE from MID range ECR.
- 68 -
11-5-8. QT CF converts flow.
CF CARD
(A-1)
F:¥CASIO¥QT6000
¥AUTOPGM¥myplu.004
¥XZ¥060206¥X001T01.TXT
¥XZ¥060206¥X002T01.TXT
(A-2)
Communication DLL
QT6000.INI
[CF]
FOLDER_AUTOPGM=G:¥CASI
O¥QT6000¥AUTOPGM
FOLDER_X=G:¥CASIO¥QT600
0¥XZ
TEXT convert
1.
2.
X/Z convert
3.
X001T01.TXT
(B-1)
myplu.txt
(B-2)
X002T01.TXT
1: c_comw R myplu.txt myplu.004 -lc -dQT6600.INI -T
2: c_comw S myplu.txt myplu.004 -lc -dQT6600.INI
3: c_comw X X001T01.txt 060206¥X001T01.txt -lc -dQT6600.INI
- 69 -
11-5-9. QT CF converts sample.
(A-1) CF card AUTOPGM file example
000000:
000010:
000020:
000030:
000040:
000050:
000060:
000070:
000080:
000090:
0000A0:
0000B0:
0000C0:
0000D0:
0000E0:
0000F0:
000100:
6E
00
00
00
00
00
00
00
48
49
08
31
00
20
00
00
00
3A
00
00
00
00
00
00
00
20
00
03
02
01
20
00
00
00
50
00
00
00
00
00
00
00
20
29
0B
38
00
20
00
00
00
30
00
00
00
00
00
00
00
00
00
03
06
41
20
00
00
00
30
00
00
00
00
00
00
00
00
04
51
6E
00
20
00
00
00
30
00
00
00
00
00
00
00
06
00
03
01
01
20
00
00
00
34
00
00
00
00
00
00
00
02
11
0D
6F
03
20
00
00
00
3A
00
00
00
00
00
00
00
14
11
03
01
84
20
00
00
00
0D
00
00
00
00
00
00
00
19
00
0A
70
50
20
00
00
00
0A
00
00
00
00
00
00
00
25
00
02
01
4C
20
00
00
50
1A
00
00
00
00
00
00
00
00
06
30
71
55
20
00
00
4C
00
00
00
00
00
00
00
00
00
18
03
01
30
20
10
00
55
00
00
00
00
00
00
00
50
00
07
36
46
30
20
00
00
30
00
00
00
00
00
00
00
4F
02
07
01
00
31
20
00
00
30
00
00
00
00
00
00
00
6E
00
27
37
04
20
20
00
00
32
00
00
00
00
00
00
00
00
00
03
01
01
20
20
00
00
20
n:P0004:........
................
................
................
................
................
................
............POn.
H ......%......
I.)...........'.
....Q.....0.6.7.
1.8.n.o.p.q.F...
...A... PLU001
................
................
.........PLU002
(A-2) CF card X/Z data example
"C","n:X0015"
"H","32","01","0000","060210","1616","0000","00","02"
"F","FILE005","X","D","0001"
00001,0.0000,0.00,0.00
00002,0.0000,0.00,0.00
00003,0.0000,0.00,0.00
00004,0.0000,0.00,0.00
00005,0.0000,0.00,0.00
(B-1) c_comw convert AUTOPGM data sample
"C","n:P0004:"
"H","32","20","0000","060214","1925","0000","00","02"
"F","FILE004","P","P","0001"
00001,"PLU001
","00000000000000","000000","001000","000000","000000"…
00002,"PLU002
","00000000000000","000000","001000","000000","000000"…
00003,"PLU003
","00000000000000","000000","001000","000000","000000"…
(B-2) c_comw X/Z data sample.
"C","n:X0015"
"H","32","01","0000","060210","1616","0000","00","02"
"F","FILE005","X","D","0001"
00001,0.0000,0.00,0.00
00002,0.0000,0.00,0.00
00003,0.0000,0.00,0.00
00004,0.0000,0.00,0.00
- 70 -
11-5-10. MID-Low CF converts sample.
AUTOPGM data is same as QT.
CF X/Z data smple.
"MODEL
"MACHINE
"REPORT
"FILE
"MODE
"Z COUNTER
"DATE
"TIME
","TE-2400
","MC#01
"
","DEPT
"
","FILE005"
","X
"
","0001"
","02-28-2006"
","14:19"
"
> ECR presettable.
> ECR presettable.
> Except GT file
[1]
[2] > ECR fixed character depend on language.
[3]
[4] > Order is depend on general pgm.
[5]
"RECORD
","QUANTITY
","AMOUNT
",
"0001","0","0.00","0.00","0.00","0.00"
"0002","0","0.00","0.00","0.00","0.00"
","DISCOUNT
","OLD AMOUNT
","RED AMOUNT
C_comw X/Z converted data
"C","n:X0005:"
"H","26","01","0000","020206","1419","0001","00","00"
"F","FILE005","X","D","0001"
00001,0,0.00,0.00,0.00,0.00
00002,0,0.00,0.00,0.00,0.00
00003,0,0.00,0.00,0.00,0.00
TE-2400 class CF XZ data is EXCEL CSV format, then c_comw convert to CASIO standard text format.
Because for use standard application which request same X/Z format for all of CASIO.
Use TE-2400 class CF X/Z general PGM should be “without character”. Even if “without character”, clerk
and hourly data has character then communication DLL ignore those character field.
"C","n:Z0005:"
[1]FileNo
[2] X/Z
"H","26","01","0000","060210","1517","0004","00","00"
[6] MCID
[4] Date
[5] Time [3] System Z counter
"F","FILE005","Z","D","0004"
[1]FileNo
[2] X/Z
[3] Z counter
- 71 -
11-6. FTP
Outline:
ECR FTP protocol is almost same as standard FTP for connect ECR FTP server.
This section explains inside of communication library use with FTP protocol.
ECR models:
QT
Data type:
Support Data type is binary and text as CASIO standard format.
Operation:
(1) S command (send)
Exaple) c_comw S myfile.txt 4 -lf -nMYEX820 -pMYPASS -dQT6600.INI -T -t1
Protocol:
Target ECR
-t Target ECR witch IP address is defined by INI file ECRxx keys.
Use name
-n Specified string witch is same as programmed ECR.
Password
-p Specified string witch is same as programmed ECR.
Control
STORE FILE004P.TXT
FILE004P.TXT is file name ECR understand.
Data
Send myfile.txt to ECR.
Error
Success: Message include 226. Ex. 226 Transfer complete.
Error: Error message. Ex. 553 Request action not taken.
Start communication: Message include 150. Ignored.
(2) R/X/Z command (receive)
Example) c_comw R/X/Z myfile.txt 4 -lf -nMYEX820 -pMYPASS -dBT4000.INI -T -t1
Protocol:
Target ECR
-t Target ECR witch IP address is defined by INI file ECRxx keys.
Use name
-n Specified string witch is same as programmed ECR.
Password
-p Specified string witch is same as programmed ECR.
Control
RETR FILE004P.TXT
FILE004P.TXT is file name ECR understand.
-T means receive as TEXT format.
without –T means receive binary format. (suffix is DAT)
Data
Write received data to myfile.txt.
Error
Success: Message include 226. Ex. 226 Transfer complete.
Error: Error message.
Start communication: Message include 150. Ignored.
(3) JOB command
Example) c_comw J 21 A 0 14 1 -lf -nMYEX820 -pMYPASS -dBT4000.INI -t1
Protocol:
Target ECR
Use name
Password
Control
Data
Error
-t Target ECR witch IP address is defined by INI file ECRxx keys.
-n Specified string witch is same as programmed ECR.
-p Specified string witch is same as programmed ECR.
STORE J_JOB.TXT
J_JOB.TXT is fixed file name for JOB command.
J_JOB.TXT has job command string.
Success: Message include 226. Ex. 226 Transfer complete.
Error: Error message.
- 72 -
Start communication: Message include 150. Ignored.
About “J_JOB.TXT”.
This file has command line string except option switchs.
End of line must have crlf. (0x0d,0x0a).
c_comw J 21 A 0 14 1 -lf -nMYEX820 -pMYPASS -dBT4000.INI
→ J 21 A 0 14 1[CrLf]
(4) Response type JOB command.
This means JOB 23.
Example) c_comw J 23 -ores -lf -nMYEX820 -pMYPASS -dQT6600.INI -t1
Protocol:
Target ECR
-t Target ECR witch IP address is defined by INI file ECRxx keys.
Use name
-n Specified string witch is same as programmed ECR.
Password
-p Specified string witch is same as programmed ECR.
Control
RETR JOBRES.DAT
JOBRES.DAT is fixed file name.
Data
Output to file (specified –o option) contents of JOBRES.DAT
Error
Success: Message include 226. Ex. 226 Transfer complete.
Error: Error message.
Start communication: Message include 150. Ignored.
Support FTP command:
USER username
PASS password
PORT ipaddress_port
RETR ex820filename
STOR ex820filename
QUIT
ECR file name (Protocol level):
ECR understand request by file name witch are file number, text/binary and X/Z or PGM.
This file name is protocol level then communication library output file name is not same.
(1) PGM (S/R command)
Text: FILEfffP.TXT (fff is file number. same as command line)
Binary: FILEfffP.DAT (fff is file number. same as command line)
Text/Binary is selected by –T.
(2) X (X command)
XkkkTtt.TXT
kkk is X file number. (not X/Z code)
tt is terminal number.
(3) Z (Z command)
ZkkkTtt.TXT
kkk is Z file number. (not X/Z code)
tt is terminal number.
(4) JOB command
J_JOB.TXT (Fixed name)
JOB command string is set at J_JOB.TXT file automatically.
(5) JOB response file (J 23 response)
JOBRES.DAT (Fixed name)
- 73 -
Response data is set JOBRES.DAT.
(6) X/Z file number.
X/Z command line number is X/Z code, but FTP file name is file number.
X/Z code – 10 = file number.
Ex. PLU:
14 -> X004T01.TXT
Ex. M&M:
61 -> Z051T01.TXT
But some file are not file number.
Clerk:
17 -> X011T01.TXT
PLU Stock:
64 -> X064T01.TXT
Error:
It possible following errors.
・ Connect time out.
・ Login name is wrong.
・ Password is wrong.
・ Specified file number is not ECR file.
・ ECR receive timeout.
・ ECR send timeout.
・ User break;
Login/Password:
ECR must be set Login and Password before use FTP.
Communication Library must specify Login and Password by –n and –p switch.
- 74 -
Example: - FTP protocol: Send fixed totalizer to ECR.
Use PORT is same as standard FTP. ECR control PORT is 21, Data PORT is 20. c_comw Data
PORT is defined INI file.
File receive:
c_comw side
−
EX820 (FTPd) side
connect
(port:Control)
"USER A"
(port:Control)
"PASS A"
(port:Control)
→
←
→
←
→
←
(port:21)
"220 FTP Service (Version 1.0) ready…."
(port:21)
"331 User name okay, need password."
(port:21)
"230 User logged in, proceed."
"PORT 129,1,51,168,5,195"
(port:Control)
"STOR FILE004P.TXT"
(port:Control)
→
←
→
←
(port:21)
"200 Command successful."
(port:21)
"150 Opening data connection."
(port:DATA)
(port:DATA)
(port:DATA)
(port:DATA)
(port:DATA)
close
←
←
←
←
←
→
connect(port:20)
DATA1
DATA2
DATAn
close
(port:20)
(port:Control)
←
"226 Transfer complete."
"QUIT"
(port:Control)
(port:Control)
close
→
(port:21)
← "221 FTP Service (Version 1.0) closing……."
←
close
→
(port:21)
- 75 -