Doppler shift measurement method in a recording system using ambiguous codes