× Forum Header

Setting up parallel port

More
16 Oct 2014 02:48 #52127 by SteveT
Hi
Can someone please give some help, I have installed a parallel port pci card to my PC as the mother board is without one, I have
identified its address which is e800 and e480 and have tried both in StepConf with no luck.
I have looked in the HAL ini file and probe_parport is present and I am still not connecting to the driver!!!

Now I am at a bit of a loss on what to check next

Steve

Please Log in or Create an account to join the conversation.

More
16 Oct 2014 13:14 - 16 Oct 2014 17:20 #52134 by ArcEye
Replied by ArcEye on topic Setting up parallel port
Hi

In a terminal, run lspci -vv > lspci.txt and post the resulting file lspci.txt

You probably have 4 addresses listed, 2 are ports and 2 are data registers, you have likely chosen the wrong addresses.
Which is which is often counter intuitive.

regards

see also my FAQ at
www.linuxcnc.org/index.php/english/forum...-parallel-port-cards
Last edit: 16 Oct 2014 17:20 by ArcEye.
The following user(s) said Thank You: SteveT

Please Log in or Create an account to join the conversation.

More
19 Oct 2014 22:30 #52192 by SteveT
Replied by SteveT on topic Setting up parallel port
Thanks
This is the file as requested

File Attachment:

File Name: lspci.txt
File Size:12 KB
Attachments:

Please Log in or Create an account to join the conversation.

More
19 Oct 2014 22:40 #52193 by ArcEye
Replied by ArcEye on topic Setting up parallel port
01:05.2 Parallel controller: NetMos Technology PCI 9865 Multi-I/O Controller (prog-if 03 [IEEE1284])
Subsystem: Device a000:2000
Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B- DisINTx-
Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Latency: 64, Cache Line Size: 64 bytes
Interrupt: pin C routed to IRQ 17
Region 0: I/O ports at e800
Region 1: I/O ports at e480
Region 2: Memory at fdffb000 (32-bit, non-prefetchable) [size=4K]
Region 4: Memory at fdffa000 (32-bit, non-prefetchable) [size=4K]
Capabilities: <access denied>
Kernel driver in use: parport_pc


There are 2 issues here

1) there is only one parport, it is probably at 0xe480, the port is normally the lower address on Netmos boards, the other address is the register

2) The port has been claimed by parport_pc, which will prevent hal claiming it at boot of Linuxcnc

Try opening a terminal and issuing

sudo rmmod parport_pc
sudo rmmod ppdev
sudo rmmod lp
modprobe parport

Then run stepconf again and see if it recognises the port

If it does the unwanted modules can be blacklisted (they should be already)

regards
The following user(s) said Thank You: SteveT

Please Log in or Create an account to join the conversation.

More
19 Oct 2014 23:07 #52194 by SteveT
Replied by SteveT on topic Setting up parallel port
Hi

I get this error

steven@CNC:~$ sudo rmmod parport_pc
[sudo] password for steven:
Error: Module parport_pc is in use
steven@CNC:~$

Steve

Please Log in or Create an account to join the conversation.

More
19 Oct 2014 23:22 #52195 by ArcEye
Replied by ArcEye on topic Setting up parallel port
Try unloading ppdev first, this was off the top of my head, I'm not at a linux box right now.

Please Log in or Create an account to join the conversation.

More
20 Oct 2014 00:30 - 20 Oct 2014 16:19 #52197 by ArcEye
Replied by ArcEye on topic Setting up parallel port
Alternately, try creating a file called /etc/modprobe.d/linuxcnc.conf
which contains
blacklist ppdev
blacklist parport_pc


then reboot and run
lsmod
and check that parport is loaded and that ppdev and parport_pc are not

You need parport loaded for low level access to the parallel port, but not ppdev and parport_pc, which will claim the port and prevent linuxcnc from doing so

If parport is not loaded then
modprobe parport

To make this permanent, add the line
parport
to /etc/modules

