Home Robot Safety


Left ArrowBack to discussions page
Tim_SmithTim_Smith Posts: 38 Apprentice
edited October 2016 in Robot Safety
Hi DoF Community,

I am working on a project using Universal Robots, and the customer is very worried about safety. In this case, the customer is worried about the robot having to hit someone for it to stop. So I proposed using a light curtain or an area scanner to slow down the robot when a person comes within 3 meters and have the robot stop when someone is within 1 meter of the robot. Has anyone used a light curtain or an area scanner for increased safety on a Universal Robots cell? How easily can I interface the light curtain with the robot's controller? How can I communicate with the robot when the light curtain's signal is triggered?



  • BeachChEBeachChE Founding Pro Posts: 19 Handy

    I have used a light curtain to slow down a UR3. The output of the light curtain is an input to the robot. Then using that input as a trigger for a thread to slow the UR3 down from 100% to 10%. You can do the same thing with a safety mat or a safety scanner.
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    You can also have these input directly into the safety controller using the configurable inputs, then you can use reduced mode and set lower speeds, forces, moments, etc that are activated when the safety system is active.  You can also plug directly into the safety system and have the robot physically stop moving when the safety system is active and then resume as soon as the signal is returned to normal.  We have used this with safety mats to stop motion while someone is walking through the area and then automatically return to work once they have passed through.

    To do the auto stop/start you just wire the safety output into the safeguard stop of the controller

    If you want to use the thread route realize that this is technically not safety rated as there is no redundancy to the method and there is no guarantee that it would work every time unlike using the safety controller built in to the robot.   You will need to call the speed slider using a TCP socket but here is the instruction on how to do that.
  • Tim_SmithTim_Smith Posts: 38 Apprentice
    @BeachChE Thanks for the information. The light curtain's output would be interfaced to a digital input on the UR's controller?

    @matthewd92 Thanks for mentioning the option of using the safety controller. I hadn't thought of this option, and the fact that this option covers the redundancy is really great! So in my program I will have to monitor both the rising edge and the falling edge of the light curtain's. Could you share a snippet of code that explains how to use the logic signal from the light curtain or the safety mat to change the robot's speed?

    Thanks a lot for the information!
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    @Tim_Smith you won't have to monitor anything, it will handle it for you if you use the safety controller.  If you use the safeguard stop the robot will pause movement whenever the safety system is breached, someone breaks a light curtain or steps on a mat.  If you use the configurable inputs you will need to tell the system what function you want it to have such as reduced power mode.  Either way, the system will handle the functionality for you.

    If you want to use the speed slider you would just have an event running that is looking for the digital input to change (either go low or high depending on if you are using the NC or NO output of the light curtain).  Once it changed you would send to the local host at port 29999 the speed slider percentage that you want it set at.

    Something like this:
        Event input=True #Set the speed slow
            socket_send_string("set speed")

        Event input=False #Set the speed back to normal
            socket_send_string("set speed")
  • BeachChEBeachChE Founding Pro Posts: 19 Handy
    Tim, Matthew is right that using the safety loop is better in that it will stop all motion, But I choose to slow down everything instead of stopping it. Here is the code that I use in a thread.

         ok≔socket_open("", 30002)
         speed_low≔0.03 (equals 3% on the slider)
         speed_high≔1.0  (equals 100% on the slider)
           If LightCurtain≟ False   (LightCurtain is the name of my Input)
           socket_send_string("set speed")
           Wait btnState≠LightCurtain

    As you can see in the last two statements, I set "btnState:=LightCurtain", then the wait statement holds the speed until the wait state is not equal to LightCurtain. Basically, while the input is on, the thread waits at the last statement.
    This works great if you want to have a two stage process, first slowing down the robot say at the 3 meters away, then go the safety circuit at 1 meter. We use the safety circuit with safety mats on some of our robots, not because of the robot, but because we are running a small press being fed by the robot. I choose the speed control because I am driving screws and a complete stop causes problems. Whereas the slow down is still fast enough to drive the screw most of the way into the part.
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    @BeachChE have you tried just using the reduced mode with the safety curtain?  My understanding is you would be able to accomplish the same result by just reducing the allowable speed in the reduced mode.  I like what you have done there, my only concern is if its for true safety where someone could get hurt and therefore part of the Risk Assesment what would OSHA say about this approach since its not safety rated technically.  I know we had them in a while back on a different issue than the robot but they were very interested in how we doing safety and making sure that we were using safety rated parts in the safety circuit.
  • BeachChEBeachChE Founding Pro Posts: 19 Handy
    Matthew, since in mu application, safety wasn't the issue (gap was small enough). The issue was moving at speed in a small area was the issue. Slowing down while an object was desired to reduce the chance of having a finer or hand pinched. We have had a couple of hands pinched at speed, but the robot did it's job and not harm was done to the hands. This particular robot works in a small area, less than 50 square inches.
  • SebastienSebastien Posts: 219 Handy
    We recently tested some light curtains for a client. So we decided to try the reduce mode of the UR. The setup was so easy. The light curtains that the client had were Reer Light Curtains. They have a way that you can wire them out such that they are in AUTO RESET mode. This is what we used in the video below. Then we hooked up the light curtains output to inputs of a safety relay. We then wired the output of the safety relays to the safety inputs of the UR controller. Then in the SAFETY setting of the UR we simply assigned the values of the plugged inputs to reduced mode. So in the video you see the robot going at roughly 3000mm/s and then switching to about 450mm/s when the operator moves his arms across the curtains. 

  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    @Sebastien could you have bypassed the safety relay and wired directly into the safety controller of the robot?  The only light curtains we have done were used to prevent a machine from being turned on by the robot if anything was breaking the beam so we used a safety relay to go into the machine.  We are about to deploy laser area scanners on a project and will post up some video once that is done.
  • SebastienSebastien Posts: 219 Handy
    I believe we could have bypassed our safety relay. However the light curtains are not the only safety devices in the robot cell. The way we manage our safety for E-stop and fences are through loops that if are open when a Estop or fence is open. Our light curtains are giving 0 or 24VDC depending on the state (broken or not) they are in. So to fit this in our usual loop we kept the relay.

    Does that make sense?

  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    Yep, our application with mats uses a mat controller which converts the mats into a safety relay which we then pull into the safeguard stop on the robot so that motion pauses when someone steps on the mat and resumes as soon as they are off the mat.

  • Tyler_BerrymanTyler_Berryman Posts: 122 Handy
    @Sebastien Nice video! What kind of accelerations did you use in both the reduced mode and the normal mode to get such a smooth transition? I used a safety scanner in the past and had trouble getting a smooth transition.

    Tyler Berryman
    Robotiq Integration Coach
    [email protected]
    1-418-380-2788, option 3
  • SebastienSebastien Posts: 219 Handy
    here is a picture for the values setup in the safety parameters. I did not save the program but my points in the program where linear points with 10mm blend radius, speed of 3000mm/s and accel of 2000mm/s2.

  • tiago_costatiago_costa Posts: 4 Apprentice
    Hi there. We have a similar situation in our application. We have a light courtain (OMRON) and a 2D laser scanner (SICK). However, we cannot put it to work correctly. We have the light courtain connected in safeguard stop and the laser scanner in config input with a reduced mode activation. Like this, the program is constantly pausing and resuming by itself by no reason. If we connect the light courtain to a config In or a digital In this won't happen. I have tried the speed slider that you mention earlier but we have a huge gap between the crossing of the barrier and the slowing down of the UR5 (aprox. 3 seconds). The laser scanner works fine but the risk assement that was made, defines that both safety devices should stop complete activity of the robot and not slowing it down. Is there a way to put both devices has a safeguard stop?

    Thank you very much.
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    You will either need to use a separate safety controller, we use the Banner XS26DE system, or use safety relays. You would need two relays. You would wire the A channel from both into one relay, B channel from both into the other relay. Then wire one output from each relay to the safeguard circuit. We have had to do this in the past before we started using the safety controller.

    We are actually in the process of switching to a Siemens S7-1200F PLC as it gives us the ability to control the safety systems as well as gives us a PLC and access to Profinet for expansion IO which is way faster than modbus IO expansion. 
  • fabefabe Posts: 4 Apprentice
    ...or use safety relays. You would need two relays. You would wire the A channel from both into one relay, B channel from both into the other relay. Then wire one output from each relay to the safeguard circuit...
    Hello Matthew, I should connect two light curtains and thee RFID-door-switches to an UR5e. Each safety device should be connected to an safeguard input. My mistake was, that I thought that I can configure the safety inputs of the controller as safeguard-stop inputs.

    Have you an little schematic of the relay connections? I don't understand your explanation.

    Thanks a lot, Fabian
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    With that much safety items I would recommend that you use a separate safety controller as it will take an extremely large number of relays to get that all combined down to 1 input.  We use the Banner XS26 system as our safety controller of choice.  They are extremely powerful but very easy to setup with intuitive drag and drop type functionality for setting up your safety logic.  We even do a lot of communication between the controller and robot over modbus so we can mute certain sensors for instance when the robot is not in that area and its safe for the human to be in that area and the robot thereby knows someone is there and not to enter the area until they vacate the area.

    This will by far be the easiest and safest way to connect more than 1 or 2 items to a UR controller.
  • fabefabe Posts: 4 Apprentice
    Wow, thanks for the fast answer.
    The three door switches are connected in row. That is allowed. So i have only three devices with each two OSSD's. Are there no possibility to solve this with a simple relay circuit?
    We don't want any external safety controller because it should be a simple and manageable "special machine". We have a lot of big totally complex machines.  :)
  • fabefabe Posts: 4 Apprentice
    I have found a safety relay for light curtains:
    For each curtain one relay. Then I connect the closers contact in row on the safeguard input.
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    Don't forget on the UR you will have two inputs on the safeguard circuit, they must be made and broken at the same time and I do not believe they can be tied together, meaning one circuit feeding both inputs, as I think that causes a fault on the UR.  All of this dual redundancy is for safety to ensure that if a relay or device were to fail in the closed/on state that you could not get the robot into an unsafe state by monitoring two independent circuits at all times.
  • MoAlMoAl Posts: 3 Recruit
    I am currently working on a project where the best way is to make the stop/resume manually after the light curtain detects. But the issue is the robot is lifting relatively a heavy item that is around 10 Kg in weight so I also need to make sure that when the robot pauses until an operator comes outside the area and press to continue that the robot keep lifting the item and do not drop it. So is there a way to make sure that during the pause operation that all the digital and analog inputs/output will remain the same ?
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    Generally for safety we make the gripper output being off the state for holding the part. That way in case the outputs turn off for some reason, a fault for instance, the gripper does not turn loose of the part. We also use 5/3 valves in critical applications so that we have to power both open and close operations. We’ve also used systems where even on a loss of air pressure we do not lose control of the gripper. 

    The only way to make sure the outputs cannot change state due to an operator interfering is to remove the ability for the outputs to be operated from the touch pendant, this is on the installation tab for the IO setup. 

    Remember though that if the robot faults for any reason that all outputs will turn off. One easy way to fault a safeguarded robot is to try to move it. This will cause a safety violation which triggers a fault and I believe turns off all the outputs. 
  • MoAlMoAl Posts: 3 Recruit
    edited December 2019
    Thank you for the quick answer, but the issue that I have is that the item that is lifted is relativey large in dimensions if the gripper lost it, it may cause some harm for exmaple if it is dropped on the feet of operator. So I was thinking if I can connect the light curtain as input to the safety guard with a reset button. So that once the light curtain detect interfering from operator, the robot standstill but with enough vacuum power to keep lifting the item and not dropping it then resume the process from where it was stopped when the operator press the reset button and step out from the robot area. So my main concern is that to always make sure the outputs are not affected by the safety signals e.g. if outputs were high, they remain high and vice versa. I want only to stop the movement of the robot but I do not know if that would be possibe using the safety signals. I know that is something I can do if I am going to wire the light curtain to the other input but in this case, I know that I will have a problem with safety consideration since I am not using dedicated safety inputs.
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    Yes, you would connect the light curtain to the safeguard input on the robot, S0 and S1 located below the e-stop input.  You would then need to connect a double pole button to one of the pair of configurable inputs and in the safety section of the installation file set that input to be a safeguard reset button.  Then when the light curtains are broke the robot program will pause operation until the reset button is pressed, then operation will resume.

    My earlier point though still needs to be heeded as the robot will turn off outputs if the system were to fault.  If this were to occur while the operator was in the safety area this could lead to a part being dropped if the vacuum on signal is when the output is high and so when the system faults the output would turn off and so would the vacuum.  I have seen many system faults with safety systems as operators will enter the safety area and then try to use the free drive button to move the robot, this does not work and if they try to force it to move will cause a safety violation as the safety system is monitoring the robot position and watching for any motion as there should be none during a safeguard stop.

  • MoAlMoAl Posts: 3 Recruit
    And in this case, it should be possible to directly connect the light curtain to the control box without the need to have any kind of safety relay or safety controller ?
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    You can try connecting the OSSD outputs from the light curtain, it should work so long as you power the light curtain using the controller 24V circuit. 
  • Ali40Ali40 Posts: 4 Apprentice
    I was trying to install a light curtain and wire it into Ur10 control box but I encountered the problem that the robot starts with safetyguard enabled for no reason. 

    The way I wire the light curtains 

    OSSD1: s0
    OSSD2: s1

    But I did not know if I should connect anything to the 24V of each in the safety inputs of the robot. I was also in doubt to supply the sender and receiver of the light curtain, Can I supply them from digital outputs from the robot or they need to be wired in a specific way ?
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    You will need to power the light curtain sender and receiver from the robot so that everything is set to use the same 24V source.  Also, make sure your curtains are aligned properly and that the OSSD are turning on. 
  • Ali40Ali40 Posts: 4 Apprentice
    Thank you for the fast reply. I am powering it from the robot but should it be power from the pwr terminal or from digital outputs  and does it make any difference?

    May I ask you what do you mean by aligned properly and how can I check if the OSSD are turning ?. I think they are turning since the robot does not even continue initialization due to safety guard stop
  • matthewd92matthewd92 Founding Pro, Tactile Sensor Beta Testers Posts: 1,266 Handy
    I usually use the 0V and 24V on the IO blocks to get my power. 

    As far as knowing if they are aligned there should be some sort of indicator on the light curtains that indicate their state, curtain made or curtain broken. Each brand does this differently, look at the user manual for your light curtains. 

    Do you need to have a reset safeguard input?  Check your safety configuration, by default the robot requires a manual reset following a safeguard stop and that is assigned to the CI0/1 pair from the factory. You will need to change that to unassigned if you are not using a button for that function. 
Sign In or Register to comment.
Left ArrowBack to discussions page