[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Epson ESC codes in dos

Posted on 2004-11-24
4
Medium Priority
?
1,418 Views
Last Modified: 2008-03-03
I guess this should go in the "Printers" section in hardware, but I think it probably needs a more technical mind to answer it, please help.

I'm trying to print barcodes on an epson EPL 6200 using ESC codes from DOS, just it's not working, I can't find any examples anywhere either.

the manual says:

ESC ( B nl nh k m s v1 v2 c barcodeData

I'm using ASCII character 27 for ESC which looks something like "<-" in DOS edit.

number of databytes = bytes in string + 6

nl = mod databytes/256
nh = databytes / 256

k is a hex value for what sort of barcode, code 128 = 06

m is module with, I'm using 05

s is space ajustment, I'm using 1
v1 and v2 = abar length, I'm using 2 for both

c = controll flag, I'm using 1000000 (8 bits)

so I'm sending from DOS edit and counting every ascII char as one byte, so my barcode "01234567801" = 11 bytes + 6 = 17

(<- = asci character 27)

<-(B17006050111000000001234567801

but the printer just goes mental.

bizzarely when I paste it in here it comes out : "\033\017" something to do with ASCII -> ANSI conversion or something???

Any help would be fantastic, atleast an example that works?

Anyone ?
0
Comment
Question by:lorddef
2 Comments
 
LVL 1

Author Comment

by:lorddef
ID: 12674572
bump
0
 
LVL 4

Accepted Solution

by:
Woodster earned 400 total points
ID: 12705137
You will need to send the numbers as characters, not as text.

ie: 17 should be send as ASCII character 17 and NOT the text characters '17'

You will need to do the same with the remaining numbers in the string.



0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Navigation is an important part of web design from a usability perspective. But it is often a pain when it comes to a developer’s perspective. By navigation, it often means menuing. This is less theory and more practical of how to get a specific gro…
How to remove superseded packages in windows w60 or w61 installation media (.wim) or online system to prevent unnecessary space. w60 means Windows Vista or Windows Server 2008. w61 means Windows 7 or Windows Server 2008 R2. There are various …
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
Suggested Courses
Course of the Month18 days, 19 hours left to enroll

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question