Measurement of Switch Timing Distribution in Scanning Communication and Its Application to Automatic Error Correction