[plug] serial/parallel protocol logging

Mike Holland myk at golden.wattle.id.au
Mon Feb 21 10:12:02 WST 2000


Hi John,

On Mon, 21 Feb 2000, John Summerfield wrote:

> You should have kept this on-list. Quite likely someone else (maybe DC) 

It was, but I also CC:ed to you direct. The listserver seems to be down.
I'll send this to plug too.

> > > in dump mode, of course.
> > 
> > Of course. Could you elaborate a little please. It doesnt seem to be
> > mentioned in the lp(4) man page. Where might i get info?

> Read your printer manual; the printer probably has an option to print 
> everything coming its way in hex.

Its a scanner :( And I need to log bidirectional protocol here. Not so
simple.

> > That doesnt sound trivial. e.g. logging the direction of bytes, avoiding
> > buffer overflow. Any pointers?
> 
> To do the job properly, I suspect you're looking at devicer-driver-land. 

Absolutely. I had hoped either:
- the existing drivers have a facility for this. (As the tcp/ip drivers
do.)
- or a redirecting pseudo device driver can do it.

> It might be easier to fiddle with the standard driver to simply log 
> everything to disk.

 I've never programmed Linux kernel, so that would be a big step.
Is "log to disk" _simple_ in ther kernel? Maybe via syslogd.

> However, if you wanted to see what Windows does, 
> 	take two computers.
> 	Link with a laplink or similar cable.
> 	On Linux, read everything coming in.
> 	Log it, send it on to the printer,
> 	Read stuff from the printer, log it, send it on to the other computer.
> There is some chance that you won't be able to get the hardware signals at 
> the Windows computer 'just so.'

s/printer/scanner/g
Now there's an idea. That would avoid kernel programming. Thanks!
Still sounds like a lot of wheel re-inventing though. Somebody must have
done this before.

> It's also possible that you could do something very like this under 
> vmware; I don't know anything much about vmware, but if it makes Windows 
> think it's talking to real hardware, AND you can do some programming at 
> the right point, the chances are good.

Again, we are talking kernel programming, no?
I was hoping somebody might be able to help me find some specific info on
the web. It seems nobody here has done anything similar, so I'll try some
more specialist lists.

regards,

Mike Holland <mike at golden.wattle.id.au>            Perth, Australia.
                          --==--




More information about the plug mailing list