Twin Parallel Ports and 2x 7i43

More
29 Jul 2013 10:27 #37192 by jsflanagan
The next saga on my Hardinge CHNC conversion is I need to be able to read an encoder as my spindle uses an encoder for position. So, I've decided to use a second 7i43 and a 7i33. I chose these since I'm already using them on my Milltronics Mill, and I can borrow them for now and then once I get it working order replacements for my mill. I'm struggling with getting a second parallel port working with the 7i43. I had a PCI parallel port card laying around so that's the one I'm using, and I'm thinking it's causing my trouble. The card is a NetMos 9865, in my research to fix this I've found mention that the NetMos 9805 specifically does not work with the 7i43, so I'm guessing that the Netmos 9865 is close enough to not work.

Any recommendations as to what parallel cards do work with the 7i43? I see in the documentation both the Startech (maybe need some program to set it to EPP?) and the SIIG based chip boards seem to do well. I just haven't found any posts of people specifically using an add-on card for the 7i43. So I figured I'd ask and see if anyone had an example of a specific board (P/N and all) that works with the 7i43 so I can order that and make it all work.

I took a stab at writing a hal file for my current setup, it and the error output are attached. I'm kind of guessing whatever I do here won't work w/out a new card but I figured it was good practice on interpreting the lspci.

From the lspci output:
05:04.0 Parallel controller: NetMos Technology PCI 9865 Multi-I/O Controller (prog-if 03)
Subsystem: Device a000:2000
Flags: bus master, medium devsel, latency 32, IRQ 11
I/O ports at 1000
I/O ports at 1008
Memory at fc510000 (32-bit, non-prefetchable) [size=4K]
Memory at fc511000 (32-bit, non-prefetchable) [size=4K]
Capabilities: <access denied>

I assumed my add-on board is at 1000 so I put that in the ioaddr for the second board. Initially I tried specifying the motherboard parallel port at ioaddr=0378 and ioaddr_hi=0 but I always got error messages and it struggled to find the first parallel port, once I removed the ioaddr for the first board it seemed to load fine and then it gets hung up.

The loadrt call I used:
loadrt hm2_7i43 config="firmware=hm2/7i43-4/SVRM6S.BIT num_encoders=0 num_pwmgens=6 num_3pwmgens=0 num_stepgens=0 num_resolvers=6 ,firmware=hm2/7i43-4/SVST4_4.BIT ioaddr=0x1000 ioaddr_hi=0 num_encoders=2 num_pwmgens=1 num_3pwmgens=0 num_stepgens=0 "

It would seem to proceed just fine displaying all of the IO pin configurations and then:

[ 4063.465466] hm2_7i43.0: board at (ioaddr=0x0378, ioaddr_hi=0x0778, epp_wide ON) found
[ 4063.465487] PARPORT: ERROR: request_region(0x3f8) failed
[ 4063.465491] hm2_7i43.0: releasing board

I'm not really sure what is going on at that point. The full error log is attached along with my hal, lspci output and ioports. Looking forward to seeing what parallel card people have had success with for the 7i43, then maybe this part will work! Until then I get to do the easy part of home, limtis, PID tuning. All of that is so less daunting with one conversion under my belt.

-Scott
Attachments:

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

More
29 Jul 2013 20:44 #37224 by PCW
Replied by PCW on topic Twin Parallel Ports and 2x 7i43
Can you try the PCI parallel port/7I43 by itself?
Also including you ini file would possibly help

(or just paste the config = "blah blah blah" section in the forum text)

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

More
30 Jul 2013 09:25 #37250 by jsflanagan
I like the idea of singling out the one board, so tonight I started even more basic and tried to specify the address of the motherboard parallel port using the ioaddr=0x0378, ioaddr_hi=0. I finally could get linuxcnc to find the board but then it has issues with request_region. I've tried all sorts of variations for the ioaddr_hi, had it =0. Also, the manual didn't seem to show that you need a comma before the ioaddr= otherwise it wasn't found. Any ideas on where to go from here, I did try this all on the second PCI card as well using its address of 1000 (tried it in decimal and hex as well). But that didn't work, didn't expect it to if I can't even get my known working parallel port to work.

Errors:
[ 4063.465466] hm2_7i43.0: board at (ioaddr=0x0378, ioaddr_hi=0x0778, epp_wide ON) found
[ 4063.465487] PARPORT: ERROR: request_region(0x3f8) failed
[ 4063.465491] hm2_7i43.0: releasing board
[ 4063.465516] hm2/hm2_7i43.0: unregistered

Command used to load:

loadrt hm2_7i43 config="firmware=hm2/7i43-4/SVRM6S.BIT, ioaddr=0x0378, ioaddr_hi=0, num_encoders=0 num_pwmgens=6 num_3pwmgens=0 num_stepgens=0 num_resolvers=6"
Attachments:

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

More
30 Jul 2013 09:55 #37251 by PCW
Replied by PCW on topic Twin Parallel Ports and 2x 7i43
Thats pretty strange considering 0x3F8 is not in the range of
the parallel port with a base address of 0x378

I guess the first thing to do is go back to where it was working
I would also try a minimal config line:

loadrt hm2_7i43 config="firmware=hm2/7i43-4/SVRM6S.BIT"

