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. Fanuc 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

Send active alarm to PLC

  • tomexx
  • May 17, 2017 at 6:12 PM
  • Thread is Resolved
  • tomexx
    Trophies
    4
    Posts
    66
    • May 17, 2017 at 6:12 PM
    • #1

    Hi,

    I need to be able to send active alarm to the PLC for data collection purposes.
    Is this possible?

    Thanks,
    Tom

  • cobenson
    Reactions Received
    10
    Trophies
    3
    Posts
    314
    • May 18, 2017 at 1:26 AM
    • #2

    More information would be helpful. Controller type, what kind of alarms? User alarms, robot alarms, robot warnings, messages, etc.

    We do this all the time and have been for a long time. So yes it is possible. Just depends how much money you want to spend. Nothing's free with Fanuc!

  • bidzej
    Reactions Received
    23
    Trophies
    4
    Posts
    592
    • May 18, 2017 at 7:17 AM
    • #3

    Could be done with a dedicated option called Error Code Output (or sth like that), or by accessing robot registers via SNPX, or by creating a small KAREL program to copy a fault code to a GO...

  • dewitm
    Reactions Received
    3
    Trophies
    3
    Posts
    99
    • May 18, 2017 at 10:47 AM
    • #4

    I know a free option which sends the error code to the PLC and is working.

    1. Do controlled start and set $TPP_MON.$GLOBAL_MT=2
    2. Function, Start Cold
    3. Make a condition monitor (for example cond_error)

    Quote

    1: WHEN UO[6:Fault]=ON+,CALL ERROR_OUTPUT ;
    2: WHEN UO[6:Fault]=OFF-,CALL ERROR_OUTPUT ;


    4. Menu, 0, Status, Type: Condition
    5. You see the screen "Program Monitor" now. Press F2 or 'System"
    6. As CH Program, select cond_error
    7. In the condition program, you called error_output, so make this program:

    Quote

    1: CALL ERROR_TO_REG(51) ;
    2: MONITOR COND_ERROR ;


    The number (51) is in my program, you can address whatever register you want (use an unused one :zwink:), you need 2 registers. So 51 and 52 in this case...
    8. Make a karel program:

    Quote

    PROGRAM error_to_reg
    %NOLOCKGROUP
    %NOPAUSE= COMMAND + TPENABLE + ERROR
    %NOBUSYLAMP
    %NOABORT = ERROR + COMMAND
    %COMMENT= 'ERROR SEND'

    VAR
    par_no,par_typ,par_int,int_reg:INTEGER
    par_real:REAL
    par_str:STRING[10]

    seq_num,error_code,cause_code,time_int,severity,STATUS :INTEGER
    error_string,cause_string,prog_nam:STRING[40]
    prog_stop:BOOLEAN

    BEGIN
    par_no=1
    GET_TPE_PRM(par_no,par_typ,par_int,par_real,par_str,STATUS)
    IF (par_typ=1) AND (STATUS=0)THEN
    int_reg=par_int
    ENDIF

    ERR_DATA(MAXINT, error_code, error_string, cause_code, cause_string, time_int,severity, prog_nam)
    SET_INT_REG( int_reg,error_code/1000,STATUS)
    SET_INT_REG( int_reg+1,error_code MOD 1000,STATUS)

    END error_to_reg

    Display More


    Load this program into the controller, make sure karel is accepted

    Cond_error monitors when alarm is true. If true, call program error_output.
    Error_output activates error_to_reg.

    Now you have 2 codes in R51 and R52. In your alarm manual the code is in 2 parts.
    For example R[51] = 11 and R[52] = 001, when you look it up, it is SRVO ESTOP

    To send it to the PLC, write R[51] and [52] to a GO....

  • tomexx
    Trophies
    4
    Posts
    66
    • May 19, 2017 at 9:44 PM
    • #5

    Thank you for suggestions, I will try them next week.

    Tom

  • Victortz88
    Trophies
    1
    Posts
    8
    • December 8, 2022 at 10:34 PM
    • #6

    I tried this dewitm but not sure if I am doing somethign wrong. My UALM do not get written to the register. Does this only work for the other alarms?

  • Sergei Troizky
    Reactions Received
    71
    Trophies
    6
    Posts
    664
    • December 13, 2022 at 5:10 AM
    • #7
    Quote from bidzej

    Could be done with a dedicated option called Error Code Output (or sth like that), or by accessing robot registers via SNPX, or by creating a small KAREL program to copy a fault code to a GO...

    "...or by accessing robot registers via SNPX, ..."

    Which registers?

    Do it well right away. It will become bad by itself.

  • Stefan Gimpl
    Trophies
    1
    Posts
    1
    • September 11, 2024 at 1:06 PM
    • #8

    The Karel-Program cant compiled:

    SET_INT_REG( int_reg,error_code/1000,STATUS) return a failure (data type error)

    Use SET_INT_REG( int_reg,error_code DIV 1000,STATUS) instead

  • cking8177
    Reactions Received
    11
    Trophies
    1
    Posts
    36
    • September 16, 2024 at 2:51 PM
    • #9

    Which PLC are you using?

    Is the robot communicating with the PLC via hardwired IO, EthernetIP, CC-Link, etc?

    Do you want all active alarms, or only the most recent alarm? (The one you would see on the message banner on the TP)

    If you are communicating with the PLC via EthernetIP, the PLC can read the most recent active alarm using explicit messaging. This would get you the fault code and fault description in a string variable.

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
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • 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
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000
  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