Wasp WPL2 Programming Manual

Manual is about: BAR CODE PRINTER SERIES

Summary of WPL2

  • Page 1

    Wpl2 programming manual wasp technologies bar code printer series.

  • Page 2: Revise History

    Revise history date description remark 2003/09/19 1. Basic functions are added to wpl2 2. Supported code page update 2004/5/21 qr code is supported.

  • Page 3: Table Of Contents

    Table of contents document conventions .................................................................. I setup and system commands .................................................................................. 1 size ...............................................................................

  • Page 4

    !J .............................................................................................................................................. 47 file management commands................................................................................ 48 download .....................................

  • Page 5

    Second............................................................................................................................... 105 @year ................................................................................................................................ 106 @month ...................

  • Page 6: Document Conventions

    Wasp technologies. I copyright 2001 all rights reserved. Document conventions this manual uses the following typographic conventions. Convention description [expression list] items inside square brackets are optional, expression maximum length 2*1024 bytes; escape (ascii 27), control code of status ...

  • Page 7: Setup And System Commands

    Wasp technologies. 1 copyright 2001 all rights reserved. Setup and system commands size description this command defines the label width and length. Syntax (1) english system (inch) size m, n (2) metric system (mm) size m mm, n mm parameter description m label width (inch or mm) n label length (inch...

  • Page 8

    Wasp technologies. 2 copyright 2001 all rights reserved. Gap, bline.

  • Page 9: Gap

    Wasp technologies. 3 copyright 2001 all rights reserved. Gap description define the gap distance between two labels syntax (1) english system (inch) gap m, n (2) metric system (mm) gap m mm, n mm parameter description m the gap distance between two labels 0 ≤ m ≤ 1 (inch), 0 ≤ m ≤ 25.4 (mm) n the of...

  • Page 10

    Wasp technologies. 4 copyright 2001 all rights reserved. Special gap (1) english system (inch) gap 0.30, 0.10 (2) metric system (mm) gap 7.62 mm, 2.54 mm see also size, bline.

  • Page 11: Bline

    Wasp technologies. 5 copyright 2001 all rights reserved. Bline description this command is used to set the height of the black line and the user-defined extra label feeding length each form feed takes. Syntax (1) english system (inch) bline m, n (2) metric system (mm) bline m mm, n mm parameter desc...

  • Page 12: Offset

    Wasp technologies. 6 copyright 2001 all rights reserved. Offset description this command defines the selective, extra label feeding length each form feed takes, which, especially in peel-off mode and cutter mode, is used to adjust label stop position, so as for label to register at proper places for...

  • Page 13: Speed

    Wasp technologies. 7 copyright 2001 all rights reserved. Speed description this command defines the print speed. Syntax speed n parameter description n printing speed in inch per second n 1 1.5 2 3 4 5 6 8 10 12 wpl606 x x x x x wpl305 x x x x example speed 10 see also density.

  • Page 14: Density

    Wasp technologies. 8 copyright 2001 all rights reserved. Density description this command designates the level of darkness of printing. Syntax density n parameter description n 0, specifies the lightest level 15, specifies the darkest level example density 7 see also density.

  • Page 15: Direction

    Wasp technologies. 9 copyright 2001 all rights reserved. Direction description this command defines the printout direction. Syntax direction n parameter description n 0 or 1. Please refer to the illustrations below: example direction 0 see also reference.

  • Page 16: Reference

    Wasp technologies. 10 copyright 2001 all rights reserved. Reference description this command defines the reference point of the label. The reference (origin) point varies with the print direction, as shown: syntax reference x, y parameter description x horizontal coordinate, with “dot” as the unit. ...

  • Page 17: Country

    Wasp technologies. 11 copyright 2001 all rights reserved. Country description this command defines what special character to have on the wpk-200 portable lcd keyboard (option) to orient the keyboard for use in different countries. Syntax country n parameter description n 001: usa 002: canadian-frenc...

  • Page 18: Codepage

    Wasp technologies. 12 copyright 2001 all rights reserved. Codepage description this command defines the code page of international character set. Syntax codepage n parameter description n name or number of code page, which can be divided into 7-bit code page and 8-bit code page further. 7-bit code p...

  • Page 19: Feed

    Wasp technologies. 13 copyright 2001 all rights reserved. Feed description this command feeds label with the specified length. The length is specified by dot. Syntax feed n parameter description n unit: dot 1 ≤ n ≤ 9999 example feed 40 note: 200 dpi: 1 mm = 8 dots 300 dpi: 1 mm = 12 dots see also ba...

  • Page 20: Backfeed

    Wasp technologies. 14 copyright 2001 all rights reserved. Backfeed description to back feed label with the specified length the length is specified by dot. Syntax backfeed n parameter description n unit: dot 1 ≤ n ≤ 9999 example backfeed 40 caution: impropriety back feed value may cause paper jam or...

  • Page 21: Formfeed

    Wasp technologies. 15 copyright 2001 all rights reserved. Formfeed description this command feeds label to the beginning of next label. Syntax formfeed parameter description none n/a example formfeed see also feed, size, gap, bline.

  • Page 22: Home

    Wasp technologies. 16 copyright 2001 all rights reserved. Home description it is not expected the first label will be printed on the right position when the printer power is turned on. This command will feed label to the beginning of next label. The size of the label should be setup in advance. Synt...

  • Page 23: Print

    Wasp technologies. 17 copyright 2001 all rights reserved. Print description this command prints the label format stored in the image buffer. Syntax print m [,n] parameter description m specifies how many sets of labels will be printed. 1 ≤ m ≤ 999999999 if m=-1, printer will print the last label con...

  • Page 24: Cut

    Wasp technologies. 18 copyright 2001 all rights reserved. Cut description at this command, the printer will activate the cutter to cut the labels immediately without back feeding the label. Syntax cut parameter description none n/a see also set cutter.

  • Page 25: Label Formatting Commands

    Wasp technologies. 19 copyright 2001 all rights reserved. Label formatting commands cls description this command clears the image buffer. Syntax cls parameter description none n/a note: this command must be placed after size command. Example cls see also size, gap, bline.

  • Page 26: Bar

    Wasp technologies. 20 copyright 2001 all rights reserved. Bar description this command is used to draw a line or a bar on the label format. Syntax bar x, y, width, height parameter description x the upper left corner x-coordinate in dot y the upper left corner y-coordinate in dot width the width of ...

  • Page 27: Erase

    Wasp technologies. 21 copyright 2001 all rights reserved. Erase description this command is used to clear a specified region in image buffer. Syntax erase x_start, y_start, x_width, y_height parameter description x_start the x-coordinate of the starting point in dot y_start the y-coordinate of the s...

  • Page 28: Reverse

    Wasp technologies. 22 copyright 2001 all rights reserved. Reverse description this command is used to reverse a region in image buffer. Syntax reverse x_start, y_start, x_width, y_height parameter description x_start the x-coordinate of the starting point in dot y_start the y-coordinate of the start...

  • Page 29: Box

    Wasp technologies. 23 copyright 2001 all rights reserved. Box description this command is used to draw rectangles on the label. Syntax box x_start, y_start, x_end, y_end, line thickness parameter description x_start specify x-coordinate of upper left corner in dot y_start specify y-coordinate of upp...

  • Page 30: Bitmap

    Wasp technologies. 24 copyright 2001 all rights reserved. Bitmap description this command is used to draw bitmap images (not bmp graphic file). Syntax bitmap x, y, width, height, mode, bitmap data… parameter description x specify the x-coordinate of the bitmap image y specify the y-coordinate of the...

  • Page 31: Putbmp

    Wasp technologies. 25 copyright 2001 all rights reserved. Putbmp description this command is used to print bmp format image. Syntax putbmp x, y, ”filename” parameter description x the x-coordinate of the bmp format image y the y-coordinate of the bmp format image filename the downloaded bmp filename...

  • Page 32: Putpcx

    Wasp technologies. 26 copyright 2001 all rights reserved. Putpcx description this command is used to print pcx format image. Syntax putpcx x, y, ”filename” parameter description x the x-coordinate of the pcx image y the y-coordinate of the pcx image filename the downloaded pcx filename. Case sensiti...

  • Page 33: Barcode

    Wasp technologies. 27 copyright 2001 all rights reserved. Barcode description this command is used to print 1d barcodes on label form. The available bar codes are listed below: code 128 (switching code subset automatically) code 128m (switching code subset manually) ean 128 (switching code subset au...

  • Page 34

    Wasp technologies. 28 copyright 2001 all rights reserved. Syntax barcode x, y, ”code type”, height, human readable, rotation, narrow, wide, “code” parameter description x specify the x-coordinate of the bar code on label y specify the y-coordinate of the bar code on label code type 128 code 128, swi...

  • Page 35

    Wasp technologies. 29 copyright 2001 all rights reserved. Upca+5 upc-a with 5 digits add-on upce upc-e upce+2 upc-e with 2 digits add-on upce+5 upc-e with 5 digits add-on cpost china post code msi msi code plessey plessey code itf14 itf 14 code ean14 ean 14 code height bar code height expressed by d...

  • Page 36

    Wasp technologies. 30 copyright 2001 all rights reserved. Plessy - - - - itf14 - 10x 10x 5x ean14 - - - - code number the maximum number of digits of bar code content barcode type maximum bar code length 128 - ean128 - 25 - 25c - 39 - 39c - 93 - ean13 12 ean13+2 14 ean13+5 17 ean 8 7 ean 8+2 9 ean 8...

  • Page 37: Dmatrix

    Wasp technologies. 31 copyright 2001 all rights reserved. Dmatrix description this command is used to define the datamatrix 2d bar code. Currently, it supports ecc200 error correction only. Syntax dmatrix x, y, width, height, [xm, lm], expression parameter description x horizontal start position in ...

  • Page 38: Maxicode

    Wasp technologies. 32 copyright 2001 all rights reserved. Maxicode description this command is used to define a 2d maxicode. Syntax maxicode x, y, mode, [class, country, post, lm,] “message” for mode 2 or 3: maxicode x, y, mode, class, country, postal code, ”low priority message" if country is 840, ...

  • Page 39

    Wasp technologies. 33 copyright 2001 all rights reserved. Cls size 4.00,3.00 gap 0.10,0 density 10 maxicode 24,24,4,"this is a 93 character code set a message that fills a mode 4, unappended, maxicode symbol..." box 424,16,700,60,2 direction 0 print 1 rem mode 5 speed 6 cls size 4.00,3.00 gap 0.10,0...

  • Page 40: Pdf417

    Wasp technologies. 34 copyright 2001 all rights reserved. Pdf417 description this command is used to define a pdf417 2d barcode. Syntax pdf417 x, y, width, height, rotate, [option], expression parameter description x x-coordinate of the starting point in dot y y-coordinate of the starting point in d...

  • Page 41: Qrcode

    Wasp technologies. 35 copyright 2001 all rights reserved. Qrcode description this command is used to print qr code syntax qrcode x, y, ecc level, cell width, mode, rotation, [model, mask,]"data string” parameter description x the upper left corner x-coordinate of the qr code y the upper left corner ...

  • Page 42

    Wasp technologies. 36 copyright 2001 all rights reserved. 3). 8-bit byte data: 486 characters 2,953 characters 4). Kanji data: 299 characters 1,817 characters *if “a” is the first character in the data string, then the following data after “a” are alphanumeric data. *if “n” is the first character in...

  • Page 43

    Wasp technologies. 37 copyright 2001 all rights reserved. Gap 0.12,0 cls qrcode 10,10,h,4,a,0,"abc abc 123" qrcode 160,160,h,4,a,0,"123 abc abc" qrcode 310,310,h,4,a,0," 印表機 abc abc 123" print 1,1 c. Data string concatenation (must be used with download ... Eop command) download “demo.Bas” size 4,2....

  • Page 44

    Wasp technologies. 38 copyright 2001 all rights reserved. Qrcode 10,10,h,4,m,0,"aabc!B0007 abc !N123" qrcode 160,160,h,4,m,0,"n123!B0002 !Aabc!B0005 abc" qrcode 310,310,h,4,m,0,"k 印表機!B0002 !Aabc!B0010 abc 123" print 1,1 c. Data string concatenation (must be used with download ... Eop command) size ...

  • Page 45: Text

    Wasp technologies. 39 copyright 2001 all rights reserved. Text description this command is used to print text on label syntax text x, y, ”font”, rotation, x-multiplication, y-multiplication, “content” parameter description x the x-coordinate of the text y the y-coordinate of the text font font name ...

  • Page 46

    Wasp technologies. 40 copyright 2001 all rights reserved. Status polling commands (rs-232) !? Description this command is used to obtain the printer status. An inquiry request is solicited by sending an (ascii 27, escape character) as the beginning control character to the printer. It can be sent an...

  • Page 47

    Wasp technologies. 41 copyright 2001 all rights reserved. !R description this command is used to reset the printer. It can be sent at any time as long as the printer is powered on and not in the dump mode. The beginning of the command is an escape character (ascii 27). The files downloaded in memory...

  • Page 48: ~!i

    Wasp technologies. 42 copyright 2001 all rights reserved. ~!I description the command is used to inquire the code page and country setting of the printer. The returned information is given in the following format code page, country code ex: 8 bit: 437, 001 7 bit: usa, 001 regarding the code pages an...

  • Page 49: ~!f

    Wasp technologies. 43 copyright 2001 all rights reserved. ~!F description this command is used to inquire about files resident in the printer memory and fonts installed in the memory module. The filename is returned in ascii characters. Each file name ends with 0x0d 0x0a. The ending character is 0x1...

  • Page 50

    Wasp technologies. 44 copyright 2001 all rights reserved. Message translation protocols ~# description the beginning identifier (~#) of the prompt message is sent from the printer to the kp-200 portable keyboard. The ending identifier is ~&. @0 following the ending identifier ~& is used to instruct ...

  • Page 51: Beep

    Wasp technologies. 45 copyright 2001 all rights reserved. Beep description this command is used to issue a beep sound on portable keyboard. Printer sends 0x07 to kp-200 portable keyboard. Syntax beep parameter description none n/a example download “demo.Bas” size 4,4 gap 0,0 density 8 speed 6 direct...

  • Page 52

    Wasp technologies. 46 copyright 2001 all rights reserved. Commands for windows driver !B description this command is used to store bitmap image data in the memory. Behind the nnn is the bitmap data. Syntax !Bnnn parameter description nnn the number of bytes of image data sent from pc to printer,expr...

  • Page 53

    Wasp technologies. 47 copyright 2001 all rights reserved. !J description this command is used to print the bitmap data at the specified position (in y-direction). Syntax !Jnnnn parameter description nnnn print image at the specified position in y-direction. The position is expressed in 4 decimal dig...

  • Page 54: File Management Commands

    Wasp technologies. 48 copyright 2001 all rights reserved. File management commands download description “download” is a header of the file that is to be saved in the printer's memory. The downloaded files can be divided to two categories: program file and data file (including text data file, pcx gra...

  • Page 55

    Wasp technologies. 49 copyright 2001 all rights reserved. Filename: the name of data file that will remain resident in the printer memory. It is case sensitive. Data size: the actual size (numbers of byte) of the data file without header. Note: (1). For text data file, cr (carriage return) 0x0d and ...

  • Page 56

    Wasp technologies. 50 copyright 2001 all rights reserved. Below is an example of downloading data file. Download “data”,20,computer 2001 21 note: stands for keyboard “enter” key. In the above example, please press “enter” key instead of typing in the above example. See also eop, run, putbmp, putpcx,...

  • Page 57: Eop

    Wasp technologies. 51 copyright 2001 all rights reserved. Eop description end of program. To declare the start and end of basic language commands used in a program, the “download “filename.Bas” must be added in the first line of the program, and “eop” statement at the last line of program. Syntax eo...

  • Page 58: Files

    Wasp technologies. 52 copyright 2001 all rights reserved. Files description this command lists the files that remained in the printer memory (both flash memory and dram). The total memory size and available memory size are listed as well. Syntax files example follow the steps below to list the files...

  • Page 59: Kill

    Wasp technologies. 53 copyright 2001 all rights reserved. Kill description this command deletes a file in the printer memory. The wild card (*) will delete all files resident in specified dram or flash memory. Syntax kill [n],”filename” parameter description n specify the memory location that files ...

  • Page 60

    Wasp technologies. 54 copyright 2001 all rights reserved. See also ~!F, files.

  • Page 61: Run

    Wasp technologies. 55 copyright 2001 all rights reserved. Run description this command is used to execute a program that resident in printer memory syntax run “filename.Bas” example c:¥>copy con lpt1 run “demo.Bas” c:¥> note: stands for keyboard “enter” key. In the above example, please press “enter...

  • Page 62: Abs( )

    Wasp technologies. 56 copyright 2001 all rights reserved. Basic commands and functions abs( ) description this function returns the absolute value of an integer, floating point or variable. Syntax abs (-100) abs (-99.99) abs (variable) example download “test.Bas” size 4,4 gap 0,0 density 8 speed 3 d...

  • Page 63: Asc( )

    Wasp technologies. 57 copyright 2001 all rights reserved. Asc( ) description this function returns the ascii code of the character. Syntax asc (“a”) example download “test.Bas” size 4,4 gap 0,0 density 8 speed 3 direction 0 reference 0,0 set cutter off set peel off cls code1=asc(“a”) text 100,100,”3...

  • Page 64: Chr$( )

    Wasp technologies. 58 copyright 2001 all rights reserved. Chr$( ) description this function returns the character that has the specified ascii code. Syntax chr$(n) parameter description n the ascii code example download “test.Bas” size 4,4 gap 0,0 density 8 speed 3 direction 0 reference 0,0 set cutt...

  • Page 65: End

    Wasp technologies. 59 copyright 2001 all rights reserved. End description this command states the ending of program. Syntax end example download “demo.Bas” size 4,4 gap 0,0 density 8 speed 3 direction 0 reference 0,0 set cutter off set peel off cls text 10,600,"5",0,1,1,"gosub & return command test"...

  • Page 66: Eof( )

    Wasp technologies. 60 copyright 2001 all rights reserved. Eof( ) description this function is used to detect an opened download file to see whether it has reached the end of file. Syntax eof (file handle) parameter description file handle either 0 or 1. Return value description none-zero end of file...

  • Page 67

    Wasp technologies. 61 copyright 2001 all rights reserved. See also download, eop, open, read, seek.

  • Page 68: Open

    Wasp technologies. 62 copyright 2001 all rights reserved. Open description this command is used to open a downloaded file and establish the file handle. Up to 2 files can be opened at the same time. The file to be opened should be downloaded prior to using this command. Syntax open “filename”, file ...

  • Page 69

    Wasp technologies. 63 copyright 2001 all rights reserved. If i>0 then end box 98,48,502,514,2 a$=”items:”+item$ b$=”price:”+str$(price) c$=”qty:”+str$(qty) text 128,114,”2”,0,1,1,a$ text 130,198,”2”,0,1,1,b$ text 132,268,”2”,0,1,1,c$ barcode 132,365,”39”,96,1,0,2,4,”price-2000” print 1 close 1 eop s...

  • Page 70: Read

    Wasp technologies. 64 copyright 2001 all rights reserved. Read description this command is used to read data from downloaded data file syntax read file handle, variables parameter description file handle 0 or 1 variables string, integer or float point variable example download “open1.Bas” size 4,4 g...

  • Page 71

    Wasp technologies. 65 copyright 2001 all rights reserved. A$="items:"+item$ b$="price:"+str$(price) c$="qty:"+str$(qty) text 128,114,"2",0,1,1,a$ text 130,198,"2",0,1,1,b$ text 132,268,"2",0,1,1,c$ barcode 132,365,"39",96,1,0,2,4,"price-2000" print 1 i=eof(1) if i=0 then goto b open "data2",0 cls z$...

  • Page 72: Seek

    Wasp technologies. 66 copyright 2001 all rights reserved. Seek description this command is used to shift the specified file pointer to a certain position. Syntax seek file handle, offset parameter description file handle 0 or 1 offset the offset characters which are shifted to the beginning of a new...

  • Page 73: Lof( )

    Wasp technologies. 67 copyright 2001 all rights reserved. Lof( ) description this function returns the size of the specified file. Syntax lof (“filename”) parameter description filename the file downloaded in the printer memory. Example download “open2.Bas” size 4,4 gap 0,0 density 8 speed 3 directi...

  • Page 74: Fread$( )

    Wasp technologies. 68 copyright 2001 all rights reserved. Fread$( ) description this function reads a specified number of bytes of data from a file. Syntax fread$ (file handle, byte) parameter description file handle either 0 or 1 byte number of bytes to be read example download “fread.Bas” size 4,4...

  • Page 75: For…next Loop

    Wasp technologies. 69 copyright 2001 all rights reserved. For…next loop description loop is used to execute one or more lines of program repetitively. Before anything, a value should be assigned the loop counter to specify the execution times. Nested loop is allowed (up to 10 nested loops) in this p...

  • Page 76

    Wasp technologies. 70 copyright 2001 all rights reserved. Text 10,100,"3",0,1,1,c$ next for i=1 to 5 step 0.5 h$=h$+str$(i)+" " text 10,150,"3",0,1,1,h$ next print 1 eop see also download, eop.

  • Page 77: If…then…else

    Wasp technologies. 71 copyright 2001 all rights reserved. If…then…else description use if…then block to execute one or more statements conditionally. You can use either a single-line syntax or multiple-line “block” syntax: syntax if condition then statement notice that the single-line form of if …th...

  • Page 78

    Wasp technologies. 72 copyright 2001 all rights reserved. Density 8 speed 3 direction 0 reference 0,0 set cutter off set peel off cls a=50 b=5 c$="" d$="" :l1 if a>100 then goto l1 else a=a+10 c$=str$(a)+" is smaller than 100" text 100,10,"4",0,1,1,c$ print 1 end :l2 a=a+b d$=str$(a)+" is larger tha...

  • Page 79: Gosub…return

    Wasp technologies. 73 copyright 2001 all rights reserved. Gosub…return description branch to and return from a subroutine. Branch to the specified label and execute subroutines until “return” is reached and then go back to the statement following the gosub statement. Syntax gosub label statement end...

  • Page 80

    Wasp technologies. 74 copyright 2001 all rights reserved. Set peel off density 13 for i=21 to 50 text 10,i,100,”3”,0,1,1,”==============================” next return eop see also download, eop, end, goto.

  • Page 81: Goto

    Wasp technologies. 75 copyright 2001 all rights reserved. Goto description this command is used to branch to a specified label. The label cannot exceed 8 characters in length. Syntax goto label :label parameter description none n/a example download “gosub1.Bas” size 4,4 gap 0,0 density 8 speed 3 dir...

  • Page 82: Inp$( )

    Wasp technologies. 76 copyright 2001 all rights reserved. Inp$( ) description one byte is received from a serial port through this function. Syntax inp$(n) parameter description n 1: com1 port in printer example download “demo.Bas” size 4,4 gap 0,0 density 8 speed 3 direction 0 reference 0,0 set cut...

  • Page 83: Input

    Wasp technologies. 77 copyright 2001 all rights reserved. Input description this command is used to receive data through serial port. This command is used with portable keyboard kp-200. Syntax input [“prompt string”], variables parameter description prompt string the prompt string is shown on keyboa...

  • Page 84: Rem

    Wasp technologies. 78 copyright 2001 all rights reserved. Rem description comment. Prefix is “rem” that will be ignored by the printer. Syntax rem example rem ******************************** rem this is a demonstration program* rem ******************************** download “remark.Bas” size 4,4 gap...

  • Page 85: Out

    Wasp technologies. 79 copyright 2001 all rights reserved. Out description this command is used to send data through printer serial port. Syntax out “prompt”, variable parameter description prompt prompt which is shown on lcd screen. Variable the output message example download “demo.Bas” size 4,4 ga...

  • Page 86: Getkey( )

    Wasp technologies. 80 copyright 2001 all rights reserved. Getkey( ) description this command is used to get the status of pause key and feed key. This command waits until either key is pressed. 0 is returned if pause key is pressed and 1 is returned if feed key is pressed. Syntax getkey() example do...

  • Page 87: Int( )

    Wasp technologies. 81 copyright 2001 all rights reserved. Int( ) description this function is used to truncate a floating point number. Syntax int (n) parameter description n n can be positive or negative integer, floating point number or mathematical expression. Example download “demo5.Bas” size 4,...

  • Page 88: Left$( )

    Wasp technologies. 82 copyright 2001 all rights reserved. Left$( ) description this function returns the specified number of characters down from the initial character of a string. Syntax left$ (x$, n) parameter description x$ the string to be processed n the number of characters to be returned exam...

  • Page 89: Len( )

    Wasp technologies. 83 copyright 2001 all rights reserved. Len( ) description this function returns the length of a string. Syntax len (string) parameter description string the string whose length is to be measured. . Example download "demo6.Bas" size 4.00,4.00 gap 0.12,0.00 speed 2.0 density 8 set c...

  • Page 90: Mid$( )

    Wasp technologies. 84 copyright 2001 all rights reserved. Mid$( ) description this function is used to get the specified number of characters down from the mth character of a string. Syntax mid$(string, m, n) parameter description string the string to be processed. M the beginning of mth characters ...

  • Page 91: Right$( )

    Wasp technologies. 85 copyright 2001 all rights reserved. Right$( ) description this function returns the specified number of characters up from the end of a string. Syntax right$ (x$, n) parameter description x$ the string to be processed n the number of characters to be returned from the right sid...

  • Page 92: Str$( )

    Wasp technologies. 86 copyright 2001 all rights reserved. Str$( ) description this function converts a specified value or expression into corresponding string of characters. Syntax str$ (n) parameter description n an integer, floating point number or mathematical expression example download "demo9.B...

  • Page 93: Val( )

    Wasp technologies. 87 copyright 2001 all rights reserved. Val( ) description this function is used to convert numeric character into corresponding integer or floating point number. Syntax val (“numeric character”) parameter description numeric character “0~9”, “.” example download "demo10.Bas" size ...

  • Page 94: Set Counter

    Wasp technologies. 88 copyright 2001 all rights reserved. Device reconfiguration commands set counter description counter can be a real counter or a variable. This setting sets the counter number in program and their increments. There are three different kind of counters: digit (0~9~0), lower case l...

  • Page 95: Set Cutter

    Wasp technologies. 89 copyright 2001 all rights reserved. Set cutter description this setting is used to activate/deactivate the cutter and define how many printed labels to be cut at one time. This setting will be saved in printer memory when turning off the power. Syntax set cutter off/batch/piece...

  • Page 96

    Wasp technologies. 90 copyright 2001 all rights reserved. Rem set cutter piece example program rem this program cuts each printed label size 4,4 gap 0,0 density 8 speed 6 direction 0 reference 0,0 set cutter 1 set peel off cls text 50,50,”3”,0,1,1,”set cutter piece” barcode 50,500,”39”,48,1,0,2,4,”d...

  • Page 97: Set Peel

    Wasp technologies. 91 copyright 2001 all rights reserved. Set peel description this setting is used to enable/disable the self-peeling function. The default setting for this function is off. When this function is set on, the printer stops after each label printing, and does not print the next label ...

  • Page 98: Set Tear

    Wasp technologies. 92 copyright 2001 all rights reserved. Set tear description this command is used to enable/disable feeding label to gap/black mark position for tearing off. This setting will be saved in printer memory when turning off the power. Syntax set tear on/off parameter description on the...

  • Page 99: Set Gap

    Wasp technologies. 93 copyright 2001 all rights reserved. Set gap description this setting is used to set the gap sensor emission sensitivity. The printer initiates automatic gap sensor calibration as you hold down the pause key and then turn on the printer power. But this function may cease to work...

  • Page 100

    Wasp technologies. 94 copyright 2001 all rights reserved. See also size, gap, bline.

  • Page 101: Set Ribbon

    Wasp technologies. 95 copyright 2001 all rights reserved. Set ribbon description this setting is used to enable/disable ribbon sensor detection. (thermal transfer printing/thermal direct printing) printer will detect if there is ribbon or without ribbon installed in ribbon mechanism at the instance ...

  • Page 102: Set Com1

    Wasp technologies. 96 copyright 2001 all rights reserved. Set com1 description this setting defines communication parameters for printer serial port. Syntax set com1 baud, parity, data, stop parameter description baud baud rate, available baud rates are as listed : 24: 2400 bps 48: 4800 bps 96: 9600...

  • Page 103: Set Printkey

    Wasp technologies. 97 copyright 2001 all rights reserved. Set printkey description this command will print one label and feed label gap to tear bar position for tearing away. Press feed button to print the next label or batch of labels. If label content includes serial text or barcode, it will chang...

  • Page 104: @label

    Wasp technologies. 98 copyright 2001 all rights reserved. @label description this variable (read only) is used to count how many pieces of labels have been printed. It can’t be initialized if the printer is reset. It will be memorized if the printer power is turned off. Syntax @label 0 example size ...

  • Page 105: Year

    Wasp technologies. 99 copyright 2001 all rights reserved. Year description this variable is used to read from/write to rtc the year data. Four-digit year format is supported by rtc. Syntax write attribute: year=02 read attribute: a=year range: 00~99 example download "demo21.Bas" size 4,4 gap 0,0 den...

  • Page 106: Month

    Wasp technologies. 100 copyright 2001 all rights reserved. Month description this variable is used to read from/write to rtc the month data. Two-digits (01~12) month format is supported by rtc. Syntax write attribute: month=01 read attribute: a=month range: 01~12 example download "demo21.Bas" size 4...

  • Page 107: Date

    Wasp technologies. 101 copyright 2001 all rights reserved. Date description this variable is used to read from/write to rtc the date data. Two-digits (01~31) date format is supported by rtc. Syntax write attribute: date=12 read attribute: a=date range: 01~31 example download "demo21.Bas" size 4,4 ga...

  • Page 108: Week

    Wasp technologies. 102 copyright 2001 all rights reserved. Week description this variable is used to read from/write to rtc the week data, which is represented by one single digit (1~7).. . Syntax write attribute: week=3 read attribute: a=week range: 1(sunday)~7(saturday) example download "demo21.Ba...

  • Page 109: Hour

    Wasp technologies. 103 copyright 2001 all rights reserved. Hour description this variable is used to read from/write to rtc the hour data. The 24-hour-day system (00~23) is supported by rtc. Syntax write attribute: hour=12 read attribute: a=hour range: 00~23 example download "demo21.Bas" size 4,4 ga...

  • Page 110: Minute

    Wasp technologies. 104 copyright 2001 all rights reserved. Minute description this variable is used to read from/write to rtc the minute data. Two-digits (00~59) minute format is supported by rtc. Syntax write attribute: minute=12 read attribute: a=minute range: 00~59 example download "demo21.Bas" s...

  • Page 111: Second

    Wasp technologies. 105 copyright 2001 all rights reserved. Second description this variable is used to read from/write to rtc the second data. Two-digits (00~59) second format is supported by rtc. Syntax write attribute: second=12 read attribute: a=second range: 00~59 example download "demo21.Bas" s...

  • Page 112: @year

    Wasp technologies. 106 copyright 2001 all rights reserved. @year description this variable is used to read from/write to rtc the year data. Four-digit year format is supported by rtc. @year global variable can be accessed directly without using basic language functions. Syntax write attribute: year=...

  • Page 113: @month

    Wasp technologies. 107 copyright 2001 all rights reserved. @month description this variable is used to read from/write to rtc the month data. Two-digits (01~12) month format is supported by rtc. @month global variable can be accessed directly without using basic language functions. Syntax write attr...

  • Page 114: @date

    Wasp technologies. 108 copyright 2001 all rights reserved. @date description this variable is used to read from/write to rtc the date data. Two-digits (01~31) date format is supported by rtc. @date global variable can be accessed directly without using basic language functions. Syntax write attribut...

  • Page 115: @day

    Wasp technologies. 109 copyright 2001 all rights reserved. @day description this variable is used to read from/write to rtc the week data, which is represented by one single digit (1~7).. . @day global variable can be accessed directly without using basic language functions. Syntax write attribute: ...

  • Page 116: @hour

    Wasp technologies. 110 copyright 2001 all rights reserved. @hour description this variable is used to read from/write to rtc the hour data. The 24-hour-day system (00~23) is supported by rtc. @hour global variable can be accessed directly without using basic language functions. Syntax write attribut...

  • Page 117: @minute

    Wasp technologies. 111 copyright 2001 all rights reserved. @minute description this variable is used to read from/write to rtc the minute data. Two-digits (00~59) minute format is supported by rtc. @minute global variable can be accessed directly without using basic language functions. Syntax write ...

  • Page 118: @second

    Wasp technologies. 112 copyright 2001 all rights reserved. @second description this variable is used to read from/write to rtc the second data. Two-digits (00~59) second format is supported by rtc. @second global variable can be accessed directly without using basic language functions. Syntax write ...

  • Page 119

    Wasp technologies. 113 copyright 2001 all rights reserved..

  • Page 120

    Last update: may. 21, 2004.