Only United States small businesses are eligible to participate in the SBIR/STTR programs.
#Transfer rapid program outside robotstudio code
IDelete err_interrupt - The Interrupt is deleted as soon as this code is executed. What I'm doing wrong with joint out of range error?Ĭounter := counter + 1 A neverending counter?. I comment Path_10 in main and write:Īnd then the TRAP working fine. What is more it works for Division by zero error. ReadErrData err_data, err_domain, err_number, err_type įirst of all I want to simply set do1, when error occurs, but as I said it can't go into TRAP routine (do1 is still equals to 0). IError MOTION_ERR, TYPE_ERR, err_interrupt I made new normal type task with foreground task T_ROB1 (Motion task, only move instructions) where i wrote this code: I created RAPID code like SomeTekk wrote but my problem is that I can't get into TRAP routine. Your Main routine has no error handler in it. It is suggested to read about IError in a RAPID Instructions Tech Ref Manual. IF err_number=10 AND err_number=100 AND err_number999 THEN This is what has been done SIMILAR to what you are looking to do, I believe. ReadErrData err_data,err_domain,err_number,err_type IError MOTION_ERR,err_type,intErr_interrupt OR IError COMMON_ERR,err_type,intErr_interrupt WHILE DOutput(do_Eax_Err1)1 AND DOutput(do_Eax_Err2)1 DO To do so the concatenation used to construct the text string2 could be altered for that purpose. (A background task is used in this instance)Īlso, the error domain (for motion domain errors the domain number = 5) is NOT prepended to the text in the RAPID below! Maybe this error number is not stored in ERRNO variable ? Use the joystick to move the joint into its working range." Position for ROB_1 joint rob1_4 is out of working range. MoveL Target_120,v200,z200,AW_Gun\WObj:=wobj0 īut I see that ERRNO is 0 although Event Log shows me this Error: After "ERROR" instruction I write ERRNO to num type variable "ErrorNb" and then SETDO if this value is higher than 0. I tried to do this in simulation mode with "ERROR" instruction but It didn't work. The X-axis value of Target_30 is that Robot can't reach this point. I wanted to get "Position outside reach (50436)" error.
#Transfer rapid program outside robotstudio how to
Then I have to send this value to PLC via PROFINET.ġ) How can i read, that robot is in Error state - which variable from IRC5 controller give us this information?Ģ) How to read actual error number (Events List code) in every step of program ? I need to get a number of current robot error from IRC5 controller (like emergency stopped, axis error etc.) and write this value to integer type variable. I registered on this forum because I am beginner in Robot Studio and RAPID language and I have a question.