Configuring Parallel Port

Discussion of linuxCNC (formerly knows as EMC2)
Post Reply
danimal
Posts: 332
Joined: Wed Mar 13, 2013 5:53 pm
Location: Colorado

Configuring Parallel Port

Post by danimal » Sun Mar 02, 2014 7:14 pm

This is what I get when I enter lspci -vv:

03:05.0 Communication controller: NetMos Technology PCI 9835 Multi-I/O Controller (rev 01)
Subsystem: LSI Logic / Symbios Logic Device 0012
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-
Interrupt: pin A routed to IRQ 20
Region 0: I/O ports at e800
Region 1: I/O ports at e400
Region 2: I/O ports at e000
Region 3: I/O ports at d800
Region 4: I/O ports at d400
Region 5: I/O ports at d000
Kernel driver in use: parport_serial
Kernel modules: parport_serial

First, with a little research I found that there are problems with some of the NetMos chipsets but that seemed to be specifically 9005 and 9815 with no mention of the 9835 have any problems or working correctly. Does anyone have any evidence either way?

Second I am having problems installing the PCI parallel port card. I tried the following but received the error:

dan@LinuxCNC:~$ /sbin/modprobe parport_pc io=0x3f8,d000 irq=4,18
WARNING: All config files need .conf: /etc/modprobe.d/emc2, it will be ignored in a future release.

Honestly I do not know what the IRQ is, but I tried listing it at both 18 and 20 and received the same error. The install instructions for the card listed 18 for the IRQ. /dev/lp0 is visible and seems to be functioning properly, I dont know what else to do and honestly I have not worked with Linux based systems for a few years now.
Shapeoko # 1458

RT0701C Spindle || dual y motor || x axis nema23 with custom carriage 1000mm length || z axis nema23 linear rail upgrade with 1/2-10 ACME

danimal
Posts: 332
Joined: Wed Mar 13, 2013 5:53 pm
Location: Colorado

Re: Configuring Parallel Port

Post by danimal » Mon Mar 03, 2014 8:10 pm

I have been working on this off and on for the last few days. So far I have built three additional computers out of old parts to chase down the PCI address issue for cards installed on computers not equipped with a parallel port on the motherboard. I found an old motherboard with a parallel port, and it took me about 5 minutes to locate the address in bios, change the setting in the stepconf wizard and have the G540 running strong. But this old computer is a monster, and I just do not have room for it, the controller and power supply and an additional PC for running the design software. It is not a powerful enough PC to run AutoCAD and SprutCAM. So I need to get my other PC up and running with the PCI parallel port.

How do you find the parallel port base address for a PCI card based parallel port? I have tried the lspci -v as seen above, but the address of 0xd000 did not work.In BIOS there is just a list of interrupt requests an nothing stating what PCI slot or address anything is installed in.
Shapeoko # 1458

RT0701C Spindle || dual y motor || x axis nema23 with custom carriage 1000mm length || z axis nema23 linear rail upgrade with 1/2-10 ACME

Improbable Construct
Posts: 997
Joined: Tue Apr 10, 2012 3:21 am
Location: Fairhope, AL
Contact:

Re: Configuring Parallel Port

Post by Improbable Construct » Mon Mar 03, 2014 9:19 pm

As far as I can tell some cards work and some cards don't work.
Unfortunately what card and motherboard/bios combination works isn't clear until its tried.
I would try to get one of the parallel cards known to work and hope it will work with your system.
This:
http://www.cnczone.com/forums/joes-cnc- ... -card.html
or this:
http://www.machsupport.com/forum/index. ... 910.0.html
might help.

Also you can pick up a referb dual core box with a parallel port for under $100 on amazon or ebay.
Shapeoko #Classified some of the bolts may be original parts.
Shapeoko 1 # ???? Stainless plates, still in the box.
Shapeoko 2 # 3926 not stock
Shapeoko 3 # 0003
Store:
http://ImprobableConstruct.com
Twitter:
https://twitter.com/ImprblConstruct

danimal
Posts: 332
Joined: Wed Mar 13, 2013 5:53 pm
Location: Colorado

Re: Configuring Parallel Port

Post by danimal » Tue Mar 04, 2014 4:18 am

