Date: Sat, 16 Dec 2006 13:02:13 +0100 From: Bernd Walter <ticso@cicely12.cicely.de> To: "Daniel O'Connor" <doconnor@gsoft.com.au> Cc: Mr CW <mrcomputerwiz@hotmail.com>, freebsd-hackers@freebsd.org Subject: Re: Capturing Parallel Port Data Message-ID: <20061216120213.GI75351@cicely12.cicely.de> In-Reply-To: <200612161112.52611.doconnor@gsoft.com.au> References: <BAY127-F2600E499F0FAE61D967201B3D40@phx.gbl> <200612161112.52611.doconnor@gsoft.com.au>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Dec 16, 2006 at 11:12:44AM +1030, Daniel O'Connor wrote: > On Saturday 16 December 2006 10:24, Mr CW wrote: > > Thank you for the pointers. It sounds like reading data back from the > > parallel port is not a common thing to do, although I thought parallel port > > projects might have done this. Then I realized that most PIC programmers, > > parallel port displays, etc. usually only receive data, not send it back to > > the computer... > > It is pretty easy to read data in a GPIO kind of fashion - you can set the > data direction (PCD) to input and then use PPIGDATA. However for what you > want the each byte of the data stream is marked by a STROBE pulse and AFAIK > there isn't a preexisting way to handle this. Well - the hardware is made to write and in some fashion to read data from a printer, not to simulate one. Using it for a self defined protocol is something else. > > I'm still looking into this, so any other suggestions are very welcome. > > If it was me I'd use a microcontroller (eg AVR) to turn the parallel data into > a serial stream and read it in to a PC's serial port. However we already make > PCBs and write microcontroller code at work.. > > Actually maybe something like this would do what you want > http://www.bb-elec.com/product.asp?SKU=232SPS2 > > I think then you could just plug it into the FreeBSD box and log the stuff > coming from the serial port. I did something like this on a C64 to scan lpt data from a PC and pass it to a serial (IEC-Bus) commodore printer. Well, it's been a very long time since then, but I asume something like the FT245BM (http://www.ftdichip.com) should do. The FT245BM is a generic parallel to USB device Interface. It's handshake features on the parallel side should match the requirements to simulate a printer - maybe with some 74ls. The other side is USB device and supported by our uftdi driver. The driver handles it as an virtual RS232 port. -- B.Walter http://www.bwct.de http://www.fizon.de bernd@bwct.de info@bwct.de support@fizon.de
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061216120213.GI75351>