ought to be ok for the default 0x378

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

More
30 Jul 2013 19:49 #37261 by jsflanagan
Yes I should have mentioned I tried that first, and of course it did work as I was succesfully running the single board off the motherboard parallel port. I also did try letting it automatically find the PCI parallel port card by launching EMC w/ no ioaddrr but with the 7i43 plugged into the PCI card, that didn't work. I do have a few SIIG based parallel cards on the way now so I will try them when they get here. But, it seems like I need to figure out how to make linuxcnc specifically address at least the motherboard parallel first.

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

More
30 Jul 2013 21:33 #37264 by PCW
Replied by PCW on topic Twin Parallel Ports and 2x 7i43
I dont know if the NetMOS 9885 chip will work or not (the 9805 and 9815 do not as they do not implement EPP mode correctly), it definitely will not work unless you specify either an address or a card index (the default if none is supplied is always 0x378)

It may be that the driver does not support 2 cards, looking at the driver manual, (man hm2_7I43) I dont see any suggestion that 2 cards are supported (multiple PCI card are supported so that why I didn't think it was an issue)

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

More
31 Jul 2013 00:28 #37275 by jsflanagan
I'll have to go back and search the forum again but I thought that someone else had successfully run two 7i43 cards. When you say that you don't see any suggestion that 2 cards are supported do you mean that the hm2_7i43 driver can't control two boards? I do have multiple SIIG parallel port cards on the way now, so maybe this will work with two PCI parallel cards? They should be in Friday and I'll try that.

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

More
31 Jul 2013 00:57 - 31 Jul 2013 01:07 #37277 by PCW
Replied by PCW on topic Twin Parallel Ports and 2x 7i43
OK I just looked at the source and the driver is supposed to support up to 4 cards
I suspect what going on is this:

Somehow the configuration parser is not getting the second ioaddr
and therefor using its (bogus) default of 0x3f8:


static int ioaddr[HM2_7I43_MAX_BOARDS] = { 0x378, 0x3f8, [2..(HM2_7I43_MAX_BOARDS-1)] = 0 };

EDIT: just noticed that the ioaddr setting is not in the config string but earlier
in the hm2_7i43 command line:

I would try something like this

loadrt hm2_7i43 ioaddr=0x1000 config=" firmware=hm2/7i43-4/SVRM6S.BIT" to check your NetMOS card
Last edit: 31 Jul 2013 01:07 by PCW. Reason: errors

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

More
31 Jul 2013 05:00 #37280 by jsflanagan
Ok, so I tried launching with the following line:

Using:
loadrt hm2_7i43 ioaddr=0x1000 config=" firmware=hm2/7i43-4/SVRM6S.BIT"
Error:
[ 1342.998252] hm2: loading Mesa HostMot2 driver version 0.15
[ 1343.003186] hm2_7i43: loading HostMot2 Mesa 7i43 driver version 0.3
[ 1343.005208] hm2_7i43: /DONE is not low after CPLD reset!
[ 1343.005770] hm2_7i43.0: firmware: requesting hm2/7i43-4/SVRM6S.BIT
[ 1343.008050] hm2/hm2_7i43.0: board has FPGA '3s200tq144', but the firmware in hm2/7i43-4/SVRM6S.BIT is for FPGA '3s400tq144'
[ 1343.008061] hm2_7i43.0: board at (ioaddr=0x1000, ioaddr_hi=0x1400, epp_wide ON) not found!
[ 1343.323175] hm2: unloading

The result was it thought it had the wrong size BIT file, but I know the BIT file is correct as I've run it w/ no problems when I load w/out the ioaddr on the motherboard's port. So just to verify I plugged in my 200k 7i43 that has the encoder board hooked up to it, loaded it with the following line and got another error. So, I'm thinking it is probably just the bogus NetMOS chip, I've got a bunch of SIIG cards on the way (large ebay lot!). So I'll test that out when they get here, hopefully by the weekend.

Using:
loadrt hm2_7i43 ioaddr=0x1000 config=" firmware=hm2/7i43-2/SVST4_4.BIT"
Error_2.txt:
[ 1509.704368] hm2: loading Mesa HostMot2 driver version 0.15
[ 1509.709023] hm2_7i43: loading HostMot2 Mesa 7i43 driver version 0.3
[ 1509.711022] hm2_7i43: /DONE is not low after CPLD reset!
[ 1509.711051] hm2_7i43.0: firmware: requesting hm2/7i43-2/SVST4_4.BIT
[ 1509.715411] hm2_7i43: /DONE is not low after CPLD reset!
[ 1509.715420] hm2/hm2_7i43.0: failed to reset fpga, aborting hm2_register
[ 1509.715427] hm2_7i43.0: board at (ioaddr=0x1000, ioaddr_hi=0x1400, epp_wide ON) not found!
[ 1510.017397] hm2: unloading
Attachments:

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

More
31 Jul 2013 05:38 #37282 by PCW
Replied by PCW on topic Twin Parallel Ports and 2x 7i43
Yes this is likely because the 9865 will not work in EPP mode
(or less likely because the 0x1000 address is wrong)

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

Time to create page: 0.107 seconds
Powered by Kunena Forum