On Thursday 15 September 2016 21:06:17 Gene Heskett wrote: > On Thursday 15 September 2016 10:44:08 Gene Heskett wrote: > > On Thursday 15 September 2016 06:57:27 andy pugh wrote: > > > On 15 September 2016 at 11:04, Gene Heskett <ghesk...@shentel.net> > > > > wrote: > > > > But, if I could 'net' the edge trigger parameters, > > > > > > You can't net parameters. You can only net pins. > > > http://linuxcnc.org/docs/2.7/html/man/man9/oneshot.9.html > > > Tells you which are which. > > > > Ok, then as soon as the coffee and my morning pills have kicked in, > > I'll go carve a bit on the hal file for TLM. > > Looking at the lut5 modules man page, where it claims all kinds of > functions can be performed, I am not grokking what it says. And the > link to lut5.py isn't helping as it gives me the exact same answer, > 0x2, regardless of what logic operator I put between the two input > pins. And what it says is not getting me what I want. What I want is > a true output for every input combo of 2 pins, based on > motion.spindle-on but delayed a hundred milliseconds as an enable of > its going false if the encoder output stops, indicated by frozen data > for .2 seconds. > > That will stop the retrigger oneshot. So it will go true or false > depending on the output wired in. > > The second input in-1, is fed from a timedelay module so that its > output is a time-delayed version of motion.spindle-on, delayed by how > long it takes the spindle to move past an edge of a slot plus a bit, > perhaps 250 milliseconds from the time motion.spindle-on went true. > > The best I can get, for about an hours playing with halshowconfig, and > setp is to get it to move the spindle about 10 degrees during the > timedelay, and shut it down because the spindle did move. > > Thanks for any enlightenment that is not in the manpage. > > Cheers, Gene Heskett
I just had a better idea Andy. Use the onehot to make a spindle-is-turning signal as now. Feed that into a mux2.in1 Use the timedelay to switch that mux2, feeding a logic one into in0, and the spindle-is-turning into in1. When the timedelay runs out, and spindle-is-turning is still false, bang the motion.enable down with the 0 out of the mux2 until the timedelay has been reset by motion.spindle-on going back false, putting the logic 1 back into motion.enable from the mux2.in0. However, a mux2 carries digital values & may not like a setp in0 True, and on looking thru what we have, maybe tristate_bit might be the better choice, copying a logic 0 from spindle-is-turning when it isn't, to motion.enable until the timedelay is reset by the machine being turned off I'll try that. And I found tristate_bit is not tristated when disabled. Testing now. Yup, its pulling motion.enable false when its enable is false. So the machine cannot be turned on at all. Thats a bug isn't it? Unless you've an even better idea of course. Obviously this doesn't work. Thanks Andy. Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) Genes Web page <http://geneslinuxbox.net:6309/gene> ------------------------------------------------------------------------------ _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users