Print

Ramp

Ramp is a background task. It only needs to be Started. Once Started, it will continue to operate in the background until Stopped.

The Ramp function changes a value from its initial value to a target value, at a defined rate of change. Optionally, a ramp can include a soft start and soft stop. A soft start ramps the rate of change up to the defined rate of change gradually, over the defined soft start/stop period. A soft stop ramps the rate of change from the defined rate to 0, over the defined soft start/stop period.

Ramp is commonly used for motion control. The vBuilder Stepper Motion function has its own ramp feature built in, so this Ramp function would not commonly be used for stepper motion control. It would be applicable to servo motion control, typically coupled with a high speed pulse counter input and PID.

Ramp is also applicable to other machine and process control applications. Any time you want to change a variable at a defined rate, Ramp can be used.

  • The top selection is for the Tag that you want to Ramp.
  • Next is the ramp rate in units per second of whatever unit the Ramp Tag is. The Ramp Rate is an absolute value. Whether it is a rate of increase or decrease depends on whether the Ramp Tag is above or below the target.
  • Next is the Ramp Target – the .final value of the Tag after ramping
  • Optionally, you can enter a Soft Start/Stop time. If you enter a Soft Start/Stop time the ramp rate will ramp up to the Ramp rate over the defined period and ramp down over the same defined period, when approaching the target. This will have the effect of rounding off the value curve, like that shown in the Ramp button graphic.

Stop

Ramp Stop will Stop the Ramp function. This is something that you would normally do, once the target value has been reached.

Select the Tag that is being ramped.

My Ramp doesn’t work

If we have a ramp to 100 with a start/stop time of 250 milliseconds is simply exceeding the ramp length that can be performed at that slow of a speed. The ramps use times and the function calculates time increments for the next step.  When you have a real long time and a small rate, the math gets to the point that no ramping will take place. The limit varies proportionally to the speed. A low value for speed can only have a short ramp.

 

Execute a task only once

 

Here, we will show how to have a state for execute a task only once, from top to bottom of the cycle, when the PLC boots.

This state will never run again until the next boot. Usually used to initialize variables.

  • SET a Coil in the beginning of your program
  • Use this BIT and the Rising edge contact