Frame buffer reading fixed. Need to do frame synchronization