473,732 Members | 2,175 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to send ASCII values to the RFID printer?

20 New Member
Hi,

I have connected RFID printer(Zebra R2844-Z) to the serial port(/dev/ttyS0).My OS is linux(ubuntu).

The following is a program which is written in ZPL:

^XA
^RI0,,5^FS
^FO20,120^A0N,6 0^FN0^FS
^HV0,,Tag ID:^FS
^XZ

This program will read the RFID tag's ID and return the result back to the terminal. I saved this program as RL.zpl. I sent this program to the printer using minicom. It works fine. It reads and returns the tag id.

But what I have to do is, I have to send this RL.zpl to the printer(which is connected to the serial port) using a c++ program. I do't know how to do this. please help me!. please give me some ideas. If possible, please send me an example program.

Thanks in advance!
Feb 9 '07 #1
1 2632
horace1
1,510 Recognized Expert Top Contributor
have a look at
http://www.geocities.c om/horacespider/Serial_IO/Linux/terminal.c

which contains functions to read and write the serial port under Linux
Feb 9 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
2372
by: free free | last post by:
Hi, i'am writing a python program and now i need to print some stuff. Before print i want to set the text to condensed text and to italic, so i have to send some esc commads to printer. my code pp=open("/dev/lpr","w") pp.write(chr(27)+chr(15))
13
21688
by: Susan Beebe | last post by:
I have downloaded the code described in Microsoft article Q154078. I am trying to send raw ZPL (zebra barcode printer) code from Microsoft access. It works just fine if I hard code the actual data in the string being sent to the printer. However, if I prompt the user for data or if I insert data from a particular record/field in a form Access crashes/closes on its own. I have included the code below, if anyone has any suggestions,...
1
3339
by: Paul Aspinall | last post by:
Hi I'm writing a web based system, which needs to direct prints to a Zebra barcode printer. I plan to use the ZPL (Zebra's own) programming language for sending Raw ASCII to the printer, and therefore enabling the printing. Does anyone have any sample code on sending Raw ASCII to a printer share location, ie. \\computer1\printer1, \\computer1\printer2
1
2262
by: broadbandera | last post by:
RFID Technology and Architecture, RFID Standards,RFID Applications, RFID Security, Impact of RFID Tags on Recycling, Environmental Challenges of RFID, RFID Tags: Advantages and Limitations, http://flying-rugs.com/rfid-tutorial/
1
3131
by: Peter Hansen | last post by:
Im on a RFID application, in have a lot of problems, which I hope you kan help me with. Sourcefiles: http://www.ti.com/rfid/docs/manuals/softwares/DLL.zip Documentation http://www.ti.com/rfid/docs/manuals/refmanuals/S6000ProgramLibraryFECOM.pdf og http://www.ti.com/rfid/docs/manuals/refmanuals/S6000ProgramLibraryFEISC.pdf
1
4514
by: rsaikamesh | last post by:
Hi, I have connected RFID printer(Zebra R2844-Z) to serial port(dev/ttyS0). My OS is linux(ubuntu). I am using minicom for communication. I need to print some data using the RFID printer. the following is the program which is written in ZPL language: ^XA ^LH30,30 ^F020,10^AD^FDZEBRA^FS ^F020,60^B3^FDSMITHA NARENDRA^FS ^XZ
1
2887
by: paridaG | last post by:
Hi can any one help me? I am using RFID zebra printer and my os is linux. I try to print on it. I have no driver for linux and I can not communicate through minicom. I want to communicate with my printer through c program. Thanks in advance.
1
6006
by: remya1000 | last post by:
how to send a .txt file to a printer. after creating a .txt file i need to send that .txt file to a printer.using vb.net and while sending that file to printer i need to tell, which printer i need to send. and i can't used printdialog, to select to which printer i need to send and number of pages and all. everything i need to hardcode. after creating a .txt file, hardcode to which printer i need to send the data and just send to printer. ...
6
6381
by: Jerry Spence1 | last post by:
I am tring to send out of a TCP port, the hext digits: FF010040000042 I can't quite get the syntax in my head: Command="FFH010040000042" Dim sendBytes As () = System.Text.Encoding.ASCII.GetBytes(Command) networkStream.Write(sendBytes, 0, sendBytes.Length)
0
8773
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9445
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9306
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9234
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9180
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4548
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4805
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2177
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.