regards
Last edit: 20 Oct 2014 16:19 by ArcEye.
The following user(s) said Thank You: SteveT

Please Log in or Create an account to join the conversation.

More
20 Oct 2014 23:17 #52214 by SteveT
Replied by SteveT on topic Setting up parallel port
Hi

I think that has worked, this is the output from "lsmod" as far as I can tell hal has conected to the paraport.

Thanks for your help it is very much appreciated. Steve

steven@CNC:~$ lsmod
Module Size Used by
charge_pump 12383 0
stepgen 16544 0
hal_parport 16727 0
probe_parport 12446 0
motmod 153177 0
trivkins 12495 1 motmod
hal_lib 39487 6 probe_parport,trivkins,hal_parport,stepgen,charge_pump,motmod
rtapi 34887 6 probe_parport,hal_parport,stepgen,charge_pump,hal_lib,motmod
rtai_math 56034 0
rtai_sched 191741 1 rtapi
rtai_hal 231371 2 rtapi,rtai_sched
bnep 17186 2
rfcomm 36117 0
bluetooth 166348 10 bnep,rfcomm
rfkill 18403 2 bluetooth
lp 12767 0
parport 35208 2 lp,hal_parport
uinput 17057 1
nfsd 202675 2
nfs 277039 0
nfs_acl 12464 2 nfs,nfsd
auth_rpcgss 32226 2 nfs,nfsd
fscache 35490 1 nfs
lockd 56898 2 nfs,nfsd
sunrpc 151263 6 nfs,nfsd,auth_rpcgss,lockd,nfs_acl
loop 21832 0
nouveau 722446 3
mxm_wmi 12468 1 nouveau
wmi 17148 2 mxm_wmi,nouveau
video 17461 1 nouveau
ttm 54921 1 nouveau
drm_kms_helper 26601 1 nouveau
drm 169993 5 ttm,drm_kms_helper,nouveau
thermal_sys 17699 1 video
power_supply 13320 1 nouveau
i2c_algo_bit 12648 1 nouveau
i2c_nforce2 12521 0
k10temp 12540 0
i2c_core 23097 5 drm,drm_kms_helper,i2c_algo_bit,nouveau,i2c_nforce2
evdev 17099 9
button 12818 1 nouveau
ext4 270189 1
crc16 12328 2 ext4,bluetooth
jbd2 54294 1 ext4
mbcache 12899 1 ext4
sg 25482 0
sr_mod 21529 0
cdrom 38893 1 sr_mod
sd_mod 43403 3
crc_t10dif 12333 1 sd_mod
usbhid 39608 0
hid 72252 1 usbhid
usb_storage 39140 0
floppy 51935 0
ata_generic 12440 0
microcode 17386 0
forcedeth 56263 0
ohci_hcd 26266 0
pata_amd 13084 0
sata_nv 22085 2
libata 152992 3 sata_nv,pata_amd,ata_generic
scsi_mod 125436 5 sg,usb_storage,libata,sd_mod,sr_mod
ehci_hcd 43561 0
usbcore 124257 5 usb_storage,ohci_hcd,ehci_hcd,usbhid
usb_common 12339 1 usbcore

Please Log in or Create an account to join the conversation.

More
20 Oct 2014 23:22 #52216 by ArcEye
Replied by ArcEye on topic Setting up parallel port

parport 35208 2 lp,hal_parport


Yep, that all looks about right.

On to the next challenge (problem) :laugh:

regards

Please Log in or Create an account to join the conversation.

More
01 Jul 2015 23:11 #60312 by dennis.lewis5
I have added a pci card with two parallel ports on it. I can use ptest to activate/read one port which is all I need. However when in stepconfig I specify a second port but do not get a panel to define any connections on the second port.

using the guidance in this topic it looks as if there is no contention for the port. any suggestions?

Please Log in or Create an account to join the conversation.

Time to create page: 0.096 seconds
Powered by Kunena Forum