Creating dummy ASCII driver for thermal printer (Star TSP600)

Helge Blischke h.blischke at acm.org
Sun Jan 27 07:06:32 PST 2013


Luis Da Costa wrote:

>> Luis Da Costa wrote:
>>
>> >> Luis Da Costa wrote:
>> >>
>> >> > Hello everyone,
>> >> >
>> >> > I am new here, so if this is not the right place to post this please
>> >> > tell me.
>> >> >
>> >> > I bought a thermal Star TSP600 for my POS installation. Normally
>> >> > this device has a official website (licensed under GPLv2 if I'm not
>> >> > wrong, which is pretty cool and useful), but it only works (under
>> >> > Gnu/Linux and Mac, not on Windows) with the USB and Ethernet
>> >> > version... and as you may already imagine my version is a Serial
>> >> > one.
>> >> >
>> >> > Long story short. After a long time understanding how all of this
>> >> > should work, I've found a way to print. Simply by doing this :
>> >> >
>> >> > echo "Hello World" >> /dev/ttyUSB0
>> >> >
>> >> > It works nice (with no accents as expected) but this isn't a
>> >> > solution for a POS installation since I need the software
>> >> > (proprietary) to work with this printer (by using Cups as you may
>> >> > already understood).
>> >> >
>> >> > Under Fedora 18 I've managed to make it print something under cups
>> >> > using one of those generic drivers : - PostScript
>> >> > - Raw Queue
>> >> > - Others from other printers randomly chosen.
>> >> >
>> >> > After installing them with one of the generic drivers, I've tested
>> >> > with gedit and it would print, sometimes slowly, sometimes faster,
>> >> > but in all the cases I couldn't even understand what was printed
>> >> > (the best I got was one of the drivers that printed in big fonts all
>> >> > the settings used for printing like the font used, the size used
>> >> > etc..).
>> >> >
>> >> > So my question is (as I know programming, and need to have this
>> >> > printer working until the end of this month, and I am trying to not
>> >> > use Windows, since it works in there perfectly), is it possible to
>> >> > create a dummy driver for this kind of situations ? Or is it
>> >> > possible to edit the original ppd from this printer in order to add
>> >> > the serial support ?
>> >> >
>> >> > If yes, could anyone help me do this ? (Or just help me find a
>> >> > better solution that would work under cups in order for the POS
>> >> > software to recognize the printer and use it).
>> >> >
>> >> > Thanks in Advance for all the help. And sorry for my horrible
>> >> > English.
>> >> >
>> >> > Best Regards,
>> >> > Luis Da Costa
>> >>
>> >> Look at
>> >> http://www.starasia.com/productshow.asp?id=82
>> >> for Linux drivers.
>> >>
>> >> Helge
>> >>
>> >
>> >
>> > Hi Helge,
>> >
>> > Thanks for the help. But as I already said, those drivers are only for
>> > the Ethernet and USB version and I've got a Parallel/Serial version
>> > which is not compactible. I've already tried those drivers and they
>> > give me problems with the rasterstar filter, and when they don't, they
>> > simply don't print...
>> >
>> > I have better results with the Raw Queue drivers that with those ones
>> > :S
>> >
>> > Thanks in Advance,
>> > Luis Da Costa
>>
>> The driver(s) are independent of the backend used. For your serial
>> version you need to use the serial backend of CUPS. But it seems your
>> serial connection needs to be capable of transferring 8-bit binary data.
>>
>> Helge
>>
> 
> Hi there again,
> 
> I've tried to install those drivers in a Fedora 14 i686 box with sucess,
> then I added the printer, and selected the same options as the printer
> output in the debug mode :
> 
> - Baud Rate : 9,600bps
> - Data Bits : 8 Bits
> - Parity : None (Odd)
> - Handshake : DTR
> 
> But nothing to do, I only receive "????????????" and some weird
> characters.
> 
> The only difference is that sometimes with some options the text just
> prints upside down.
> 
> What should I do then ? And how can I know if my serial connection is
> capable of transferring 8-bit binary data ? I have it connected to a
> serial-to-usb cable, can this be the problem ?
> 
> Sorry for all this questions, and thank you for all you help.
> 
> Best Regards,
> Luis Da Costa

Am I right in assuming that your Fedora box's USB port is connected to your 
printer's serial port by the usb-to-serial cable? That may indeed be the 
cause of your issues.
To further dig into your problems, please do:
- execute 
  cupsctl --debug-logging
- print a (not too big) test job to your printer
- execute
  cupsctl --no-debug-logging
- post (an URL to) the portion of your /var/log/cups/error_log that contains 
  all the messages related to the test job.

Helge





More information about the cups-devel mailing list