Partially tested code

Vertical sync happening at 60.04966 Hz
Horizontal sync happening at 35.96981 KHz ( not confirmed)