Searching \ for 'Problems with PicPrg2.2 (Brian Lane) under Linux 2' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: massmind.org/techref/microchip/devices.htm?key=pic
Search entire site for: 'Problems with PicPrg2.2 (Brian Lane) under Linux 2'.

Truncated match.
PICList Thread
'Problems with PicPrg2.2 (Brian Lane) under Linux 2'
2000\02\09@103147 by berentse

flavicon
face
Hi everybody !

Since an update on my linux box from 2.0.x to 2.2.x the PicPrg2.2 from Brian
Lane, used with Tait Hardware, I can't program or read from pic's.
Is this a generic Problem ?


Martin <spam_OUTberentsenTakeThisOuTspamsent5.uni-duisburg.de>

2000\02\09@145805 by Byron A Jeff

face picon face
>
> Hi everybody !
>
> Since an update on my linux box from 2.0.x to 2.2.x the PicPrg2.2 from Brian
> Lane, used with Tait Hardware, I can't program or read from pic's.
> Is this a generic Problem ?

Yes it is. What happened is that the 2.0.x kernel assigned parallel port
numbers based on IOPORT numbers. So Brian used that mapping in PicPrg2.2
to set up the port.

The 2.2.x kernel does dynamic parallel port numbers starting at 0.

A quick fix without recompiling is to link /dev/lp1 to /dev/lp0 then configure
the picprg2.2 to use lp1.

Hope this helps,

BAJ

2000\02\10@013046 by berentse

flavicon
face
On Wed, 09 Feb 2000, Byron A Jeff wrote:

> The 2.2.x kernel does dynamic parallel port numbers starting at 0.
>
> A quick fix without recompiling is to link /dev/lp1 to /dev/lp0 then configure
> the picprg2.2 to use lp1.

yes, this is one problem. But another one is that i can't recompile the source,
because the lp.h with some structures has changed from 2.0.x to 2.2.x

Martin

2000\02\10@131046 by Byron A Jeff

face picon face
>
> On Wed, 09 Feb 2000, Byron A Jeff wrote:
>
> > The 2.2.x kernel does dynamic parallel port numbers starting at 0.
> >
> > A quick fix without recompiling is to link /dev/lp1 to /dev/lp0 then configure
> > the picprg2.2 to use lp1.
>
> yes, this is one problem. But another one is that i can't recompile the source,
> because the lp.h with some structures has changed from 2.0.x to 2.2.x

I remember that now. It was a while ago since I worked on it. The 2.2 parport
stuff has completely changed the nature of accessing the parallel ports
using the lp_struct defined in /usr/include/linux/lp.h.

I simply faked it out by adding my own structure and defining my own
LP_B macro that accomplished the same task. Also you get uint defined
you need to include the file sys/types.h.

I replaced the lp_table definition with the following code :
-------------------------------------------------------------
58,61c58,68
< struct lp_struct lp_table[] = {
<       { 0x3bc, 0, 0, LP_INIT_CHAR, LP_INIT_TIME, LP_INIT_WAIT, NULL, NULL, },
<       { 0x378, 0, 0, LP_INIT_CHAR, LP_INIT_TIME, LP_INIT_WAIT, NULL, NULL, },
<       { 0x278, 0, 0, LP_INIT_CHAR, LP_INIT_TIME, LP_INIT_WAIT, NULL, NULL, },
---
{Quote hidden}

62a70
>
8a9
> #include <sys/types.h>
-----------------------------------------------------------------------

Now honestly it still isn't right due to dynamic ioport assignment that
the 2.2 kernel does. The next thing to do is to actually open each of
/proc/parport/N/hardware files and get the base I/O port from there and
fill the lp_table values from it. It's another 10 minutes work, but it's
not 10 minutes that I've taken the time to do.

Hope this helps,

BAJ


>
> Martin
>

More... (looser matching)
- Last day of these posts
- In 2000 , 2001 only
- Today
- New search...