Placed directly opposite each other on either side of your entrance, they have an infrared beam that shines between them. As long as the beam is broken then the gates will not close. This is a safety measure to prevent gates from self-closing whilst there may be a vehicle in the way or a pedestrian. Sliding and cantilever gates generally only require one set of photocells whereas it would be advisable to place 2 sets on swing gates… One set between the actual entrance and another set (mounted on posts if nowhere else to fix to) further through the gates to ensure that if your vehicle has pulled partly through your gates that the 2nd set of photocells has detected it is still there. If a car is likely to have to remain stopped between the gates (to exit on to a road for example), you will definitely need 2 pairs on a swing gate.