Configuration Problems for The Beast

More
03 Jul 2012 22:03 #21529 by BruceLayne
I'm retrofitting a giant four axis gantry machine that I lovingly refer to as The Beast. 4' X 8' bed. 7.5 HP radial arm saw. Two 15 HP routers. Two air drills.

I have LinuxCNC 2.5 running and stable on an old PC with good latency (low jitter). I'm using Allen Bradley Ultra3000 servo drives to move the big Siemens servo motors left over from the original Fanuc controls with Seimens SeimoDrive motion control. All of the old Fanuc and Siemens controls are gone. I have a MESA 5i25 card in the PC, talking to a 7i77 servo and I/O board, that will be connected to a 7i64 I/O board via RS422 for the remote I/O on the gantry.

This is my first LinuxCNC conversion, but I have at least two more planned. I expected a steep learning curve, and I've been reading a lot online and trying to learn from the available documentation, as well as learning from other people's problems and solutions. I'm starting to feel like I can't even get off square one. I can run LinuxCNC with a simulation configuration, and I had a PNCconfig generated configuration that wasn't right, but at least LinuxCNC would start. After running PNCconfig again to fix some of what wasn't right, I now get errors and LinuxCNC won't start. I tried running the 5i25-7i77 config that I downloaded from www.linuxcnc.org/index.php/english/compo...ew&catid=39&id=20043 .

I have the manuals from wiki.linuxcnc.org/cgi-bin/wiki.pl. I've been reading and trying to learn, but part of my trouble is that I'm working on this project in the evenings and I'm having trouble becoming an expert fast enough. I feel that I know a lot of specifics, but I'm still missing a lot of the big picture, although some of the threads in . www.linuxcnc.org/index.php/english/compo...unc=showcat&catid=32 definitely help.

There's a lot to learn, and it's hard to even crawl until a lot of that has been learned.

I'm probably making this a lot harder than it needs to be. It seems that a new LinuxCNC installation should have some generic machine configurations for a stepper mill, a servo mill, a stepper lathe, a servo lathe, etc. I should be able to open one of those that's close, save it as my own machine configuration and then start tweaking it to change the limits, encoder counts, etc., either using a GUI configuration tool like PNCconfig or by manually editing the files, but that definitely doesn't seem to be working for me.

Anybody who really understands this stuff want to make $100 for an hour of phone consulting? It just seems that I've wandered in the LinuxCNC desert for days and at this point I'm not sure if I'm even learning much that can help me overcome what are probably some simple problems. I'm an EE with a lot of machine design experience and a LOT of microcontroller systems design and programming, but I feel like I'm getting nowhere fast, frustration is setting in and it's always downhill from there. I understand the basic concepts and many of the specifics, but I'm getting lost in some specifics, details and syntax.

I've attached a text file with the errors generated when I tried to run LinuxCNC with the configuration I produced with PNCconfig. The errors when I tried to use the recommended 5i25-7i77 config were similar. It sort of looks like LinuxCNC is unable to find some files?

File Attachment:

File Name: Error_MyPN...nfig.txt
File Size:6 KB
Attachments:

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

More
03 Jul 2012 23:41 - 03 Jul 2012 23:43 #21536 by BigJohnT
LinuxCNC can't find a pin on the 7i64 card. Comment out any reference to the 7i64, run your config and see if the 7i64 pins are there. How did you know I charge $100 an hour? If you see the 7i64 pins then you might have a typo... the best way (Peter taught me this) is with your config running open a terminal and say halcmd show pins > pins.txt and this will give you a list of all your pins so you can copy and paste easier.

I can understand and relate to your frustrations for sure...

John
Last edit: 03 Jul 2012 23:43 by BigJohnT.

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

More
03 Jul 2012 23:48 #21537 by BigJohnT
BruceLayne wrote:

I have a MESA 5i25 card in the PC, talking to a 7i77 servo and I/O board, that will be connected to a 7i64 I/O board via RS422 for the remote I/O on the gantry.


I assume you need the 7i64 online or the HAL pins won't be available...

