Directional Drilling (DD) achieves higher well production and improves accessibility of oil reservoirs in complex locations. Quad Motor drilling heads was recently proposed to achieve better steering control of the drilling operation and higher dogleg severity. The current state of the art in DD is the Rotary Steerable System (RSS), where steering actuators displace the centerline of the drilling system away from the centerline of the hole by a controllable amount of eccentricity. The drilling bit is powered by the rotation of the drilling string. However, in the quad motor drilling head, four drilling bits are independently controlled by 4 downhole motors. This paper proposes a real time control and optimization of the quad bit directional drilling system. The control commands include the angular velocity and torque of each of the 4 motors. The control is updated at regular distance intervals. The optimization procedure determines the drilling parameters to minimize the drilling time and the deviation from the planned trajectory.