On Tue, 2002-11-26 at 15:03, Peter Asemann wrote:
> For an assignment I need to write an "odd" piece of software, a parallel port
> hardware emulator.
Unfortunately the only obvious commercial purpose for such a device is
to misuse software protection dongles. So its a circumvention device,
and probably illegal to make 8)
> So I have some questions:
> Is it possible (as an user) to access all parallel-port functionality
> (including read/write to status, control and all data registers) using the
> /usr/src/linux/drivers/char/ppdev.c driver?
It should be yes - if you can't then someone missed a feature out and
you should fix it. Things like DMA are obviously somewhat more
> And, most important, how and where do the parport drivers probe which
> hardware is present, and how do the most common chipsets react? That's very
> important for me to know, and I couldn't find the probing routinges so far.
> There must be rules like "if you write XY to register Z and reread it, and
> bit a has changed, then the chipset supports EPP, otherwise it's SPP" or
> something. I guess. Give me a hint. Tutorial suggestions are welcome, too.
You don't want to me working at that level. The answer at that level is
"it depends, read the spec for each chip, read the errata, discover
several new ones".
You might therefore want to consider emulating at a higher level - make
your virtual device handle virtual ways of switching to epp/spp etc, and
then map that onto the exist lp layer functionality.
-- To unsubscribe, send mail to: email@example.com --
-- with the single word "unsubscribe" in the body of the message. --
This archive was generated by hypermail 2b29 : Tue Nov 26 2002 - 10:33:27 EST