John

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

More
04 Jul 2012 00:14 #21540 by andypugh
BruceLayne wrote:

I've attached a text file with the errors generated when I tried to run LinuxCNC with the configuration I produced with PNCconfig.

I think there are two issues here. One that you haven't even noticed yet…

The one that is biting you now is that the 7i64 is on sserial port 0 channel 1. So it will be hm2_5i25.0.7i64.0.1.digin… whereas your HAL files referring to 7i63.0.2...

Something that you haven't noticed yet is that your 7i77 sserial components are not active either (the dmesg printout hasn't got a sserial TXdata0 and RxData0
This is probably because the field power isn't connected on the 7i77 board.

The first thing to do is to get a list of all the pins. The Mesa Smart Serial devices name the pins themselves and the actual names depend on which devices are plugged in to each port.

Open a terminal window and power up the 7i77 etc.
Then
:/$ halrun
halcmd: loadrt hostmot2
halcmd: loadrt hm2_pci
halcmd: show pin
haldmd: show param

That will give you a list of all your HAL pins and parameters. You can copy them to a text file to check your HAL file. (In fact, you can even use them for tab-completion with the right GEdit plugins)

What you are doing there is opening an interactive HAL session. You can load and unload components, and make nets and set values. basically anything that can happen in the main HAL file, except of just gives you an error if it fails, rather than dropping completely out.

It _is_ a very steep learning curve. But there are lots of people here to help, either on the forum or live on IRC.

A high-level overview of HAL:
Every component loaded in to the HAL with a "loadrt" statement creates a set of "pins" These can be connected together in the HAL file so that information flows between the components. (for example from the motion controller to the PID to the 7i77 analogue outputs.)
Every component has one or more "functions" which when run read in the values on the input pins, and write new values to the output pins. Every function updates every time the realtime thread it is attached to runs. Typically the servo thread runs every millisecond, and the base thread (when there is one) very 25uS.
The functions run in the sequence in which they are added to the thread with "addf"
You connect pins together with "net" Or, in some older configs with "link**"
The net format requires a signal name (which you can choose freely) followed by zero or more "input" pins and zero or one "output" pins. i.e. every signal can only have one pin setting its value, but can pass a value to any number of other pins.
Translating a HAL net to electrical wiring might give
net red-wire mains-hot toaster kettle fridge router
And net red-wire mains-hot mains-neutral kettle would be bad, as two "output" pins (the mains hot and neutral) just got shorted together.

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

More
04 Jul 2012 03:31 #21545 by PCW
I assume you need the 7i64 online or the HAL pins won't be available...

Absolutely, if the 7I64 is not connected, none of its HAL pins will be there either

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

More
05 Jul 2012 02:14 #21594 by cmorley
Peter is the 7i64 on serial # 1 because the 7i77 isn't powered up?

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

More
05 Jul 2012 02:54 #21597 by BruceLayne
cmorley wrote:

Peter is the 7i64 on serial # 1 because the 7i77 isn't powered up?

The 7i77 is powered on, with a couple of LEDs lit. It's powered by the 5i25. The 7i64 however wasn't powered. It's already installed in the remote I/O panel behind the gantry, but it's not powered yet. It will be soon. The 5V and 24V split supply should be here in a day or two and I'll use it to power the 7i64, and we already have some high-flex cat 5 cable to run through the Igus track for the RS422 connection between the 7i77 and the 7i64.

I did 4.5 hours of internet based research on my problems that concluded with me starting this thread, just before heading out the door to work another two hours on The Beast. Based on my research, I had already concluded that part of my PNCconf problems might be the result of having the 7i77 powered but not having the 7i64 connected, yet trying to configure it. PNCconf would let me manually install it and configure it, but LinuxCNC produced the errors when I ran it. I tried a much simpler PNCconf configuration last night, with only the 7i77 and the encoders and PWM I needed for a four axis servo system. That produced apparently the same type of errors. I also get similar errors with any canned configurations that I tried to load into LinuxCNC. Simulation configurations continue to run OK.

