In case anyone else has one of these PCB mills with the solenoid driven floating Z, I thought I would share my configuration changes. The premise I worked with was that if I could take the commanded Z position and convert it to a bit output to my solenoid relay I could use the standard drill and move codes with it. So I connected the Zpos-cmd and a constant "0" to a comparator and then routed that to the par-port. Now any commanded Z position 0 or greater results in the head up and any Z command less than 0 puts the head down. Here is what I did, let me know if it could use any adjustments, I am new to this hal thing.
In stepper_inch.ini I added a line for my new hal file:
HALFILE= solenoid_Z.hal
My new hal file solenoid_Z.hal contains:
loadrt blocks constant=1 comp=1
constant.0.value=0
newsig constcomp float
linksp constcomp comp.0.in1
linksp Zpos-cmd comp0.in0
newsig discrete_Z bit
linksp discrete_Z comp.0.out
linksp discrete_Z parport.0.pin-07-out
addf constant.0 servo-thread
addf comp.0 servo-thread
That's it. After a few syntax problems it worked. I am quite happy.
Have fun,
Tony
------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users