RogerN wrote: > I got my filtered speed feedback working by copying and modifying parts > of nist lathe and sim lathe. Tonight I tried to add PID control to the > spindle and can't get it to run. I get this error - > > HAL: ERROR: bad position: 0 > > Here is what I added tonight (beside adding another PID loop (count=4) > and such to core servo.hal). > > #### Start of drive speed control > loadrt limit2 count=1 > addf limit2.0 servo-thread # Limit spindle rpm rate of change to 300 RPM
This is a head-scratcher. The error message is almost certainly coming from an "addf" command. "addf" allows you to optionally specify a position in the thread where you would like the function to be (1 = first function in the thread, 2 = 2nd function, -2 = 2nd from the end, etc.). That error message is issued if you try to set the position to zero, as in: addf limit2.0 servo-thread 0 Obviously you aren't doing that. I thought maybe the comment was being mishandled and turned into a "0" somehow, but I've tried here on both CVS head and version 2.1.7, and comments after an addf command are fine. What version are you running? Do you have any other addf commands in your file that end in zero? Try removing the comment after the addf command? Let me know what you find out. Regards, John Kasunich ------------------------------------------------------------------------- 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 [email protected] https://lists.sourceforge.net/lists/listinfo/emc-users
