Problem with interrupts and multitasking

Hello to all. I'm trying to solve problem buyer is complaining about. Basically if robot gets stuck on part pickup or drop off position they would like to have some kind of auto recovery, to send robot home from this position if it's possible once gripper is opened, and start new cycle on a push of one button. I was thinking to create zones in pick and drop position and trap routine that would send robot home if it is in zone area and external homing input is received. But I'm confused with this trap algorithm. In manual it says interrupt will be applied only when program execution is stopped. So I made system input cross-connection to test this in RobotStudio. Once I stop program with this system input and than invoke interrupt I got error "Interrupt removed from queue-program has been stopped". So I don't get it, first I need to have program stopped to activate interrupt and then interrupt is asking for program running state? Where I'm wrong, I tried to put interrupt in second task but then I'm getting error that my interrupt output is controlling robot motion and this is not allowed. Thanks a lot in advance for your input. 

Comments

  • lemster68
    lemster68 United States ✭✭✭
    The system input for interrupt is kind of newer.  It will do things when the program is stopped.  The other type of interrupt has been around forever.  It requires the program to be running.  This type will be appropriate for your background task.  I did something similar years ago to what you are asking.  If you pm me your e-mail address I can send you a backup.
    Lee Justice