Home Programming


Left ArrowBack to discussions page
aliahmadaliahmad Posts: 2 Recruit
I am using two external buttons with the UR-10e robot. I want the robot to execute four tasks (probably with several If-Else statements?) alternatively but in a sequence e.g.
Input 1 = Task A
Input 1 = Task B
Input 2 = Task C
Input 2 = Task D
Can someone help to how to write the program? 


  • MarcAntoine_GauthierMarcAntoine_Gauthier Vacuum Beta tester Posts: 55 Crew
    Hello @aliahmad

    It all depends on what you are trying to do and what logic do you want.

    I have made an example below to show you one use case.

    In this program, I have a thread looking for the the buttons to be pressed. Once it is pressed, the Var_1 or 2 will be updated and these will be the variable that you will look for into your program to sort your task. 

    In this specific example, If you press on both button one after the other, you will enter into both "if" sequence. then at the end of the "if" sequence, the Var_X is set back to 0 waiting for the button to be pressed.

    Hope this helps. Let me know if you need further details.

Sign In or Register to comment.
Left ArrowBack to discussions page