Spinx1 to 7i85

More
10 years 11 months ago #65791 by OT-CNC
Replied by OT-CNC on topic Spinx1 to 7i85
I'm editing the hal for my machine, and the splash screen keeps teasing me. It almost loads.
I know I'm not connecting things correctly.
It errors out around here:
net spindle-pos pid.1.feedback orient.0.position
net spindle-vel pid.0.feedback hm2_5i25.0.encoder.03.velocity

spindle.hal:37: Pin 'pid.0.feedback" does not exist
if I continue with #, next line errors out. What do I have to change?

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

More
10 years 11 months ago #65795 by OT-CNC
Replied by OT-CNC on topic Spinx1 to 7i85
actually, it errors out earlier:

loadrt pid num-chan=2

I bumped up the number of channels to 4 and no good.
The error is hal:13:exit value: 1
insmod for pid failed, returned -1

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

More
10 years 11 months ago #65804 by OT-CNC
Replied by OT-CNC on topic Spinx1 to 7i85
Okay, I attached the error log and my hal and ini files.
It's looking very messy. I didn't get very far today :(

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

More
10 years 11 months ago #65806 by andypugh
Replied by andypugh on topic Spinx1 to 7i85
Actually, you are really close...

The names=.... pid.0, pid.1 in the first HAL file is a clever way to make things work. All you need to do now is remove the loadrt pid from the spindle HAL file.

All instances of a component normally have to be loaded at the same time. There is a way round that using two-pass scanning.

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

More
10 years 11 months ago #65915 by OT-CNC
Replied by OT-CNC on topic Spinx1 to 7i85
Thanks Andy.
I got it to load but I lost the spindle enable somehow. I'm not getting any spindle motion yet.

Line 61 down in the latest spindle hal file things get messy. addf abs.0. servo- thread wasn't liked, so that is turned off. After that are the pwm components you helped me with earlier. That needs looking at as well.
Also I comented out all the simulated spindle components under line 55 in the lathe_v7hal. Do I need any of those turned on?

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

More
10 years 11 months ago #65917 by andypugh
Replied by andypugh on topic Spinx1 to 7i85
Odd that the addf didn't work. Is there really as space in "servo- thread" ? There shouldn't be.

As a general rule, commenting-out a HAL line just defers the problem. You need to work it out, not mask it.

One problem is that every instance of each module type needs to be loaded at the same time, which somewhat limiting. You often need to go back to an earlier-loading HAL file and add some extras.

There is the option to name each component instance and use two-pass processing. It's nice, if you start off that way.
linuxcnc.org/docs/2.7/html/hal/twopass.html

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

Moderators: PCW, jmelson
Time to create page: 0.210 seconds
Powered by Kunena Forum