Avoiding temporary world zones reset.

Kami
Kami
edited October 2019 in RAPID Programming
Hello,
I am in a situation that I have to set up and free different temporary world zones dynamically.
I am encountering a problem that the temporary world zones are automatically erased after pptomain or pp leaves the routine where the world zones are set.
Is there a method that can keep those temporary world zones activated until they are freed?
Thanks

Best Answers

Answers

  • lemster68
    lemster68 United States ✭✭✭
    Why not use stationary then?
    Lee Justice
  • soup
    soup USA ✭✭✭
    You can enable and disable from a background task -- might help with having more control -- mentioned in the Rapid manual under wztemporary.
  • Hi @lemster68
    Thank you for your suggestion. However, I need to free and reactivate world zones when needed, but I can not free a stationary one. Is there way I can modify a stationary wz after it is activated?
  • Hi, @soup
    Thank you for your suggestion.
    I forgot to mention that the reason I need to activate and deactivate world zones because the maximum number of world zones is 20 and I need more.
    So I have to modify and redefine and  them according to TCP.

  • If anyone knows a way to detect pptomain event, I can then call my redefine procedure to solve this problem.
  • graemepaulin
    graemepaulin New Zealand mod
    If you  use a WHILE loop in the main routine you can call your world zone routine above this - thus only run when PP to main.
  • graemepaulin,
    That will work nicely when I run the program, but if the operator pressed pp to main without running the program, and then use jogging mode, the world zones are not activated, so there comes the risk. 
  • graemepaulin
    graemepaulin New Zealand mod
    So if program is not running and PP to main pressed the world zones are still reset?
  • @graemepaulin
    Yep, It happens to me, at least on a virtual robot. I have not tried it on a real robot yet. My Robotstudio version is 6.08.
  • lemster68
    lemster68 United States ✭✭✭
    Kami said:
    Hi, @soup
    Thank you for your suggestion.
    I forgot to mention that the reason I need to activate and deactivate world zones because the maximum number of world zones is 20 and I need more.
    So I have to modify and redefine and  them according to TCP.

    With IRC5, there is a function PPMovedInManMode that you can use.  You might also be able to use an UNDO handler in your routines.  Both might still not help, because I don't know which will happen first.  If the last thing that the controller decides to do is to delete the world zones, then you are boned.
    So if program is not running and PP to main pressed the world zones are still reset?
    @graemepaulin

        Yes, it is documented that this will occur.  I think that I remember you addressing the number of WZ's before with someone else.  Despite the documentation saying 20, it is actually 40?
    Lee Justice
  • lemster68
    lemster68 United States ✭✭✭
    One other thing that you can try is the function IsStopStateEvent(\PPToMain), if you have not already come across that one yet.
    Lee Justice
  • soup
    soup USA ✭✭✭
    Something to test: if you WZEnable from the background task, does PPtoMain in the motion task reset the zones?
  • soup
    soup USA ✭✭✭
    @lemster68 That's a good thought, but wouldn't protect on a PPtoMain then a manual jog.
  • @soup @lemster68
    Thank you guys.
    I had tried setting up more than 20 world zones. And the program stopped on the 21st one.
    I will take WZEnable from the background task as a final try I guess
  • Thank you very much. @soup @lemster68 
    The reason I need this is that my project is like carrying books into a grid like shelf. The project requires unprofessional operators to jog the robot. 
    And the ABB robot(760) is a four axis robot which does not support collision avoidance. So, I was trying to set up world zones only that are close to TCP.
  • EricH
    EricH Germany
    This is maybe a bit off topic, but: How can you avoid the reset of a stationary worldzone signal after a restart? Cross connect?
  • @EricH
    I use a PowerON event routine to set up my stationary worldzones, so the stationary worldzones are active all the time.

  • EricH
    EricH Germany
    Yes, I also do that, but after a power loss and restart, you need to set motors on for once to initialize the stationary worldzone. I would like to initialize without motors on.
  • lemster68
    lemster68 United States ✭✭✭
    You could maybe set the IO configuration state to store.
    Lee Justice
  • EricH
    EricH Germany
    I tried a custom signal safe level with all options to "set last value", but it's not working.