Patent attributes
A device has a distance sensor and a transmitter. The distance sensor, attached to a barrier, measures an opening formed by the barrier. The transmitter transmits a control signal to a barrier controller. The barrier controller controls a movement of the barrier based on the control signal. The device receives a requested size of the opening. The device transmits, to the barrier controller, a first control signal that instructs the barrier controller to move the barrier and a second control signal that instructs the barrier controller to stop the movement of the barrier after an elapsed time has expired. The device measures a final size of the opening and adjusts the elapsed time based on the final size of the opening and the requested size of the opening.