SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
more googling turned up a snippet about parport.opts for multiple cards, I don't have multiple cardss but here is my translation of that page:
Code:
case "$ADDRESS" in
*,0,*)
# Options for card in socket 0
LINK=/dev/parport0
# Options for 'tunelp'
LP_OPTS=""
# Card eject policy options
NO_CHECK=n
NO_FUSER=n
;;
esac
also had to recompile kernel to include parport, parport_pc (IBM style), parport_cs (cs=card services?) module support. those were listed as required. thats 'M' for ALL the parport options in 2.6.19.1, apparently the modular setup is required.
so dmesg seems to now also recognize the card, and I made a symbolic link to the pcmcia 'card':
It'd be great help if anyone has time to peruse the above and poke any holes in it they might find. I have only 1 parallel port peripheral which has to be run from either DOSEMU or WINE which really confounds the debugging process here..
pls remember I'm a n00b at this and any scrutiny is appreciated. I'll of course keep plugging at this and sorry if my rambling is wasting space/time on the continuum..
It's a udev thing. The config file (IIRC) is at /etc/udev/rules.d/udev.rules or somesuch. Can't help you with the actual configuration changes, though.
you are correct, and I've been reading through the man pages about this but I'm not sure how to translate my card to the parport0 device node.
I have since done more tweaking, and now my kernel added ppdev (under char devices) which if I modprobe ppdev gives me a /dev/parport0 but I think thats still incorrect, because its not pointing to the pcmcia card.
the udev.rules is confusing the hell out of me..
i can't get wine to work with the parport either...
so I am now trying to get this up and working in dosemu (1.3.4, with free-dos) and added the line:
Code:
$_ports = $_ports, "device /sys/bus/pcmcia/devices/0.0 fast range 0x378 0x37f" # lpt0
which doesn't work... i'm searching for dosemu.conf syntax now..
++tried this
Code:
$_ports = $_ports, "0x2100 fast range 0x378 0x37f" # lpt0
i get no detection from dosemu @ 0x378 though...
also of note, in windows the little light on my peripheral will glow red when plugged into the port, but now in linux it is not on... does this mean my port is not really 'on' or just that windows is sloppy about handing out power?
so now i'm trying to test from the linux side
Code:
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <asm/io.h>
#define base 0x378 /* printer port base address */
#define value 255 /* numeric value to send to printer port */
main(int argc, char **argv)
{
if (ioperm(base,1,1))
fprintf(stderr, "Couldn't get the port at %x\n", base), exit(1);
outb(value, base);
}
old snippet of a progr I found, but evervalue I can think to try as base returns 'couldnt get the port'
so the way the drivers work, please anyone correct me if I'm misrepresenting here, the parport is the top level driver and handles stuff to the kernel direct, parport_cs gets & passes information via parport_pc to create the pcmcia device. At this point one could use the address found by:
the address of our port being 0x2100, with a range to 0x2107 (I still havent come across why its split like that... but its late and I'm no longer thinking) <edit - i guess its an addr size v. pins?>
<edit forgot something-sorry 'tis late here>
so the scrupulous reader will note that the assignments changed between post #6 and this one. thats because of this bus path:
which finally let me cpu talk with the cardbus. the basic idea is there must be direct path between 00 and 02 (i'm kind of guessing here) else we better create on at boot time. another way to check for this need was/is dmesg | grep assign. if you see the kernel recommending it, go for it..
but lets just say... hypothetically, you need to use dosemu to write to an eprom burner, or eprom emulator...
enter ppdev... ppdev creates /dev/parport0 so that in /etc/dosemu.conf you can do this:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.