Added Phase delay and fixed offset

Also looking into reference voltage