My last post has generated a lot of response. First, thank you all for 
responding. Second, I think some of you wanted me to clarify the problem and 
maybe better explain exactly what I'm trying to do:

We have a small family business here and we do business with a company that 
lets us download shipping orders from their web site. They used to have a 
dedicated PC here to print orders but went to this new web based system. They 
took out the PC but left the Lexmark 2380 dot-matrix printer they had here.

So now we download a text file from their web site that has the orders in it. 
The file is basically ASCII text, but does contain some special IBM ProPrint 
control characters so it can print some text at the top of the order in a 
smaller font.

You can see the printer here:
http://www.acmenet.net/~jeffny/AppleTalk/screens.html

OBJECTIVE: Deliver this text file from a Mac to the Lexmark 2380 dot-matrix 
printer. If I were using a PC the printer would just connect to the parallel 
port and you type some DOS command to send the file out to the printer. I 
want to avoid using a PC and put the Lexmark printer on our office network so 
any make on the network could print to it.

I was able to put this printer on our network using a PowerPrint for Network 
from Strydent (http://www.strydent.com/). Problem with their driver is that 
it wants the printer in Epson FX mode instead of IBM ProPrint mode....so I 
can't use their driver. You can also see screen shots of the setup software I 
have for the PrintMate on my web page above.

>From the PrintMate Documentation: "The PrintMate supports AppleTalk 
(EtherTalk), PAP, ATP, NBP, ZIP and DDP protocols, enabling Macintosh 
computers on the network to view and use the PrintMate as a regular AppleTalk 
printer."

CURRENT (Buggy) SOLUTION:
1. We download the file with the orders in it off their web site
2. We use a utility I wrote in FutureBasic to strip off the LF's at the end 
of each line...somehow they weren't needed and I kept getting an extra blank 
line. This utility also breaks down the original file into smaller files that 
can be sent to the printer....the PrintMate only has about a 20K buffer 
(thats about 8 pages for what I'm doing here).....anything that exceeded that 
got lost.
3. We send the converted smaller files to the PrintMate and printer from the 
Mac using Casper Boons LPR program. Which is a fine program except its 10 
years old and crashes a lot and also does no handshaking or flow control with 
the printer. It basically says "Hey printer, heres a text file to print! 
Catch it if you can!"

So....I attempted to write my own "LPR" program in FutureBasic and 
RealBasic....long story short AppleTalk (PAP, DDP) and TCP/IP support is 
awful in these languages. And very few people who use these languages know 
anything about either AppleTalk or TCP (believe me, I asked and asked). So I 
bought a copy of CodeWarrior Learning Edition.....it installed over 9000 
files on my computer! And it's almost as fun as writing in Assembly. .....I 
don't have the time to spend months of my free time learning C and PAP and 
DDP and all the rest. I just don't. I do most of my work now in Helix (the 
relational database) and FutureBasic for the projects I need to do.

BTW Helix blows the doors off any DB from MicroSoft and is much better than 
FileMake on many/most fronts (in my opinion). Well worth checking out  
http://www.helixtech.com/  ....and the price is very reasonable.

Anyway, so in my search for software to send my humble text file to my 
PrintMate print server I found MacPerl and then someone suggested LPRng.

A quick aside; yesterday I hacked together a modem cable and an ATEN serial 
to parallel converter then wrote a simple app in FutureBasic to send ASCII 
text out the printer port. It worked, the Lexmark printed it (as long as an 
LF is added at the end of each line). I can probably use Handshaking for flow 
control too or specify the rate at which the file is sent to avoid 
overflowing the buffer in the converter (...or just kick the baud rate down 
below the speed of the printer...not elegant, but an option). But I'd rather 
keep the printer on the network if possible.

So to sum up, I have ruled out FB, RB and C for this, I have programming 
experience but none when it comes to AppleTalk or TCP. I am also new to Perl. 
I wish you guys could see this in person, it would seem what I want to do is 
so simple. And I can't believe I'm the first person to want to do this.

If anyone feels confident this can be done in MacPerl and is interested in 
working on it I can pay you something for your time. Also, I'm in the 
Albany/Troy NY area....if anyone happens to live around hear and wants to see 
this in person. Coffees on me....

People also suggested "Net::LPR" and "Showpages (V1.4.1)", I will look for 
them and see if they will work.

Again, thanks for all the replies (some quite detailed), I appreciate the 
input very much....

Jeff-


Reply via email to