Spindle control woes

More
06 Dec 2018 10:47 #121941 by andypugh
Replied by andypugh on topic Spindle control woes
I wonder if you should have
setp hm2_7i76e.0.7i76.0.0.spinout-minlim 0

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

More
06 Dec 2018 12:21 - 06 Dec 2018 12:22 #121946 by Nitram
Replied by Nitram on topic Spindle control woes
I did try that Andy but setting minlim to 0 did not allow an M4 (i.e. CCW or minus) commanded spindle speed i.e. -400 (being S400 M4).
It seems the first command spindle speed sign permanently sets the direction (direction pin). Thereafter as the pid loop commands variations with ref to the feedback speed the numbers need to stay in absolute terms to comply with the pseudo potentiometer pin (DAC) of the 7i76e spindle output. i.e. a pot can only output a positive voltage. A negative command is outside the realms of what it can command. IOW if the PID loop commands a -20 value to reign in an M3 over speed the pot cannot issue a minus voltage command to comply. The best it can do is issue a 0 voltage command to temporarily slow the spindle.
In my case assigning abs figures to feedback and pid commands resolved this and stopped divergent behavior.
Last edit: 06 Dec 2018 12:22 by Nitram.

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

More
06 Dec 2018 13:01 #121948 by andypugh
Replied by andypugh on topic Spindle control woes
Are you using the dedicated Mesa direction pin? I agree that won't work if you disallow negative analogout

But it you use absolute spindle speed, single sided analogout and operate the VFD direction inputs using GPIO (motion.spindle-reverse) then I think it will work.

Maybe I am missing something, but what you now have still seems to allow negative PID outputs?

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

More
07 Dec 2018 00:15 #121990 by Nitram
Replied by Nitram on topic Spindle control woes
Yes conceivably the pid output could be negative if it is trying to drag down an overspeed with a big correction.
Before I made the abs change to the pid feedback pin I would always get a runaway from an M4, so it is behaving better with that change. But after getting the desired results I didnt investigate further.
I will recheck via Halwatch and see what data I get.

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

Time to create page: 0.129 seconds
Powered by Kunena Forum