RobotStudio event

IRC5 service time information on HMI

Hello to all, I know that IRC5 has service routine that will show you number of working hours and service interval, is there a way that I can send present status of those counters (number of working hours) to PLC. Thanks.

Comments

  • VAR string mystring;

    mystring:=GetServiceInfo(ROB_1 \DutyTimeCnt);

    TPWrite "DutyTimeCnt for ROB_1: " + mystring;


    Then just convert string to number with StrToVal

  • Thanks for your suggestion Dmitry, once I got numeric value from string, what would be most easy way to send this value to PLC, maybe through group output?
  • Yes, define a group output at least 16 bits long. 16 bits will have maximum value of 65535 hours. If you think that robot will work more than that, then define 32 bits signal, that will definitely be more than our civilization life (490293 years) :smiley:
    Once you define GO, for example goPLC_RobotDutyCounter, then define UINT or WORD in PLC (for 16 bits), or UDINT or DWORD (for 32 bits).
    Send a value to PLC using SetGO instruction:
    nDutyTime := StrToVal(...);
    SetGO goPLC_RobotDutyCounter, nDutyTime;

    If your PLC uses different byte order than robot, you may need to swap bytes. You will see it if your value in robot and PLC differ by 256 times (2^8). You can do this by changing definition "Device mapping" for GO signal. For example if you had "0-15", you change it to "8-15,0-7".
  • Helo..I want to transfer from PLC to robot via prifinet number like 99999 (more than 16bit). How to make GI mapping? (0-31)?? On some manual I read that the GI support max 23bits.
  • According to System Parameters manual, you can map max. 32bit as a group input. Following is from the manual. "Group signals must be mapped between 1 and 32 bits."