Bridgeport Torq-Cut TC4G Retrofit

More
5 years 7 months ago #203187 by chopper79
I gave the PID tuning a go and still having issues.

Set all values to 0 (excluding max output which is 100 as I figure 100rpm orientation is fine for now)

Using halshow I introduced P, I, D values and never arrived at a good spot. I set P to 1 and the spindle will rotate slowly to the orientation degree and stop. Added more P and the rotation is quicker, but when oriented the oscillation is greater as well. No matter how much P,I, or D is introduced the oscillation is there. If to much D the oscillation is less, but a heavy vibration is present.

Also inverted my spindle encoder just incase this was the issue and then the spindle never orients. It just rotates and never stops in position.

Wonder if the Yaskawa VFD's internal parameter constants are interfering with this process?

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

More
5 years 7 months ago #203215 by andypugh

chopper79 wrote: I set P to 1 and the spindle will rotate slowly to the orientation degree and stop. Added more P and the rotation is quicker, but when oriented the oscillation is greater as well.


Maybe the P needs to be less than 1?

If you increase P as far as you can without oscillation then add some I it will probably speed up. (but might then enter I-term oscillation).

I will never dampen oscillation if P is too high. D might, sometimes.

You could try the Zeigler-Nichols method

Increase P until you get oscillation.
Then set P to 0.45 times that value, and I to 0.8 times the oscillation frequency.

It might well be that the system can only orient slowly.

You might need some inverse-deadband if the VFD doesn't even come alive below a certain frequency (which is likely)
If I was doing this I would probably use the "lincurve" HAL component to map frequency requests below 2Hz to 0 and between 2Hz and 10Hz to 10Hz, then 1:1 above there.

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

More
5 years 7 months ago #203310 by chopper79
Still no luck..

I get oscillation with a P value of 0.0005 and all other PID values at 0 If I drop P to 0 then the spindle will rotate slowly on its own and never orient. This goes back to an issue I had a few posts back about when spindle is enabled it begins to rotate about 1 rpm. Not sure at this moment on how to do this orientation thing. I did try adding some I and inverse D with no luck at all

The orientation speed from the factory is about 300 rpm.

I will have to look at this lincurve you mentioned. Not familiar with it so need to research some more on it.

Just for the heck of it I triggered the orientation on the VFD and the spindle orients at 400 rpm and stops solid with no issues excluding the position is wrong and if I change gears it is wrong again. This is using the encoder on the spindle motor and not the load encoder on the spindle.

Well for now I will have to sit back and keep thinking about this issue.

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

More
5 years 7 months ago #203327 by andypugh
Does the encoder on the motor use an index?

What kind of motor is it? If you are using a VFD then presumably an induction motor? What dies it use the encoder for?

I wonder what would happen if you wired the spindle encoder to the VFD in place of the motor encoder?

Can you show us _all_ the pins/params of your spindle PID? I wonder if you have a max_output getting in the way.

Does it actually matter if the spindle oscillates? Could you simply disable the PID once the spindle is oriented?

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

More
5 years 7 months ago - 5 years 7 months ago #203332 by chopper79
The motor encoder does use an index and yes it is an induction motor.

Motor = Yaskawa UAASKA-06DBM12
VFD = Yaskawa 626vm3c

This is a match set and when the VFD is installed you must enter the motor code. From this point the VFD manages different parameters and the encoder on the motor lets the VFD know how it is performing. Adjustments are made on the fly in the VFD based on the encoder and the high voltage wiring monitoring. Well according to Yaskawa anyway...

I thought about connecting the spindle encoder to the VFD and not the motor, but Yaskawa stated that due to the above the motor and VFD would not perform correctly. They said that the DX32 controller used a PID to orient the spindle. Basically just like I am attempting in LCNC.

I thought about disabling the PID once oriented, but if the spindle rotates a little then the drive dog will not line up with the notch in the tool holder. (To much potential for error personally)

The oscillation may not matter at all but I figure that it should not be there as the original control was able to handle it so LCNC should be able to as well. Just do not know the OEMS magic sauce for it yet.

Attached is my HAL and INI file that I am using for testing the PID. Also note that even though the HAL has dual PID (Low and High gear) the same results happen with even a single PID for orient. Also attempted multiple different configurations of the pin/signal and keep coming up with the same results. I may have something basic messing me up on this so please by all means have a look.

Thank you

**** Focus on the area that is ###### TEST ####### This is my testing area so I do not have random stuff everywhere in the HAL. ****

If anyone attempts to use this HAL and INI file. I caution you that it is not complete has work still to be done on it. This is just the current spot I am at in the progress of getting the controls set up.
Last edit: 5 years 7 months ago by chopper79.

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

More
5 years 7 months ago #203337 by PCW

I get oscillation with a P value of 0.0005


I don't really understand this as a P value of 0.0005 would result in a correction velocity
of only .00025 RPM when 1/2 turn out of position (assuming the velocity command is scaled in RPM)

Because of the step in position during orient (and the slow response of VFDs) it might be worth a try
to use an exponential motion by setting P proportional to the absolute error. This is helpful in eliminating
small oscillations as the gain is near 0 once in place. Bounding the PID error might help as well
The following user(s) said Thank You: chopper79

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

Time to create page: 0.390 seconds
Powered by Kunena Forum