Detect rising edge in RAPID
BigApe
✭
I come from the world of PLC programming, where rising and falling edge detection is crucial in a lot of programs, but I can't figure out how to make it work in ABB RAPID.
What I want to do, is change the function of a physical button to a switch, so that when the button is pressed, a bit is reversed ( 0 -> 1, 1 -> 0), and it makes the most sense to me do to that via rising edge detection.
Scenario:
We're using zero-point clamping modules on an IRBP B250, and to open and close the modules, we use airpressure which is controlled by the robot controller. For safety, we've installed a button thats supposed to turn the air on and off, releasing and locking the clamping modules.
What I want to do, is change the function of a physical button to a switch, so that when the button is pressed, a bit is reversed ( 0 -> 1, 1 -> 0), and it makes the most sense to me do to that via rising edge detection.
Scenario:
We're using zero-point clamping modules on an IRBP B250, and to open and close the modules, we use airpressure which is controlled by the robot controller. For safety, we've installed a button thats supposed to turn the air on and off, releasing and locking the clamping modules.
Tagged:
0
Comments
-
Hello BigApe,You could use an interrupt with ISignalDI to detect the rising edge and execute the necessary functionality in the associated TRAP routine. Since the interrupt is only executed when the program is running, you have to check if the detection is also necessary when the program is stopped and implement the detection of the rising edge by a separate semi-static task (multitasking).1
-
Micky said:Hello BigApe,You could use an interrupt with ISignalDI to detect the rising edge and execute the necessary functionality in the associated TRAP routine. Since the interrupt is only executed when the program is running, you have to check if the detection is also necessary when the program is stopped and implement the detection of the rising edge by a separate semi-static task (multitasking).
It'll be neccessary both while started and stopped, which is why I have already put the test code in its own task.0
Categories
- All Categories
- 5.5K RobotStudio
- 394 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 309 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 783 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings