Table of Contents

Advertisement

Quick Links

PI-10X0/PI-12X0
Basic Programming Manual
Version:2.05
Copyright © 2017 by ARGOX Information Co., Ltd.
http://www.argox.com

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the PI-10X0 and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for Argox PI-10X0

  • Page 1 PI-10X0/PI-12X0 Basic Programming Manual Version:2.05 Copyright © 2017 by ARGOX Information Co., Ltd. http://www.argox.com...
  • Page 2: Preface

    You’ll soon learn how to use BASIC language to write application programs. Please proceed and enjoy the perfect combination of PI-10X0 / PI-12X0 series Basic and PI1 series and the productivity they can boost for you in your application.
  • Page 3: Table Of Contents

    Table of Contents Preface ........................1 Table of Contents ....................2 How to run BASIC program ................. 5 User Menu ..................5 1.1.1 Run program................5 1.1.2 Remote Link ................5 1.1.3 Information................6 Program Structure..................7 Constants ..................7 2.1.1 String ..................
  • Page 4 3.10 LED Command ................54 3.11 Keypad commands ................55 3.12 LCD Commands ................63 3.13 Font ....................67 3.13.1 User font commands ..............67 3.14 TextBlock ..................69 3.14.1 TextBlock commands..............70 3.15 File manipulation commands ............74 3.15.1 Standard Commands ..............74 3.15.2 DBMS Commands ..............82 3.16 Vibrator commands .................87 3.17 Communication port commands............88...
  • Page 5 A20. LinkingPort commands ............130 A21. RFHOST commands .............. 130 A22. Simulator (Only for PC simulator) commands......131 Appendix B ......................132 Scan Module (CCD) Configuration Table ..........132 Appendix C ......................144 Scan Module (2D) Configuration Table ............144 PI1X Basic Programming Manual Ver.
  • Page 6: How To Run Basic Program

    1 How to run BASIC program 1.1 User Menu If you have already downloaded FW file, then you can view the User Menu by pressing the power key. Run program 1.1.1 If the BASIC program file (xxx.bas) in the direct path (D:\\Program\\) then you can run the BASIC program now.
  • Page 7: Information

    Information 1.1.3 You can use this item to get version information of all software and firmware parts of the system. PI1X Basic Programming Manual Ver. 1.10 6/156...
  • Page 8: Program Structure

    2 Program Structure 2.1 Constants Constants are the actual values used or generated in the program. There are two types of constants: String 2.1.1 A string constant is a sequence of up to 2048 alphanumeric characters or symbols enclosed in a pair of double quotation marks.
  • Page 9: Variable Names And Declaration Characters

    Variable Names and Declaration Characters 2.2.1 The following are the rules to declare variable names and characters:  A variable name must be begun with a letter.  The remaining characters can be letters, numbers, or underscores.  The last character can be one of these declaration characters: % (Integer) : 4 bytes (- 2147483648 to 2147483647) ! (Real number) : 8 bytes...
  • Page 10: Assignment Operator

    Assignment Operator 2.3.1 PI Basic interpreter supports an assignment operator “=” For example: Size% =100 PI! =3.1415 Str1$=”back” Arithmetic Operator 2.3.2 The arithmetic operators are: Operator Operation Example Exponentiation A% = 9^6 Negation A% = -B% Multiplication A% = B% * C% Division A% = B% / C% Addition...
  • Page 11: Operator Precedence

    Operator Operation Example Logical negation NOT (A% = B%) Logical and (A% = B%) AND (C% = Inclusive or (A% = B%) OR (C% = D%) Exclusive or (A% = B%) XOR (C% = 2.4 Operator Precedence The precedence of BASIC operators affects the evaluation of operands in expressions.
  • Page 12: Subroutines

    For example: GOTO 100 … … GOTO LABEL2 … LABEL2: … 2.6 Subroutines A subroutine is a set of instructions with a particular name or a line label. User can simplify their programming by breaking programs into subroutines. A subroutine will be executed when being called by a GOSUB command.
  • Page 13: Exit Program

    Place: PRINT "Run Place!!" RETURN SUB Test PRINT “TEST…” END SUB 2.7 Exit program  In any place of the program, you can use “END” to exit the program. The system will go to BASIC Menu. PRINT "Press key to exit!" WHILE INKEY$ = ""...
  • Page 14: Command Sets

    3 Command Sets 3.1 General commands Purpose: To return the absolute value of a numeric expression. Syntax: A% = ABS(N%) or A% = ABS(N!) Example: Num1% = 2.89 Num2% = 9.55 Difference% = ABS (Num1% - Num2%) Description: A% is numeric variable to be assigned to the absolute value of a numeric expression.
  • Page 15 GOSUB Purpose: To call a specified subroutine. Syntax: GOSUB SubName|SubLabel|SubNumber Example: GOSUB FUN GOSUB Place GOSUB 100 SUB FUN( ) PRINT "Run SUBNAME" END SUB Place: PRINT "Run SUBLABEL" RETURN PRINT "RunSUBNUMBER" RETURN Description: SubName is the name of a subroutine. SubLabel is the line label of a subroutine.
  • Page 16 Purpose: To return the largest integer that is less than or equal to the giver numeric expression. Syntax: A% = INT(N%) or A% = INT(N!) Example: A% = INT(9.86) PRINT A% B% = INT(-5.68) PRINT B% Description: A% is an integer variable to be assigned to the result. N% or N! is a numeric expression,it can be an integer or a real number.
  • Page 17 Purpose: To return an indication of the mathematical sign (+ or -) of a given numeric expression. Syntax: A% = SGN(N%) or A% = SGN(N!) Example: A% = SGN(9.86) PRINT A% B% = SGN(-5.68) PRINT B% B% = SGN(0) PRINT B% Description:...
  • Page 18: Commands For Decision Structures

    3.2 Commands for decision structures IF … THEN … {ELSE IF…} [ELSE…] END IF Purpose: To provide a decision structure for multiple-line conditional execution. Syntax: IF condition1 THEN [statements1] {ELSE IF condition2 THEN statements2} [ELSE elsestatements] END IF Example: PRINT "Input a number:" Result%=INPUT("",K%) IF K% <...
  • Page 19 ON … GOSUB … Purpose: To call one of the specified subroutines depending on the value of the expression. Syntax: ON N% GOSUB SubLabel| SubName {,SubLabel| SubName} Example: D% = DAY_OF_WEEK ON D% GOSUB MON, THE, WED, THR, FRI, SAT, SUN WHILE INKEY$=""...
  • Page 20 SubName is the line label of a subroutine. ON … GOTO … Purpose: To branch to one of several specified Line Labels depending on the value of an expression. Syntax: ON N% GOTO LineLabel | LineNumber {,LineLabel | LineNumber} Example: D% = DAY_OF_WEEK ON D% GOTO 1, 2, 3, 4, 5, 6, 7 PRINT "MONDAY"...
  • Page 21: Commands For Looping Structures

    3.3 Commands for looping structures EXIT Purpose: To provide an alternative exit for looping structures,such as FOR…NEXT and WHILE…WEND statements. Syntax: EXIT Example: WHILE 1 ‘if press ESC key IF INKEY$=CHR$(27) THEN then quit EXIT END IF WEND PRINT "EXIT..." Description:...
  • Page 22 WHILE … WEND Purpose: To repeat the execution of a block of statements while a certain condition is TRUE. Syntax: WHILE condition [Statement Block] WEND Example: N%=1 WHILE 1 PRINT "Cnt=",N% N%=N%+1 IF N%>5 THEN EXIT END IF WEND Description: If the condition is true, loop statements are executed until the WEND statement is encountered.
  • Page 23: Commands For String Processing

    3.4 Commands for string processing Purpose: To return the length of a string. Syntax: A% = LEN(S$) Example: Str$="ABCDEFGHIJK" L% = LEN(Str$) PRINT "Len. = ",L% Description: A% is an integer variable to be assigned to the result. S$ may be a string variable, string expression, or string constant.
  • Page 24 LEFT$ Purpose: To retrieve a given number of characters from the left side of the target string. Syntax: A$ = LEFT$(Str$, N%) Example: Str$ = "ABCDEFGHIJK" PRINT LEFT$(Str$,3) PRINT LEFT$("168IbB",3) Description: A$ is a string variable to be assigned to the result. Str$ may be a string variable, string expression, or string constant.
  • Page 25 RIGHT$ Purpose: To retrieve a given number of characters from the right side of the target string. Syntax: A$ = RIGHT$(Str$, N%) Example: Str$ = "ABCDEFGHIJK" PRINT RIGHT$(Str$,3) PRINT RIGHT$("168IbB",3) Description: A$ is a string variable to be assigned to the result. Str$ may be a string variable, string expression, or string constant.
  • Page 26 CHR$ Purpose: To return the character for a given ASCII value. Syntax: A$ = CHR$(N%) Example: A$=CHR$(66) 'A$='B' Description: A$ is a string variable to be assigned to the result. N% is a numeric expression in the range of 0 to 255. HEX$ Purpose:...
  • Page 27 UCASE$ Purpose: To return a copy of a string in which all lowercase letters will be converted to uppercase letters. Syntax: A$ = UCASE$(Str$) Example: Str$="abcdeFG" PRINT UCASE$(Str$) PRINT UCASE$("168BBqRrGgIbB") Description: A$ is a string variable to be assigned to the result. Str$ may be a string variable, string expression, or string constant.
  • Page 28 STRING$ Purpose: To return a string containing the specified number of the requested character. Syntax: A$ = STRING$(N%, J%) A$ = STRING$(N%, X$) Example: PRINT STRING$(10, 45) ‘ ---------- PRINT STRING$(3, "89") ‘ 888 Description: A$ is a string variable to be assigned to the result. N% is numeric expression.
  • Page 29: Commands For Event Trapping

    3.5 Commands for event trapping OFF ALL Purpose: To terminate all the event triggers. Syntax: OFF ALL Example: ON ESC GOSUB ESC_PRESS … ESC_PRESS: OFF ALL PRINT "ESC KEY PRESS..." ON ESC GOSUB ESC_PRESS RETURN Description: To resume the event trigger, call ON event GOSUB… OFF ESC Purpose:...
  • Page 30 OFF HOUR Purpose: To terminate HOUR event trigger. Syntax: OFF HOUR Example: ON HOUR GOSUB A10 … A10: OFF HOUR … ON HOUR GOSUB A10 RETURN Description: To resume the event trigger, call ON HOUR GOSUB… OFF KEY Purpose: To terminate KEY event trigger. Syntax:...
  • Page 31 OFF MINUTE Purpose: To terminate MINUTE event trigger. Syntax: OFF MINUTE Example: ON MINUTE GOSUB A10 … A10: OFF MINUTE … ON MINUTE GOSUB A10 RETURN Description: To resume the event trigger, call ON MINUTE GOSUB… OFF READER Purpose: To terminate READER event trigger. Syntax:...
  • Page 32 OFF TIMER Purpose: To terminate TIMER event trigger. Syntax: OFF TIMER(N%) Example: ON TIMER(1,200) GOSUB A1 ON TIMER(2,300) GOSUB A2 … OFF TIMER(1) … RETURN OFF TIMER(2) … RETURN Description: To resume the event trigger, call ON TIMER… GOSUB… N% is an integer variable in the range of 1 to 5, indicating the timer ID.
  • Page 33 ON ESC GOSUB Purpose: To activate ESC event trigger. Syntax: ON ESC GOSUB SubLabel | SubName Example: ON ESC GOSUB ESC_PRESS … ESC_PRESS: OFF ESC … ON ESC GOSUB ESC_PRESS RETURN Description: When ESC key is pressed, a specific subroutine will be executed.
  • Page 34 ON KEY GOSUB Purpose: To activate KEY event trigger. Syntax: ON KEY(number%) GOSUB SubLabel | SubName Example: ON KEY(1) GOSUB F1 ON KEY(2) GOSUB F2 … OFF KEY(1) … RETURN OFF KEY(2) … RETURN Description: When a function key is pressed, a specific subroutine will be executed.
  • Page 35 ON READER GOSUB Purpose: To activate READER event trigger. Syntax: ON READER(N%) GOSUB SubLabel | SubName Example: ON READER(1) GOSUB GetData … GetData: OFF READER(1) A$=GET_READER_DATA$(1,4) PRINT "DATA:"+A$ LOCATE 0,2 A$=GET_READER_DATA$(1,1) PRINT "Name:"+A$ LOCATE 0,4 PRINT GET_READER_DATALEN … ON READER(1) GOSUB GetData RETURN Description:...
  • Page 36 ON TIMER GOSUB Purpose: To activate TIMER event trigger. Syntax: ON TIMER(N%, duration%) GOSUB SubLabel | SubName Example: ON TIMER(1,200) GOSUB TimeOut … TimeOut: OFF TIMER(1) … RETURN Description: When the system runs out of the time duration specified by user, a specific subroutine will be executed.
  • Page 37 LOCK Purpose: To hold all the activated event triggers until they are released by UNLOCK. Syntax: LOCK Example: ON KEY(1) GOSUB F1 ON KEY(2) GOSUB F2 … LOCK PRINT "press F1" UNLOCK RETURN PRINT "press F2" RETURN In this example, the BASIC program can trap the KEY(1) and KEY(2) events and reroute to the subroutines F1 and F2 respectively.
  • Page 38 UNLOCK Purpose: To release all the activated event triggers held by LOCK. Syntax: UNLOCK Example: ON KEY(1) GOSUB F1 ON KEY(2) GOSUB F2 … LOCK PRINT "press F1" UNLOCK RETURN PRINT "press F2" RETURN Description: This command resumes event processing. PI1X Basic Programming Manual Ver.
  • Page 39: System Commands

    3.6 System commands AUTO_OFF Purpose: To set auto power off timer. Syntax: AUTO_OFF(N%) Example: AUTO_OFF(56) Description: N% is an integer variable in the range from 30 to 65535, indicating a specified period of time in units of 1 second. If the time interval is set to zero, this function will be disabled.
  • Page 40 Description: A% is an integer variable to be assigned to the result, it is the ordinal number of the menu item that user has selected. Item$ is a string variable, indicating the menu item that are separated and ended by carriage return (CR, 0xd). This command allows user to select an item by using the UP/DOWN arrow keys (or the shortcut keys), and then the ENTER key to confirm the selection.
  • Page 41 Example: POWER_ON(0) ‘Resume Description: N% can be set 0 or 1. Meaning Resume Reset RESTART Purpose: To restart the system. Syntax: RESTART Example: ON ESC GOSUB ESC_PRESS … ESC_PRESS: RESTART RETURN Description: This command will terminate the execution of the BASIC program and restart the system.
  • Page 42 ELSE PRINT "AID NG..." END IF WHILE INKEY$="" WEND Description: A% is an integer variable to be assigned to the result. Meaning AID not correct. AID correct. S1$ is a string variable, indicating the UserID that needs 4~8 characters. S2$ is a string variable, indicating the password that needs 4~8 characters.
  • Page 43 DATAMAGIC_SET Purpose: Set a Data Magic file for command “INPUT_DM” or “DATAMAGIC_RUN” to use. Syntax: A% = DATAMAGIC_SET(DM_file$) Example: PRINT DATAMAGIC_SET("C:\\Data\\PI-1X.dmf ") Description: A% is an integer variable to be assigned to the result. Str$ is a string variable, indicating the DataMagic setting file path.
  • Page 44: Reader Commands

    3.7 Reader commands DISABLE READER Purpose: To disable the reader ports of the terminal. Syntax: DISABLE READER(N%) Example: DISABLE READER(1) Description: N% is an integer variable, indicating the reader port (now we only can choose 1). ENABLE READER Purpose: To enable the reader ports of the terminal. Syntax:...
  • Page 45 SLEEP_READER Purpose: To set scanner module to sleep. Syntax: SLEEP_READER(N%) Example: SLEEP_READER (1) ‘Scanner to sleep Description: N% is an integer variable. Meaning Not sleep To sleep GET_READER_DATA$ Purpose: To get data that is read from a specified reader ports. Syntax:...
  • Page 46 Purpose: To get scanner type. Syntax: A% = GET_READER_TYPE Example: A% = GET_READER_TYPE Description: A% is an integer variable to be assigned to the result. Type CCD (only PI-10X0) 2D (only PI-12X0) READER_CONFIG_START Purpose: To start scanner setting procedure. Syntax: READER_CONFIG_START Example:...
  • Page 47 READER_SENDCMD Purpose: To send scanner (CCD) command to change scanner status. Syntax: A%=READER_SENDCMD(N1% , N2% , S$) Example: READER_CONFIG_START … ‘Code-39 can read A%=READER_SENDCMD(11,1, CHR$(1)) ‘‘Code-93 Checksum verification disable A%=READER_SENDCMD(12,2, CHR$(0)) ‘Preamble characters setting A%=READER_SENDCMD(8,3, "abcde") … READER_CONFIG_END Description: This command can change scanner status. A% is an integer variable to be assigned to the result.
  • Page 48 A% is an integer variable to be assigned to the result. Meaning Change fail Change OK N1% is an integer variable, indicating the parameter1. N2% is an integer variable, indicating the parameter2. S$ is a string variable. “Appendix Refer to B”...
  • Page 49 DECODE Purpose: To perform barcode decoding. Syntax: DECODE Example: ENABLE READER(1) … MAIN: IF DECODE <>0 THEN LOCATE 0,0 A$=GET_READER_DATA$(1,4) PRINT "DATA:"+A$ LOCATE 0,2 A$=GET_READER_DATA$(1,1) PRINT "Name:"+A$ LOCATE 0,4 PRINT "Length:",GET_READER_DATALEN LOCATE 0,6 A$=GET_READER_DATA$(1,2) PRINT "FULL:"+A$ LOCATE 0,8 PRINT "ID:"+GET_READER_DATA$(1,3) END IF IF INKEY$=CHR$(27) THEN DISABLE READER(1)
  • Page 50 SIM_SCANKEY_PRESS Purpose: To simulator the “Scan” key press or release. Syntax: SIM_SCANKEY_PRESS(N1%) Example: ‘Set the scan key pressed. SIM_SCANKEY_PRESS(1) … ‘Set the scan key released. SIM_SCANKEY_PRESS(0) Description: This command can simulator the scan key status for pressed or released. READER_SETFROMFILE Purpose:...
  • Page 51: Beeper Commands

    3.8 Beeper commands BEEP Purpose: To assign a beeper sequence to designate beeper operation. Syntax: BEEP(freq%, duration% {, freq%, duration%}) Example: BEEP(99,30,0,10,88,30,0,10,66,30,0,0) Description: freq% is an integer variable, indicating the value of Beep frequency ( 76000 / Actual Frequency Desired ). A beep frequency is an integer used to specify the frequency (tone) when the beeper been activated.
  • Page 52 SET_BUZZER_VOL Purpose: To set the buzzer volume. Syntax: SET_BUZZER_VOL(N%) Example: SET_BUZZER_VOL(2) Description: N% is an integer variable to be assigned to the result. Buzzer volume close Medium High PI1X Basic Programming Manual Ver. 1.10 51/156...
  • Page 53: Calendar And Timer Commands

    3.9 Calendar and timer commands DATE$ Purpose: To set or to get the current date. Syntax: DATE$ = X$ Y$ = DATE$ Example: PRINT “NOW:”+DATE$ DATE$=”20090115” PRINT “SET:”+DATE$ Description: X$ is a string variable in the form of “yyyymmdd”. DATE$ = X$, to set the current date. Y$ is a string variable to be assigned to the result.
  • Page 54 WAIT Purpose: To set system delay time. Syntax: WAIT(duration%) Example: WAIT(1000) '5sec Description: duration% is a positive integer variable, indicating the time duration for a hold. This argument is specified in units of 5 PI1X Basic Programming Manual Ver. 1.10 53/156...
  • Page 55: Led Command

    3.10 LED Command Purpose: To set the LED indicators. Syntax: LED(number%, mode%, duration%) Example: LED(2,2,100) Description: number% description LED displays green light. LED displays red light. LED displays orange light. mode% description off for (duration% X 0.01) seconds then on on for (duration% X 0.01) seconds then off flash, on then off each for (duration% X 0.01) seconds then repeat...
  • Page 56: Keypad Commands

    3.11 Keypad commands CLR_KBD Purpose: To clear the keypad buffer. Syntax: CLR_KBD Example: CLR_KBD Description: This command will clear keypad buffer. INKEY$ Purpose: To read one character from the keypad buffer then remove it. Syntax: Str$ = INKEY$ Example: START: S$=INKEY$ IF S$<>""...
  • Page 57 INPUT Purpose: To retrieve input from the keypad and store it in a variable. Syntax: A%=INPUT(S$ , variable) Example: PRINT "INPUT STRING:" ‘Input a string variable Result%=INPUT("",String$) PRINT "INPUT NUMBER:" ‘Input a numeric variable Result %=INPUT("123",Number%) Description: A% is an integer variable to be assigned to the result. Meaning Press the ENT key and has not...
  • Page 58 Input error. S$ is a string variable, indicating the input default value. variable is numeric or string variable that will receive the input data. The data entered must match the data type of the variable. When the input task is properly ended with the ENTER key being pressed, the data string will be stored in a variable.
  • Page 59 INPUT_S_SLEEP Purpose: To set scanner sleep on or off when using “INPUT_S_SLEEP” command. Syntax: INPUT_S_SLEEP(N%) Example: INPUT_S_SLEEP(1) ‘Scanner to sleep R%=INPUT_S("",S1$) … Description: N% is an integer variable. After using “INPUT_S_SLEEP” command, the “INPUT_S_SLEEP” command can set scanner to sleep or not. If use this command and set “1”, when leaving “INPUT_S”...
  • Page 60 ALPHA_LOCK Purpose: To set the ALPHA state for input mode. Syntax: ALPHA_LOCK(status%) Example: ALPHA_LOCK(1) Description: status% is a string variable, indicating the Alpha status. status% Alpha status Default input Unlock Numeric mode Lock Alpha mode (lower case) Lock Alpha mode (upper case) Lock Numeric mode GET_ALPHA_LOCK...
  • Page 61 KEYPAD_BL_TIMER Purpose: To set or get keypad backlight timer. Syntax: A% = KEYPAD_BL_TIMER KEYPAD_BL_TIMER = X% Example: KEYPAD_BL(0) PRINT "K,B timer=",KEYPAD_BL_TIMER ’Keypad backlight timer=3 KEYPAD_BL_TIMER=3 Description: A% is an integer variable to be assigned to the keypad backlight timer. X% is an integer variable indicating a period of time in units of 1-second.
  • Page 62 DEF_PKEY Purpose: To change the definition of programmable key (P1 ~ P3) . Syntax: DEF_PKEY(N1% ,N2%) Example: DEF_PKEY(1,13) ’P1 key define to ENT key DEF_PKEY(2,49) ‘P2 key define to ‘1’ key DEF_PKEY(1,21) ’P1 key define to P1 key DEF_PKEY(2,22) ‘P2 key define to P2 key ’P3 key define to UP key DEF_PKEY(3,5) ‘P2 key define to DOWN key...
  • Page 63 No profile in this Data Magic file. No match rule to convert. variable$ is string variable that will receive the input data. The data entered must match the data type of the variable. When the input task is properly ended with the ENTER key being pressed, the data string will be stored in a variable.
  • Page 64: Lcd Commands

    3.12 LCD Commands The following commands: CURSOR, CURSOR_X, CURSOR_Y, LOCATE, FILL_RECT, PRINT, CLR_RECT, CLS, SHOW_IMAGE, CLR_EOL, will only affect the current TextBlock on LCD screen. Parameters of these commands will be based on TextBlock’s size and position. BACK_LIGHT_DURATION Purpose: To specify how long the backlight will last once the terminal is turned on.
  • Page 65 CURSOR_Y Purpose: To get the y coordinate of the current cursor position in the activated TextBlock. Syntax: Y% = CURSOR_Y Example: Y% = CURSOR_Y Description: Y% is an integer variable to be assigned to the Y coordinate of the current cursor position. LOCATE Purpose:...
  • Page 66 ICON_ZONE_PRINT Purpose: To enable or disable the status bar. Syntax: ICON_ZONE_PRINT(status%) Example: ICON_ZONE_PRINT(0) Description: status% is an integer variable indicating the status bar is on or off. If using this command, all of the TextBlock setting will be reset. status% Meaning Status bar off Status bar on...
  • Page 67 Purpose: To clear the activated TextBlock. Syntax: CLS Example: CLS Description: After executing this command, whatever being shown on the LCD will be erased and the cursor will be moved to (0,0). SHOW_IMAGE Purpose: To put a rectangular bitmap in the activated TextBlock. Syntax:...
  • Page 68: Font

    3.13 Font This utility “SDK Tool” can be used as the following: When you need a font file for your application, you can make the font file by “SDK Tool”, the font generator can help you making a font file. 3.13.1 User font commands DISPFONT_SETFONT Purpose:...
  • Page 69 DISPFONT_INFO_WIDTH Purpose: To get font width. Syntax: A%=DISPFONT_INFO_WIDTH(FontID %) Example: B%=DISPFONT_INFO_WIDTH(3) Description: A% is an integer variable to be assigned to the result. FontID% is an integer variable in the range from 2 to 9. PI1X Basic Programming Manual Ver. 1.10 68/156...
  • Page 70: Textblock

    3.14 TextBlock TextBlock is a floating text printing rectangle area on LCD screen. TextBlock defines activated area anywhere within LCD screen display. An out of display area definition is not allowed. Each TextBlock has individual attribute definition for position, size, font, background color or bmp.
  • Page 71: Textblock Commands

    3.14.1 TextBlock commands DEFINETEXTBLOCK_COLOR Purpose: To define the TextBlock setting and the background using default background color or user defined color. Syntax: A%=DEFINETEXTBLOCK_COLOR (BlockNo% , FontID% , BGType% ,Color%, Column%, Row%, XPos%, YPos%) Example: Orange%=36095 A%=DEFINETEXTBLOCK_COLOR(1,0,1,Orange%,6,5,10,30) … A%=SETTEXTBLOCK(1,0) … Description A% is an integer variable to be assigned to the result.
  • Page 72 Example: A%=DEFINETEXTBLOCK_IMAGE(2,0,1,"d:\PROGRAM\5.bmp" ,8,6,120,30) Description A% is an integer variable to be assigned to the result. : Meaning Define TextBlock fail Define TextBlock OK Several key arguments as below: TextBlock number(1~15) BlockNo% FontID% Defined Font: 0~1: system font 2~9: user font. If 0 then using default background.
  • Page 73 Description: BlockNo% is an integer in the range from 1 to 15 indicating TextBlock number. PRINTTEXTBLOCK Purpose: To print Text to specific TextBlock. Syntax: PRINTTEXTBLOCK (BlockNo%, Column%, Row%, Str$ ,FontColor%) ‘font color is black Example: PRINTTEXTBLOCK(2,5,5,"Hello",0) Description: Several key arguments as below: BlockNo% TextBlock number(0~15) TextBlock column number.
  • Page 74 Description: Several key arguments as below: TextBlock number(0~15) BlockNo% Show% 1:Show cursor 0:Hide cursor 0: Cursor off. Type% 1: Cursor on, and cursor type is a line as _. 2: Cursor on, and cursor type is a line as |. 3: Cursor on, and cursor type is a block as ■.
  • Page 75: File Manipulation Commands

    3.15 File manipulation commands Standard Commands 3.15.1 Access mode string Meaning Opens file for reading operation only. Error will be returned if target file does not exist. Opens existing files for both reading and writing operations. Error will be returned if target file does not exist. Create a file and open it for both reading and writing.
  • Page 76 OPENOUT Purpose: To open (w+) a file and get the file for further processing. Syntax: F%=OPENOUT filename$ Example: FilePath$="C:\DATA\Test.DAT" fileID%=OPENOUT FilePath$ Description: F% is an integer variable to be assigned to the result. Meaning Open file failed. Other Open successfully. It returns the file. filename$ is a string variable indicating the file path.
  • Page 77  File path error. MKDIR Purpose: To create a folder. Syntax: M% = MKDIR foldername$ Example: FolderPath$="C:\ARGOX\" Result%=MKDIR FolderPath$ Description: M% is an integer variable to be assigned to the result. Meaning Create folder failed. Create folder succeed. foldername$ is a string variable, indicating the folder path.
  • Page 78 RMDIR Purpose: To delete a folder. Syntax: R% = RMDIR foldername$ Example: FolderPath$="C:\ARGOX\" Result%=RMDIR FolderPath$ Description: R% is an integer variable to be assigned to the result. Meaning Delete folder failed. Delete folder successfully. foldername$ is a string variable, indicating the folder path.
  • Page 79 BGETEXT Purpose: To read a specified number of bytes from a file. The current position is updated after reading. Syntax: STR$ = BGETEXT(N%) # FILEID% Example: STRING1$=BGETEXT(5)#FILEID% PRINT STRING1$ PRINT "STRING LEN=",LEN(STRING1$) Description: STR$ is a string to be returned to the result. N% is an integer indicating the number of bytes to be read.
  • Page 80 GET$ Purpose: Read a line terminated by a null character “\0” from a file. Syntax: FileData$ = GET$ # FILEID% Example: WHILE (EOF#FILEID% <> -1) Str$=GET$ # FILEID% PRINT Str$ WEND Description: FileData$ is a string to be returned to the result. FILEID% is an integer variable indicating the file handle.
  • Page 81 Purpose: To check if file pointer of a file reaches end of file. Syntax: E%=EOF # FILEID% Example: WHILE (EOF#FILEID% <> -1) Str$=GET$ # FILEID% PRINT Str$ WEND Description: E% is an integer to be assigned to the result. Meaning 0 (False) Not end-of-file.
  • Page 82 File specified does not exist. Illegal offset value. New position is beyond end-of-file. Purpose: To get or change file length of a file. Syntax: FILESIZE% = EXT # FILEID% EXT # FILEID% = SIZE% Example: FILESIZE%=EXT # FILEID% PRINT FILESIZE% …...
  • Page 83: Dbms Commands

    DBMS Commands 3.15.2 DBMS_INIT_SEARCH Purpose: To initiate the file search in disk. Syntax: A%=DBMS_INIT_SEARCH(FilePath$ , DBMSID% , S$ , N1% ,N2% ,N3%) Example: Result%=DBMS_INIT_SEARCH("C:\DATA\fix.DAT",1,"5,6,6",0 ,17,3) Description: A% is an integer variable to be assigned to the result. Meaning DBMS initialization fail DBMS initialization OK Open file error The DBMS ID is illegal.
  • Page 84 take care for: 1. This command cannot support Variable field length search. 2. When initial, we will make a index file in C disk, so it has to take a few time. 3. The index filename will be similar to origin file. For example, the lookup file name is “AAA.txt”, the index filename will be “AAA.idx”.
  • Page 85 Needs to insert this value, not including the symbol of line feed. This argument is the field’s quantity of each record (1~20). DBMS_CLOSE_SEARCH Purpose: To close the file search in disk. Syntax: DBMS_CLOSE_SEARCH(DBMSID%) Example: DBMS_CLOSE_SEARCH(1) Description: DBMSID% is an integer variable in the range from 1 to 10. DBMS_APPEND_DATA Purpose:...
  • Page 86 Description: A% is an integer variable to be assigned to the result. Meaning Search defeat. Other value Match the record position of data Several key arguments as below: DBMSID% DBMS ID (1~10) Search wanted field. field% Match wanted string data. key $ ※This command only supports forward search.
  • Page 87 Read record position. record % Read field position. field % DBMS_UPDATE_DATA Purpose: To revise the data of appoint field in appointed field record. Syntax: DBMS_UPDATE_DATA(DBMSID%, record%, field%, key$) Example: DBMS_UPDATE_DATA(1, 3, 3, "SONG") Description: Several key arguments as below: DBMSID% DBMS ID (1~10) Read record position.
  • Page 88: Vibrator Commands

    3.16 Vibrator commands VIBRATOR_TIMER Purpose: To set or get the vibrator timer. Syntax: A% = VIBRATOR_TIMER VIBRATOR_TIMER = X% Example: VIBRATOR_TIMER=5 … PRINT “Vibrator timer:”,VIBRATOR_TIMER Description: A% is an integer variable to be assigned as the vibrator timer. X% is an integer variable indicating a period of time in units of 100ms.
  • Page 89: Communication Port Commands

    3.17 Communication port commands CLOSE_COM Purpose: To terminate communication and disable a specified COM port. Syntax: CLOSE_COM (N%) Example: CLOSE_COM(1) Description: N% is an integer indicating which COM port is to be disabled (now we only can choose 1). OPEN_COM Purpose:...
  • Page 90 READ_COM$ Purpose: To read data from a specified COM port. Syntax: A$ = READ_COM$(N%) Example: ON COM(1) GOSUB READ1 PRINT "==COM TEST==" LOCATE 0,1 PRINT "ENT TO WRITE" SET_COM(1,1,1,2,1) OPEN_COM(1) CLEAR_COM(1) SET_RTS(1,1) LOOP2: IF INKEY$="" THEN GOTO LOOP2 END IF CLOSE_COM(1) READ1: A$=READ_COM$(1)
  • Page 91 WRITE_COM Purpose: To send a string to the host through a specified COM port. Syntax: WRITE_COM(N%, A$) Example: CLS PRINT "===COM TEST===" PRINT "ENT TO WRITE" SET_COM(1,1,1,2,1) OPEN_COM(1) WHILE INKEY$<>CHR$(13) WEND STR1$="Hello!!" WHILE GET_CTS(1)=0 WEND WRITE_COM(1,STR1$) … CLOSE_COM(1) Description: N% is an integer variable indicating which COM port the data is to be sent to (now we only can choose 1).
  • Page 92 SET_RTS Purpose: To set RTS level. Syntax: SET_RTS(N1%, N2%) Example: SET_RTS(1, 1) Description: N1% is an integer variable indicating which COM port to set RTS level (now we only can choose 1). N2% is an integer variable indicating the RTS state. Meaning Negated (Space) Asserted (Mark)
  • Page 93 FILE_TRANS Purpose: Using FILE_TRANS to upload or download files. Syntax: FILE_TRANS Example: FILE_TRANS Description: The FILE_TRANS command provides the transmission environment to link with Voler/Everlink and make file uploading or downloading. Pressing ESC key can quit the transmission operation. FILE_TRANS_REALTIME Purpose:...
  • Page 94 Description: A% is an integer variable to be assigned for the transmission baud rate. X% is an integer variable indicating baud rate to be set. FILE_TRANS_BAUD Baud rate (bps) 115200 57600 38400 19200 9600 4800 You can use the GET_FILETRANS_ERROR command to get the error code.
  • Page 95 WIFI You can use the GET_FILETRANS_ERROR command to get the error code. Possible error codes and their interpretation are listed below: GET_FILETRANS_ERRO Meaning Set OK. Selected LinkingPort is using. Parameter erro FILE_TRANS_GETBT$ Purpose: Get transmission Bluetooth information. Syntax: A$=FILE_TRANS_GETBT$ Example: S1$=FILE_TRANS_GETBT$ LocalAddress$=LEFT$(S1$,16) PRINT "LocAdd:";LocalAddress$...
  • Page 96 PRINT "LinkAddress:";LinkAddress$ PinCode$=MID$(S1$,69,20) PRINT "PinCode:";PinCode$ … Description: Use this command can get transmission’s Bluetooth settings. A$ is a string variable indicating the PI-10X0/12X0 Bluetooth information. Format of string as show below: A$(Length) Meaning PI-1X 1~16 Bluetooth MAC address.(Cannot change.) 17~36...
  • Page 97 value from 1 to 37~40 PI-1X Bluetooth security mode, if 1(on) else 0(off) 41~44 PI-1X Bluetooth encryption mode, if 1(on) else 0(off) 53~68 To linking device address. 69~88 PIN code. FILE_TRANS_GETWIFI$ Purpose: Get transmission WIFI information. Syntax: A$=FILE_TRANS_GETWIFI$ Example: … S1$=FILE_TRANS_GETWIFI$ Dhcp%=ASC(LEFT$(S1$,4)) PRINT "Dhcp:";Dhcp%...
  • Page 98 ength PI-1X WIFI Dhcp mode. PI-1X WIFI IP 5~20 address. PI-1X WIFI subnet 21~3 mask. PI-1X WIFI getway. 37~5 WIFI accesspoint 53~8 SSID name. PI-1X WIFI TX 89~9 power. 93~9 PI-1X WIFI power saving mode. 97~1 WIFI security key type. 101~ TCP connect IP address.
  • Page 99 Description: Several key arguments as below: PI-1X Bluetooth device name(Allow 1~16 characters) PI-1X Bluetooth security mode, set 1(on) or 0(off) PI-1X Bluetooth encryption mode, set 1(on) or 0(off) PI-1X Bluetooth inquiry timeout set, the value from 1(1.28 seconds) to 48(61.44 seconds). PI-1X Bluetooth inquiry max response, the value from 1 to 10.
  • Page 100 Remote TCP connect port. (allowed range 1024 to 49151) WIFI security key. (1~63 characters) You can use the GET_FILETRANS_ERROR command to get the error code. Possible error codes and their interpretation are listed below: GET_FILETRANS_ERROR Meaning Set OK. Selected LinkingPort is using. Parameter error.
  • Page 101 Parameter error. Temp buffer is full, cannot send data this time. FILE_TRANS_SENDBC_STA Purpose: Return data send temp buffer status. Syntax: N%=FILE_TRANS_SENDBC_STA Example: N%= FILE_TRANS_SENDBC_STA Description: N% is an integer to be assigned to the result. FILE_TRANS_SENDBC_CLR Purpose: Clear all data send. Syntax:...
  • Page 102 A$(Length) Meaning Data source EID(Equipmen t ID). Reveive 5~18 datetime Return the 19~22 barcode string size. (max<2000) 23~(22+size Barcode string. FILE_TRANS_READBC_STA Purpose: Return data read temp buffer status. Syntax: N%=FILE_TRANS_READBC_STA Example: N%= FILE_TRANS_READBC_STA Description: N% is an integer to be assigned to the result.
  • Page 103 Parameter error. Temp buffer is full, cannot send data this time. FILE_TRANS_SENDMSG1_STA Purpose: Return data send temp buffer status. Syntax: N%=FILE_TRANS_SENDMSG1_STA Example: N%= FILE_TRANS_SENDMSG1_STA Description: N% is an integer to be assigned to the result. FILE_TRANS_READMSG1$ Purpose: Read data from read temp buffer. Syntax:...
  • Page 104 GET_FILETRANS_ERROR Purpose: To get the FILE_TRANS error code. Syntax: N%=GET_FILETRANS _ERROR Example: N%=GET_FILETRANS _ERROR Description: N% is an integer to be assigned to the result. FILE_TRANS_STA Purpose: When using RemoteLink_RealTime,to return file transfer status. Syntax: N%=FILE_TRANS_ STA Example: N%= FILE_TRANS_ STA Description:...
  • Page 105 Description: Several key arguments as below: Type% 1: Get upload information 2: Get download information. Num% Which file to get. For example, if there are three files transferred success, when you want to get the first file information, the parameter will be filled in 0. A$ is a string variable to be assigned to the result.
  • Page 106: Memory Commands

    3.18 Memory commands RAM_SIZE Purpose: To check the total space in disk C. Syntax: RAMSIZE% = RAM_SIZE Example: PRINT "RAM_SIZE=",RAM_SIZE Description: RAMSIZE% is an integer variable to be assigned for the total space in disk C. ROM_SIZE Purpose: To check the total space in disk D. Syntax:...
  • Page 107: Usb Commands

    3.19 USB commands USB_OPEN Purpose: To initialize and enable USB port. Syntax: USB_OPEN Example: USB_OPEN Description: Using USB_OPEN command can initialize and enable the USB port. USB_CLOSE Purpose: To close the USB port. Syntax: USB_CLOSE Example: USB_CLOSE Description: Using USB_CLOSE command can disable and suspend the USB port.
  • Page 108: Linkingport Commands

    3.20 LinkingPort commands LINKPORT_OPEN Purpose: Start a LinkingPort. Syntax: N1%=LINKPORT_OPEN(N2%) Example: Result%=LINKPORT_OPEN(Port%) … Result%=LINKPORT_CLOSE(Port%) Description: Use this command can start a LinkingPort. Before use this command, you have to set LinkingPort’s setting by using “LINKPORT_SETxxx” command. N1% is an integer variable to be assigned to the result. Meaning Open LinkingPort success.
  • Page 109 LINKPORT_SELECTIF Purpose: Set LinkingPort interface select setting. Syntax: N1%=LINKPORT_SELECTIF(N2%,N3%) Example: Result%=LINKPORT_SELECTIF(Port%, Interface%) Description: Use this command can select a LinkingPort’s interface. Before use this command, you have to close LinkingPort. N1% is an integer variable to be assigned to the result. Meaning Set LinkingPort interface success.
  • Page 110 LINKPORT_SETCOM Purpose: Set LinkingPort COM baudrate setting. Syntax: N1%=LINKPORT_SETCOM(N2%, N3%) Example: Result%=LINKPORT_SETCOM(Port%, Baud%) Description: Use this command can set LinkingPort’s COM baudrate. Before use this command, you have to close LinkingPort. N1% is an integer variable to be assigned to the result. Meaning Success.
  • Page 111 N2% is an integer variable indicating LinkingPort’s port number. The value is form 1 to 4. LINKPORT_SETBT Purpose: Set LinkingPort Bluetooth function setting. Syntax: N1%=LINKPORT_SETBT(N2%, S1$, N3%, N4%, N5%, N6%, S2$, S3$) Example: Result%=LINKPORT_SETBT(Port%, LocalName$, 1, 1, 3, 10, DeviceAddress$, PIN$) Description:...
  • Page 112 PRINT "LocName:";LocalName$ LocalSec%=ASC(MID$(S1$,45,4)) PRINT "LocalSec:";LocalSec% LocalEnc%=ASC(MID$(S1$,49,4)) PRINT "LocalEnc:";LocalEnc% LocalTimeout%=ASC(MID$(S1$,37,4)) PRINT "LocalTimeout:";LocalTimeout% LocalRes%=ASC(MID$(S1$,42,4)) PRINT "LocalRes:";LocalRes% LinkAddress$=MID$(S1$,53,16) PRINT "LinkAddress:";LinkAddress$ PinCode$=MID$(S1$,69,20) PRINT "PinCode:";PinCode$ … Description: A$ is a string variable indicating the PI-1010/1030 Bluetooth information.Format of string as show below: A$(Length) Meaning PI-1X Bluetooth MAC address.(Cannot change.) 1~16 17~36 PI-1X Bluetooth device name...
  • Page 113 LINKPORT_SETWIFI Purpose: Set LinkingPort WIFI setting. Syntax: N1%=LINKPORT_SETWIFI(N2%,N3%,S1$,S2$,S3$,S4$,N4%,N 5%, S5$,N6%,S6$,N7%) Example: LINKPORT_SETWIFI(Port%,0,IP$,MK$,GW$,SSID$,1,2, CONNIP$,PORT%,KEY$,ADHOC%) LINKPORT_SETWIFI(Port%,1,"","","", SSID$,1,2, CONNIP$,PORT%,KEY$, ADHOC%) 'Use DHCP Description: Use this command can set LinkingPort’s WIFI setting. Before use this command, you have to close LinkingPort. N1% is an integer variable to be assigned to the result. Meaning Success.
  • Page 114 LOCATE 1,4 IpAddress$=MID$(S1$,5,20) PRINT "IpAdd:";IpAddress$ Port1$=MID$(S1$,117,1) Port2$=MID$(S1$,118,1) ConnPort%=ASC(Port1$)+ASC(Port2$)*256 PRINT "ConnectPort:"; ConnPort% … Description: Use this command can get LinkingPort’s WIFI settings. A$ is a string variable indicating the PI-1X30 WIFI information.Format of string as show below: A$(Length) Meaning PI-1X WIFI Dhcp mode. PI-1X WIFI IP address.
  • Page 115 ELSE AA%=LINKPORT_WRITE(1,A$,1) IF AA%>0 THEN PRINT A$; END IF END IF END IF STR1$=LINKPORT_READ$(1,1) IF LEN(STR1$)<>0 THEN PRINT STR1$; END IF WEND … A%=LINKPORT_CLOSE(1) … Description: After opening LinkingPort, you can write characters to that LinkingPort. N1% is an integer variable.It will tell you how many characters send to that LinkingPort device and other mean as bellow: Meaning >=0...
  • Page 116 EXIT ELSE AA%=LINKPORT_WRITE_N(1,A$,1) IF AA%>0 THEN PRINT A$; END IF END IF END IF STR1$=LINKPORT_READ_N$(1,1) IF LEN(STR1$)<>0 THEN PRINT STR1$; END IF WEND … A%=LINKPORT_CLOSE(1) … Description: After opening LinkingPort, you can write characters to that LinkingPort. N1% is an integer variable.It will tell you how many characters send to that LinkingPort device and other mean as bellow: Meaning >=0...
  • Page 117 IF A$<>"" THEN IF(ASC(A$)=27) THEN EXIT ELSE AA%=LINKPORT_WRITE(1,A$,1) IF AA%>0 THEN PRINT A$; END IF END IF END IF STR1$=LINKPORT_READ$(1,1) IF LEN(STR1$)<>0 THEN PRINT STR1$; END IF WEND … A%=LINKPORT_CLOSE(1) … Description: After opening LinkingPort, you can read characters from that LinkingPort.
  • Page 118 END IF END IF END IF STR1$=LINKPORT_READ_N$(1,1) IF LEN(STR1$)<>0 THEN PRINT STR1$; END IF WEND … A%=LINKPORT_CLOSE(1) … Description: After opening LinkingPort, you can read characters from that LinkingPort. A$ is a string variable to be assigned the characters is read from that LinkingPort.
  • Page 119: Rfhost (Only For Pi-1060) Commands

    3.21 RFHOST (Only for PI-1060) commands RFHOST_OPEN Purpose: Start RF module. Syntax: N1%=RFHOST_OPEN Example: Result%=RFHOST_OPEN … RFHOST_CLOSE Description: The command will start the RF module work. When open RF module, the module need 1 second to start. N1% is an integer variable to be assigned to the result. Meaning Open fail.
  • Page 120: Simulator (Only For Pc Simulator) Commands

    Loop:For beep loop times, 0 and 1=> 1time, 2 =>2times, 3=>3times Beep1~3:For beep time. 0 and 1=> 100ms, 2=>200ms, 3=>300ms Stop: For beep stop time. 0 and 1=> 100ms, 2=>200ms, 3=>300ms N1% is an integer variable to be assigned to the result. Meaning Success.
  • Page 121: Appendices

    4 Appendices Appendix A PI series Basic Commands list General commands Command description To return the absolute value of a numeric expression. To specify the maximum value of variable subscripts and to allocate storage accordingly. GOSUB To call a specified subroutine. GOTO To branch unconditionally to a specified line number or line label from the normal...
  • Page 122: Commands For Looping Structures

    Commands for looping structures Command description EXIT To provide an alternative exit for looping structures, such as FOR…NEXT and WHILE…WEND statements. FOR … NEXT To repeat the execution of a block of statements for a specified number of times. WHILE … WEND To repeat the execution of a block of statements while a certain condition is TRUE.
  • Page 123: Commands For Event Trapping

    lowercase letters. UCASE$ To return a copy of a string in which all lowercase letters will be converted to uppercase letters. STR$ To convert a numeric expression to a string. To return the numeric value of a string expression in interger form. VALR To convert a string expression to a real number.
  • Page 124: Reader Commands

    GET_TARGET_MACHINE$ To get the model name of the target terminal. MENU To create a menu. After use command “MENU”, it can get what MENU_GET_MENUSELECT option is selected in these command. Set command “MENU” ENT key status when MENU_SET_SELECT_WIT HENT use number key to select menu. Get command “MENU”...
  • Page 125: Buzzer Commands

    READER_SENDCMD_2D To send scanner (2D) command to change scanner status. READER_QUERY$ To query the scanner (CCD/2D) current setting. DECODE To perform barcode decoding. To simulator the “Scan” key press or SIM_SCANKEY_PRESS release. READER_SETFROMFILE To set scanner setting by scanner setting file.
  • Page 126: A12. Lcd Commands

    store it in a variable. INPUT_S To take user input from the keypad, scanning and store it in a variable. INPUT_S_CARRYENT To set ENT auto press on/off when use “INPUT_S_CARRYENT” command. INPUT_S_VIBRATE To set vibrator on or off when use “INPUT_S_VIBRATE”...
  • Page 127: User Font Commands

    area in the activated TextBlock. ICON_ZONE_PRINT To enable or disable the statusbar. PRINT To display data in the activated TextBlock. CLR_RECT To clear a rectangular area in the activated TextBlock. The cursor position is not affected after the operation. To clear the activated TextBlock. SHOW_IMAGE To put a rectangular bitmap in the activated TextBlock.
  • Page 128: File Manipulation Commands

    SWITCHTEXTBLOCK To switch TextBlock. File manipulation commands A15. Command description OPENIN To open (r) a file and get the header of the file for further processing. OPENOUT To open (w+) a file and get the header of the file for further processing. OPENUP To open (r+) a file and get the header of the file for further processing.
  • Page 129: A16. Vibrator Commands

    appointed record. DBMS_UPDATE_DATA To revise the data of appointed field in appointed field record. Vibrator commands A16. Command description VIBRATOR_TIMER To set or get the vibrator timer. VIBRATOR To set the vibrator on/off. Communication port commands A17. Command description CLOSE_COM To terminate communication and disable a specified COM port.
  • Page 130: A18. Memory Commands

    FILE_TRANS_SENDBC_C Clear all data send. FILE_TRANS_READBARC Read data from read temp buffer. ODE$ FILE_TRANS_READBC_ST Return data read temp buffer status. FILE_TRANS_READBC_C Clear all data read. FILE_TRANS_SENDMSG1 Send message to PC. FILE_TRANS_SENDMSG1 Return message send temp buffer status. _STA FILE_TRANS_READMSG1$ Read message from PC send. GET_FILETRANS_ERROR To get the FILE_TRANS error code.
  • Page 131: Linkingport Commands

    LinkingPort commands A20. Command description LINKPORT_OPEN Start a linkingPort. LINKPORT_CLOSE Stop a linkingport. LINKPORT_SELECTIF Set LinkingPort interface select setting. LINKPORT_GETIF Get LinkingPort interface select setting. LINKPORT_SETCOM Set LinkingPort COM baudrate setting. LINKPORT_GETCOM Get LinkingPort COM baudrate setting. LINKPORT_SETBT Set LinkingPort Bluetooth function setting. LINKPORT_GETBT Get LinkingPort Bluetooth function setting.
  • Page 132: Simulator (Only For Pc Simulator) Commands

    Simulator (Only for PC simulator) commands A22. Command description COPYFILETOPDT To copy a file from PC side to PDT. BACKUPDATAFILETOPC To backup a file from PDT to PC. PI1X Basic Programming Manual Ver. 1.10 131/156...
  • Page 133: Scan Module (Ccd) Configuration Table

    Appendix B Scan Module (CCD) Configuration Table Command1 Command2 Value 0: Disable Indication LED indication 1: Enable * 0: Disable Buzzer indication 1: Enable * 0: Disable * Transmission Preamble transmission 1: Enable 0: Disable * Postamble transmission 1: Enable 0: Before code data * Code ID position 1: After code data...
  • Page 134 Suffix characters setting 0x00 ~ 0xff ASCII code 12 characters. Preamble characters 0x00 ~ 0xff ASCII code settings 12 characters. Postamble characters 0x00 ~ 0xff ASCII code settings 12 characters. 0: Disable * Code 11 Read 1: Enable 0:Disable/Disable Check-sum transmit /verify 1:Disable/One digit * 2:Disable/Two digits 3:Enable/One digit...
  • Page 135 0 ~ 15 Truncate ending <*> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Standard * Format 1: Full ASCII 0: Disable * Start/stop transmission 1: Enable 0: Disable * Code 93 Read 1: Enable 0:Disable/Disable Check-sum transmit /verify 1:Disable/Enable * 2:Enable /Enable...
  • Page 136 <#> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Standard * Format 1: UCC.EAN 128 <#> UCC/EAN 128 ID setting 0x00 ~ 0xff ASCII code(1 bytes) 0x1D * Concatenation code 0x00 ~ 0xff ASCII code(1 bytes) 0: Disable * Codabar Read...
  • Page 137 Truncate ending <FF> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: None * Supplement digits 1: 2 digits 2: 5 digits 3: 2, 5 digits 4: UCC/EAN 128 5: 2, UCC/EAN 128 6: 5, UCC/EAN 128 7: All 0: None * Truncation/expansion...
  • Page 138 0:Disable * Industrial 2 of 5 Read 1:Enable 0 ~ 64 Max. code length 0 ~ 64 Min. code length 0 ~ 15 Truncate leading 0 ~ 15 Truncate ending <i> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Disable Interleaved 2 of...
  • Page 139 0 ~ 15 Truncate leading 0 ~ 15 Truncate ending <i> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Disable * MSI Plessey Read 1: Enable 0:N/disable * Check-sum transmit /verify 1:N/MOD 10 2:N/Mod 10,10 3:N/mod 11,10 4:Y/ Mod10 5:Y/ Mod 10,10 6:Y/ Mod 11/10...
  • Page 140 0 ~ 15 Truncate ending <@> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Disable * Telepen Read 1: Enable 0:Disable/Disable * Check-sum transmit /verify 1:Disable/Enable 2:Enable /Enable 0 ~ 64 Max. code length 0 ~ 64 Min.
  • Page 141 4: UCC/EAN 128 5: 2, UCC/EAN 128 6: 5, UCC/EAN 128 7: All 0: None Truncate/expansion 1: Truncate leading zero * 2: Expand to EAN 13 0: Disable UPCE Read 1: Enable * 0: Disable Check-sum transmission 1: Enable * 0 ~ 15 Truncate ending 0 ~ 15...
  • Page 142 2:Enable /Enable 0 ~ 64 Max. code length 0 ~ 64 Min. code length 0 ~ 15 Truncate leading 0 ~ 15 Truncate ending <B> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Disable * China post Read 1: Enable 0 ~ 64...
  • Page 143 0 ~ 15 Truncate leading 0 ~ 15 Truncate ending <RL> Code ID setting 0x00 ~ 0xff ASCII code(1 or 2 bytes) 0: Disable * UCC/EAN 128 emulation 1: Enable 0: Disable * RSS Expanded Read 1: Enable 0 ~ 99 Max.
  • Page 144 0: Disable * Leading “A” 1: Enable CCD CodeType: value Barcode type value Barcode type Code 11 UPCA Code 39 UPCE Code 93 Matrix 25 Code 128 China Post Codabar RSS 14 EAN8 RSS Limited EAN13 RSS Expanded Industrial 2 of 5 Pharama code39 Interleaved 2 of 5 Standard 2 of 5...
  • Page 145: Scan Module (2D) Configuration Table

    Appendix C Scan Module (2D) Configuration Table Command1 Command2 Value 0: Disable Indication LED indication 1: Enable * 0: Disable Buzzer indication 1: Enable * 0: Disable Vibrator 1: Enable * 0: None(*) Transmission Transmit Code ID 1: AIM Code ID 2: Symbol Code ID 5~99(0.1 sec.) Scan...
  • Page 146 0: Disable(*) Transmit Check Digit(s) 1: Enable 0 ~ 55 (default: 4) Length 1※1 0 ~ 55 (default: 55) Length 2※1 0: Disable Code 39 Read 1: Enable(*) 0: Disable(*) Check Digit Verification 1: Enable 0: Disable(*) Transmit Check Digit 1: Enable 0 ~ 55 (default: 2) Length 1※1...
  • Page 147 0: Disable(*) ISBT Concatenation 1: Enable 2: Auto 0: Disable Check ISBT Table 1: Enable(*) 2 ~ 20 (default: 10) ISBT Concatenation Redundancy 0: Disable(*) Codabar Read 1: Enable 0 ~ 55 (default: 5) Length 1※1 0 ~ 55 (default: 55) Length 2※1 0: Disable(*) CLSI Editing...
  • Page 148 0: Disable(*) Transmit Check Digit 1: Enable 0 ~ 55 (default: 4) Length 1※1 0 ~ 55 (default: 55) Length 2※1 0: MOD 10/MOD 11 Check Digit Algorithm 1: MOD 10/MOD 10(*) 0: Disable UPCA Read 1: Enable(*) 0: Disable Transmit Check Digit 1: Enable(*) 0: Disable...
  • Page 149 0 ~ 55 (default: 14) Length 1※1 0 ~ 55 (default: 0) Length 2※1 0: Disable PDF-417 Read 1: Enable(*) 0: Disable(*) MicroPDF Read 1: Enable 0: Disable(*) Code 128 Emulation 1: Enable 0: Disable(*) UPC/EAN Bookland EAN 1: Enable 0: Bookland ISBN-10(*) Bookland ISBN Format 1: Bookland ISBN-13...
  • Page 150 12: Smart Supplemental Plus User-Programmable 1 and 2 ※ Applies to EAN-13 bar codes starting with any prefix listed previously or one of the two user-defined prefixes set using User-Programmable Supplemental. 2 ~ 30 (default: 10) Supplemental Redundancy -1 ~ 999(default:-1) User-Programmable Supplemental 1 -1 ~ 999(default:-1)
  • Page 151 Inverse 1: Inverse 2: Auto 0: Disable Maxicode Read 1: Enable(*) 0: OCR off (*) Read 1: OCR-A 2: OCR-B 3. US Currency 4. MICR E13B 0: OCR-A Full ASCII(*) OCR-A Variant ※2 1: OCR-A Reserved 1 2: OCR-A Reserved 2 3: OCR-A Banking 0: OCR-B Full ASCII(*) OCR-B Variant ※3...
  • Page 152 Inverse OCR 1: Inverse Only 2: Autodiscriminate 0: Disable(*) Discrete 2 of 5 Read 1: Enable 0 ~ 55 (default: 12) Length 1※1 0 ~ 55 (default: 0) Length 2※1 0: Disable(*) Chinese 2 of 5 Read 1: Enable 0: Disable GS1 Data Bar GS1 DataBar-14 1: Enable(*)
  • Page 153 0: UPC Never Linked(*) UPC Composite Mode 1: UPC Always Linked 2: Auto 0: Disable(*) GS1-128 Emulation Mode for 1: Enable UCC/EAN Composite Codes 0: Disable QR Code Read 1: Enable(*) 0: Regular(*) Inverse 1: Inverse 2: Auto 0: Disable Micro QR Read 1: Enable(*)
  • Page 154  OCR-A Banking -0123456789<> outputs as f outputs as c outputs as h ※3: OCR-B Variant OCR-B supports the following variants:  OCR-B Full ASCII !#$%()*+,-./0123456789<>ABCDEFGHIJKLMNOPQRSTUVWXYZ^|Ñ  OCR-B Banking #+-0123456789<>JNP|  OCR-B Limited +,-./0123456789<>ACENPSTVX  OCR-B ISBN 10-Digit Book Numbers -0123456789>BCEINPSXz ...
  • Page 155 2D Barcode Type Table Code Type Code ID Code Name Code 11 Code 39 Code 93 Code 128 Codabar EAN8 EAN13 Interleaved 2 of 5 MSI Plessey UPC-A Matrix 2 of 5 PDF-417 Micro PDF IATA TLC-39 Planet (US) Postnet (US) Postal (Australia) Postbar (CA) Postal (Japan)
  • Page 156 Macro QR QR Code Aztec Rune ISSN UPC-A + 2 UPC-E + 2 EAN-8 + 2 EAN-13 + 2 UPCE1 + 2 CC-A + GS1-128 CC-A + EAN-13 CC-A + EAN-8 CC-A + GS1 DataBar Expanded CC-A + GS1 DataBar Limited CC-A + GS1 DataBar-14 CC-A + UPC-A"...

This manual is also suitable for:

Pi-12x0

Table of Contents