Improbable Construct wrote:As far as I can tell some cards work and some cards don't work.
Unfortunately what card and motherboard/bios combination works isn't clear until its tried.
I would try to get one of the parallel cards known to work and hope it will work with your system.
This:
http://www.cnczone.com/forums/joes-cnc- ... -card.html
or this:
http://www.machsupport.com/forum/index. ... 910.0.html
might help.

Also you can pick up a referb dual core box with a parallel port for under $100 on amazon or ebay.
Fortunately my father in law is a firmware engineer and has piles of computer stuff and had one that he gave to me. It works perfectly with the controller. I just wanted to dual boot with one machine so that I did not have two full size towers to design parts and run the controller. Now I am looking into creating a network with the two computers, and using remote desktop on the one to drive the computer through a shared file network with windows on one machine and Ubuntu on the other. I kinda I think that I am making my life harder, but at least I am learning stuff.
Shapeoko # 1458

RT0701C Spindle || dual y motor || x axis nema23 with custom carriage 1000mm length || z axis nema23 linear rail upgrade with 1/2-10 ACME

danimal
Posts: 332
Joined: Wed Mar 13, 2013 5:53 pm
Location: Colorado

Re: Configuring Parallel Port

Post by danimal » Wed Mar 05, 2014 2:15 am

Just a follow up to this, if you are going to buy a PCI or PCI-E based parallel port make sure it does not have any NetMos chipset. That was the problem. The controller works with every other parallel port that I have tried, just not the 9835 Netmos one. Now if I could just get Ubuntu to stop messing up my boot configuration files for my windows HDD life would be great.
Shapeoko # 1458

RT0701C Spindle || dual y motor || x axis nema23 with custom carriage 1000mm length || z axis nema23 linear rail upgrade with 1/2-10 ACME

danimal
Posts: 332
Joined: Wed Mar 13, 2013 5:53 pm
Location: Colorado

Re: Configuring Parallel Port

Post by danimal » Mon Mar 24, 2014 5:15 am

One last update on this. I want to get this down for anyone that experiences the same problems. I managed to get my machine up and running on three different parallel ports, one on the motherboard of my mini ITX build, and the other two were PCI and PCIe cards. Each of the ports had their own issues, but they all had a common solution. That solution is to start with a fresh, non-updated copy of linuxCNC. If you install updates and any non-essential drivers it can cause all kinds of problems with your machine. I installed a graphics driver that conflicted with the INI file for linuxCNC and it was crashing it on startup. I have an old graphics card that I put into my first build with an old motherboard and the driver for it rewrote a xorg file somewhere for the machine and this file was used during boot for the graphical display.

These are the steps I used to get my machine up and running:

Install linuxCNC
1) Find parallel port address which for motherboards with built in parallel ports is found in BIOS, or you can enter

Code: Select all

dmesg | grep par
into terminal and any installed parallel port addresses and IRQ will be given. This should work for PCI cards too. If this does not show a parallel port (parport0: PC-style at 0x378, irq 5 [PCSPP,TRISTATE,EPP] for example) then you will need to install the parport drivers.

2) With that information you can run and test Stepconf Wizard entering the address (0x378 for example) into the First Parport Base Address box.

3) Calculate your machine distance travel for your individual profile. For shapeoko, you multiply the number of teeth on your pulley (usually 18) by the pitch (2mm for both the GT2 and MXL belts) this gives your your pitch diameter in mm. Convert this into your machine units (in or mm) then you need to standardize this number as a rotational distance. Normally you could use your threads per inch to derive the number of turns required for 1" of linear movement for screw driven machines. So you have to divide 1 by the rotational distance of the pulley.

18 teeth X 2mm pitch = 36mm per revolution

36mm = 1.41732 in

1/1.41732 in = 0.705556967 revolutions per 1" of axis travel. This value should be entered into the Leadscrew Pitch box for the Stepconf Wizard for the respective axis.

Really I am impressed with the capabilities of LinuxCNC and how smooth my system is running with the G540. I am sure that there are a million other configurations and problems to run into, but I bet that I googled and troubleshoot about 10,000 of those problems throughout setting the machine up. Hopefully this helps someone get their machine up and running.
Shapeoko # 1458

RT0701C Spindle || dual y motor || x axis nema23 with custom carriage 1000mm length || z axis nema23 linear rail upgrade with 1/2-10 ACME

Post Reply