1. Home
    1. Dashboard
    2. Search
  2. Forum
    1. Unresolved Threads
    2. Members
      1. Recent Activities
      2. Users Online
      3. Team Members
      4. Search Members
      5. Trophys
  3. Articles
  4. Blog
  5. Videos
  6. Jobs
  7. Shop
    1. Orders
  • Login or register
  • Search
This Thread
  • Everywhere
  • This Thread
  • This Forum
  • Articles
  • Pages
  • Forum
  • Blog Articles
  • Products
  • More Options
  1. Robotforum - Support and discussion community for industrial robots and cobots
  2. Forum
  3. Industrial Robot Support and Discussion Center
  4. ABB Robot Forum
Your browser does not support videos RoboDK Software for simulation and programming
Visit our Mainsponsor
IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Sponsored Ads

ABB error handler/Trap

  • samflower
  • April 22, 2023 at 6:53 AM
  • Thread is Unresolved
  • samflower
    Trophies
    1
    Posts
    1
    • April 22, 2023 at 6:53 AM
    • #1

    Hi all,

    I am currently working on a auto recovery program so that the operators don't have to manually recover the robot as many of them on site aren't trained to use these. As a result in this we are experiencing many crashes when they are attempting to recover weld faults.

    As a result of this i have tried to create my own error handler to automatically recover the robot in fault. I am using a semi static task to to monitor if the robot is welding and moving.

    MODULE mMain

    VAR clock clkR1_MOVE;

    VAR num nR1_Move;

    PROC MAIN()

    WHILE TRUE DO

    IF DOutput(do_MonitorStop)=1 THEN

    GOTO END;

    ENDIF

    ClkStop clkR1_MOVE;

    ClkReset clkR1_MOVE;

    WHILE DOutput(do_R1_Not_Moving)=1 AND DOutput(do_R1_Welding)=1 AND DOutput(doR1_AWError)=0 DO

    ClkStart clkR1_MOVE;

    nR1_Move:=ClkRead(clkR1_MOVE);

    IF DOutput(do_R1_Not_Moving)=1 AND DOutput(do_R1_Welding)=1 AND DOutput(doR1_AWError)=0 AND nR1_Move>3 THEN

    PulseDO\PLength:=1.5,do_R1_StopFault;

    ENDIF

    ENDWHILE

    WaitTime 0.05;

    ENDWHILE

    END:

    WaitTime 0.05;

    ENDPROC

    ENDMODULE

    Using this monitoring I am calling a trap routine to raise an error. Unfortunately this is where I am struggling as I am pretty much self taught using RAPID. I am trying to use the error code below to call the automatic recovery using a UI message box so the operator has to acknowledge the fault before it starts to move back through the program to the determined safe areas within the actual welding program.

    TRAP R1_Stop_Fault

    RAISE err_R1_Weld_Fault;

    ERROR

    IF ERRNO=err_R1_Weld_Fault THEN

    R1_Recover:=UIMessageBox(\Header:="R1 Automatic Recover to Safe Point"\MsgArray:=maint_msg1\BtnArray:=maint_btn1\Icon:=iconInfo);

    IF R1_Recover=1 then

    StorePath;

    PathRecMoveBwd\ID:=Safe1;

    Stop;

    RestoPath;

    StartMove;

    ENDIF

    ENDIF

    RETURN;

    ENDTRAP

    Any time I go to test this it either pops up with interrupt queue full and value error. Or it just skips this all together and calls ABB's generic arc supervision error.

    Any pointers in the right direction will be highly appreciated.

    Thanks

    Sam

  • HawkME April 22, 2023 at 10:08 AM

    Approved the thread.
  • ColoradoTaco
    Reactions Received
    16
    Trophies
    3
    Posts
    103
    • November 16, 2023 at 7:41 PM
    • #2

    Hey Sam!

    Just saw this, as I am looking into some error handling stuff too. I've been programming ABB robots for 10 years, and I still struggle with Traps, Interrupts, and Error Handlers.

    Did you ever get this working, and if so what was the solution?

    My initial thought is that you might need to book your error number so that the system will recognize it. If it's not a built in error for the base ware or a factory option, then you need to do the following...

    Code
    ! Introduce a new error number in a system
    ! The new error variable must be declared with initial value -1
    
    VAR errnum ERR_MYERROR := -1;
    
    ! Book the new RAPID system error number
    BookErrNo ERR_MYERROR;
    
    ! Use the new error number
    IF di1 = 0 THEN
        RAISE ERR_MYERROR;
    ENDIF
    Display More

    What I am currently doing is running a Power-On event routine that books all of my custom error numbers. I might be able to just run that routine at the top of MAIN, but event routine seemed like a more error-proof option.

Advertising from our partners

IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Advertise in Robotics
Advertise in Robotics

Job Postings

  • Anyware Robotics is hiring!

    yzhou377 February 23, 2025 at 4:54 AM
  • How to see your Job Posting (search or recruit) here in Robot-Forum.com

    Werner Hampel November 18, 2021 at 3:44 PM
Your browser does not support videos RoboDK Software for simulation and programming

Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • robodk
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Thread Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • robodk
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Similar Threads

  • Unloading & Saving recipe - No recipe defined

    • jplanera
    • January 6, 2023 at 2:56 PM
    • ABB Robot Forum
  • Creating RAPID error handler

    • bebop
    • August 7, 2021 at 12:19 AM
    • ABB Robot Forum
  • FirstMove, SMove, and ChkPosition -- What are they?

    • SkyeFire
    • August 26, 2019 at 10:30 PM
    • ABB Robot Forum

Tags

  • error handling
  • trap routine
  1. Privacy Policy
  2. Legal Notice
Powered by WoltLab Suite™
As a registered Member:
* You will see no Google advertising
* You can translate posts into your local language
* You can ask questions or help the community with your knowledge
* You can thank the authors for their help
* You can receive notifications of replies or new topics on request
* We do not sell your data - we promise

JOIN OUR GREAT ROBOTICS COMMUNITY.
Don’t have an account yet? Register yourself now and be a part of our community!
Register Yourself Lost Password
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on Google Play
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on the App Store
Download