[Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Matthew Herd
Hi All, I’m sure there’s a simple answer for my question, but I haven’t been able to figure it out. Currently the configuration for the spindle forward and reverse outputs is as follows: # connect spindle fwd/rev to I/O controller net SpindleFwd <= ppmc.2.dout.00.out net SpindleFwd => spindle.

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread John Figie
I think a multiplexer will do what you want. http://linuxcnc.org/docs/2.8/html/man/man9/mux2.9.html On Sat, Dec 12, 2020, 8:15 AM Matthew Herd wrote: > Hi All, > > I’m sure there’s a simple answer for my question, but I haven’t been able > to figure it out. Currently the configuration for the

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread andy pugh
On Sat, 12 Dec 2020 at 14:15, Matthew Herd wrote: > I would like to selectively reverse direction depending on whether a backgear > input switch is triggered. I see there is a gearchange component but I’m not > clear on how to utilize it. Does the gearchange component translate to the > pin

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread andy pugh
On Sat, 12 Dec 2020 at 14:47, John Figie wrote: > > I think a multiplexer will do what you want. > http://linuxcnc.org/docs/2.8/html/man/man9/mux2.9.html mux2 only multiplexes floats. See my reply for how to use mux_generic to make bitwise muxes. -- atp "A motorcycle is a bicycle with a pandemo

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Gene Heskett
On Saturday 12 December 2020 09:12:47 Matthew Herd wrote: > Hi All, > > I’m sure there’s a simple answer for my question, but I haven’t been > able to figure it out. Currently the configuration for the spindle > forward and reverse outputs is as follows: > > # connect spindle fwd/rev to I/O contr

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Gene Heskett
On Saturday 12 December 2020 09:53:33 andy pugh wrote: > On Sat, 12 Dec 2020 at 14:47, John Figie wrote: > > I think a multiplexer will do what you want. > > http://linuxcnc.org/docs/2.8/html/man/man9/mux2.9.html > > mux2 only multiplexes floats. See my reply for how to use mux_generic > to make

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Jon Elson
On 12/12/2020 08:12 AM, Matthew Herd wrote: Hi All, I’m sure there’s a simple answer for my question, but I haven’t been able to figure it out. Currently the configuration for the spindle forward and reverse outputs is as follows: # connect spindle fwd/rev to I/O controller net SpindleFwd <=

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Matthew Herd
Thanks all for the answers on this. Andy, I’ll give your and Jon’s solutions some thought and try one of them. Thank you! Gene, it’s a Bridgeport BOSS 5, which is a factory CNC knee mill heavily based on the standard Series 1. The head is virtually identical to a manual Series 1 machine exce

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Jon Elson
On 12/12/2020 08:12 PM, Matthew Herd wrote: Jon, I have two USC boards on the same parallel port. I think there is a bit of a clarity issue in the documentation here: http://www.linuxcnc.org/docs/html/drivers/pico-ppmc.html . The loa

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Gene Heskett
On Saturday 12 December 2020 21:12:08 Matthew Herd wrote: > Thanks all for the answers on this. > > Andy, I’ll give your and Jon’s solutions some thought and try one of > them. Thank you! > > Gene, it’s a Bridgeport BOSS 5, which is a factory CNC knee mill > heavily based on the standard Series 1

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-12 Thread Jon Elson
On 12/12/2020 08:12 PM, Matthew Herd wrote: Which raises the question of how the inputs and outputs will be enumerated for the second board. Will the second board inputs enumerate as ppmc.00.din.16.in through ppmc.din.31.in and the outputs as ppmc.00.dout.08.out through ppmc.00.dout.15.out

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Matthew Herd
I’ve had a chance to do some reading. In particular, I’ve been contemplating Jon’s approach and the spindle component. The manual is very interesting because the spindle component seems to include most of the functionality I need. I was wondering if anyone has an example where they utilize th

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread andy pugh
On Mon, 14 Dec 2020 at 15:06, Matthew Herd wrote: > I’ve had a chance to do some reading. In particular, I’ve been contemplating > Jon’s approach and the spindle component. The manual is very interesting > because the spindle component seems to include most of the functionality I > need. I

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Jon Elson
On 12/14/2020 09:03 AM, Matthew Herd wrote: I’ve had a chance to do some reading. In particular, I’ve been contemplating Jon’s approach and the spindle component. The manual is very interesting because the spindle component seems to include most of the functionality I need. I was wondering

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread andy pugh
On Mon, 14 Dec 2020 at 16:15, Jon Elson wrote: > Well, interesting. Now, where does spindle come from? In > my configs, I have signals like : > spindle.0.forward > and > spindle.0.speed-out > > But, there is no loadrt spindle command anywhere. This is rather unfortunate, and I am trying to dec

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Matthew Herd
Thanks Andy, I’ll play with HAL today and see what happens. Jon, you’re using the motion pins (spindle.0.x) while the "Spindle" component also has the same naming format and some of the same names. It took me awhile to sort it out. See this forum thread for clarification: https://forum.l

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Jon Elson
On 12/14/2020 10:19 AM, andy pugh wrote: On Mon, 14 Dec 2020 at 16:15, Jon Elson wrote: Well, interesting. Now, where does spindle come from? In my configs, I have signals like : spindle.0.forward and spindle.0.speed-out But, there is no loadrt spindle command anywhere. This is rather unfo

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Jon Elson
On 12/14/2020 10:37 AM, Matthew Herd wrote: Thanks Andy, I’ll play with HAL today and see what happens. Jon, you’re using the motion pins (spindle.0.x) while the "Spindle" component also has the same naming format and some of the same names. It took me awhile to sort it out. Depends on th

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread andy pugh
On Mon, 14 Dec 2020 at 17:10, Jon Elson wrote: > So, does every configs file set now need to loadrt spindle? No, the (normal) spindle pins are created when you loadrt motmod. But they have changed names. The conversion script should change the pin names in most circumstances. -- atp "A motorc

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-14 Thread Matthew Herd
I’ve spent some time playing with the spindle component. It seems to have a number of bugs, beyond the issue with the documentation. Somehow a negative speed command multiplied by a negative gear ratio yields a negative speed. And the forward and reverse pins track the commanded speed, not th

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread andy pugh
On Tue, 15 Dec 2020 at 01:42, Matthew Herd wrote: > > I’ve spent some time playing with the spindle component. It seems to have a > number of bugs, beyond the issue with the documentation. Somehow a negative > speed command multiplied by a negative gear ratio yields a negative speed. > And t

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread Matthew Herd
Hi Andy, I might take a look at modifying the component. I’m comfortable with C, so perhaps I can work it out pretty quickly. I do like the spindle component’s concept, but it seems there are some issues. Nonetheless, fixing those issues might be a bigger project than I can handle when the p

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread andy pugh
On Tue, 15 Dec 2020 at 11:47, Matthew Herd wrote: > I might take a look at modifying the component. I’m comfortable with C, so > perhaps I can work it out pretty quickly. .comp is C with some headers to create HAL pins. You should be able to just edit the gearchange.comp file (probably best t

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread Matthew Herd
Thanks again Andy, you answered my next questions. One final question. I see gearchange was rewritten but then the rewrite wasn’t put into the final release. I was studying the code revisions, which appear to solve some of my issues. Is this something that needs bug fixes and testing that ju

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread andy pugh
On Tue, 15 Dec 2020 at 13:47, Matthew Herd wrote: > > I see gearchange was rewritten but then the rewrite wasn’t put into the final > release. Where are you looking? -- atp "A motorcycle is a bicycle with a pandemonium attachment and is designed for the especial use of mechanical geniuses, dar

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread Matthew Herd
https://github.com/LinuxCNC/linuxcnc/commit/0b113e98a1621d3e8aa6467eb535b514f0da3d5b#diff-667b45662b7da3b4712ad1ead290305621b11f4d0e9569f095879d1c9eff5525

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread andy pugh
On Tue, 15 Dec 2020 at 13:57, Matthew Herd wrote: > > https://github.com/LinuxCNC/linuxcnc/commit/0b113e98a1621d3e8aa6467eb535b514f0da3d5b#diff-667b45662b7da3b4712ad1ead290305621b11f4d0e9569f095879d1c9eff5525 > >

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread Matthew Herd
Ahh, very interesting. For the time being I’ll work on my own component and see what I find. Thanks Andy! > On Dec 15, 2020, at 9:12 AM, andy pugh wrote: > > On Tue, 15 Dec 2020 at 13:57, Matthew Herd wrote: >> >> https://github.com/LinuxCNC/linuxcnc/commit/0b113e98a1621d3e8aa6467eb535b514f

Re: [Emc-users] Question Regarding Selective Assignments in HAL

2020-12-15 Thread Matthew Herd
Also, after analyzing the code a bit further, it seems gearchange also has an error. The scale value (for gear 2, the "high" gear) is used to divide the speed in. This means that gear 2 is a lower gear, not a higher gear as the documentation indicates. I.e. gear 2 would be divided by the back