I think I've played with the LinuxCNC installation and jinxed it up somehow. Maybe it's looking for files in all the wrong places. I pretty much concluded that I'm going to do yet another clean sweep reinstallation of LinuxCNC 2.5 from the LiveCD. I think this installation was a 2.4.x upgraded to 2.5. I already had a 2.5 ISO, but I'm downloading it again just to make sure I have the latest and greatest.

I did save the errors that were produced in Tuesday night's efforts, but I'll save you guys from that, given that I'll be starting from scratch again. If I run into the same problems with a fresh install and all of the MESA hardware connected and powered, I'll be back! If that fixes it, I'll post about that too. Hopefully this thread will help others like me, stumbling about in the wilderness. :)

Thank you all so very much for trying to help me. I know that's not easy across the internet, when the dufus making the posts is ignoring the obvious problem and is asking misleading questions. It's times like this that I feel like an old engineer. :(

If I don't have any luck with PNCconf soon, I think I'll jump into HAL and do the work needed to learn it. I'm sure I'll need that knowledge for more complicated stuff later, anyway.

I'm going to the basement shop to make the last two parts for my Hacron ORD Bot 3D printer. After that project, I'm going to get my Clausing CNC lathe running (more LinuxCNC and MESA!), and then I'm going to build a laser engraver and see if I can run it with LinuxCNC. By that time, I should be answering questions on this forum instead of asking them!

For those of you in the US... Happy Independence Day!

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

More
05 Jul 2012 03:12 #21598 by cmorley
apparently not I tested it the auxiliary board was always 0.2 hmmm

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

More
05 Jul 2012 03:17 #21599 by BruceLayne
andypugh wrote:

The one that is biting you now is that the 7i64 is on sserial port 0 channel 1. So it will be hm2_5i25.0.7i64.0.1.digin… whereas your HAL files referring to 7i63.0.2...

Something that you haven't noticed yet is that your 7i77 sserial components are not active either (the dmesg printout hasn't got a sserial TXdata0 and RxData0
This is probably because the field power isn't connected on the 7i77 board.

The first thing to do is to get a list of all the pins. The Mesa Smart Serial devices name the pins themselves and the actual names depend on which devices are plugged in to each port.

Open a terminal window and power up the 7i77 etc.
Then
:/$ halrun
halcmd: loadrt hostmot2
halcmd: loadrt hm2_pci
halcmd: show pin
haldmd: show param
.
..
.


I'm very tempted to try your recommendations before doing the clean sweep reinstallation. I may do that, for the educational value as much as fixing my immediate problem. However, I'm still bothered that the default servo configurations that would work with LinuxCNC now don't work. That would seem to indicate a problem with the installation (missing or overwritten files or something similar) that is in addition to my configuration woes.

At the very least, I made a copy of this thread and I'll give that a try if I have similar problems after reinstalling LinuxCNC.

I've been using a flash thumb drive to make backups of the LinuxCNC directory. I've also been making notes into a text file, and copying files that might help that I find on this site. It's possible that I overwrote something that LinuxCNC needs when copying files, After the reinstall, I'll be very careful to only back up the LinuxCNC directory, and I'll be very careful about what I copy into that directory, one file at a time.

I did about an hour's worth of the HAL lessons from the HAL manual, trying to learn HAL. That was about a month ago. I grok the powerful hardware abstraction layer concept, but I'm still weak on syntax. Before this is over, I'll be going to HAL school. I'll take an immersion approach next time. An hour every month or two doesn't make a lasting impression.

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

More
05 Jul 2012 03:24 #21600 by cmorley
If you are trying to use PNCconf from the live CD for the 5i25 you are going to get errors.
You need to get linuxcnc from the buildbot - it has bug fixes.
buildbot.linuxcnc.org/

You can hand edit configs for the 5i25 from the live cd but as you have found its a real steep hill.

I just tried the buildbot and it seems to be down right now...

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

Time to create page: 0.149 seconds
Powered by Kunena Forum