# Slow down move on the fly

I want to do a move to maximize the power available in the system. The axis will be position PID and I will have access to the actual force (via two pressure transducers) but I will not be controlling pressure/force.

The machine stretches metal and I want to slow down the velocity move “on the fly” as I watch the force rise. I will start at some maximum velocity that the system allows. As the pressure rises, there will be higher and higher power draw on the pump motor.

My initial thought was to issue over-riding move absolute commands but the help file recommends against issuing a rapid succession of move absolutes.

I seem to remember reading about something like this on the form before but searching did not find it.

Thanks,

I would use the I-PD command. You don’t need to change the gains when changing from Move Absolute to I-PD. You can change the velocity on the I-PD command in a tight loop with no problem.

Another method is to use force limit. You will need to set up a dual-loop axis, with the primary input being position and the secondary input being your force. The position motion will be limited as the force reaches it’s limit. For best results, you may need to run the first loop as a Velocity PID.

You can use the I-PD as Peter suggested. You can continuously send Move commands if you set the Requested Jerk axis parameter to zero.

Force limit requires tuning another PID.

Thanks, the customer always want’s to stay in position mode and only monitor force based on their experience with this process.

There is one problem I have had trying the I-PD and it’s because I failed to mention in my initial post that there are actually two axes slaved to a master doing this move. The metal that is being stretched can be up to 6 ft. wide so there are stretching cylinders on each side of the strip that need to be synchronized.

I get an error when I try to do a Move Absolute (I-PD) on the virtual axis…

With force limit, the axes are actually in position mode, the motion is just limited based on the force. This would actually be the same as the method you were originally thinking of, that the axis is in position control, and is limited by the force. I have found it easier many times to use the built-in force limiting rather than making my own algorithm, since it can be rather tricky to come up with and implement a good algorithm on my own.

It seems to work by issuing move velocity commands to virtual axis. …

Good! How are you adjusting the velocity as the force increases?

I’m calculating the maximum speed in a separate task like this.
The term 1090000.0/ForceCalc is pretty cryptic but basically keeps my power draw under 200HP. (Each axis has 2x16" diameter cylinders working together off one valve).

[code]// Calculate the total force
ForceCalc := (_Axis[0].ActFrc+_Axis[1].ActFrc);
// Calculate kips for display
TotalForce := ForceCalc/1000.0;

IF ForceCalc <> 0.0 THEN
IF ForceCalc > 0.0 THEN
// Calculate the new Speed
MaxSpeed := MIN(InitialSpeed, 1090000.0/ForceCalc);
END_IF
END_IF[/code]

Then in the main program I keep issuing a Move Velocity (37) with the velocity parameter as the MaxSpeed variable calculated above.

This is all still in simulation so it could need some revision from here. Also today the customer asked if we could pre-program the slow down and just watch the power draw and only limit further if we have to. The material properties are pretty well known so in that case I’d just build a curve and run the virtual axis off of it. It should work pretty well.

Edit I just noticed that I don’t need the IF ForceCalc <> 0 because the ForceCalc >0 will do that but I had the <>0 in first because I got a divide by zero error and then I put in the >0 check when the noise in the simulated force went negative and cause havoc on the system.

I am impressed!

I have seen requests like these before where people want to keep the power constant but the velocity and force can change depending on the resistance.

So given what I know know I would still use the I-PD and constantly change the velocity as a function of force and use that as virtual master. Two axes can then be synchronized to the virtual master. Easy.

What I don’t like about issuing MoveAbs Commands is that they expect the actuator to follow a target generator and this is not the case in this application.