Method and device for alignment of audio data frames using interpolation and decimation
First Claim
1. A timing synchronization device to eliminate timing misalignment of an input sampled data and an output sampled data comprising:
- an input sampled data counter to determine a number of samples in said input sampled data;
an interpolator to estimate data sample values for each sample of the input sampled data to coincide with each sample of the output sampled data if the number of samples in said input sampled data is less than an expected number of samples in said output sampled data;
a decimator to remove any excess samples of the input sampled data and to extrapolate each data sample of the input sampled data to coincide with each sample of the output sampled data, if the number of samples in said input sampled data is greater than the expected number of samples in the output sampled data; and
a calculate and control means connected to the input sampled data counter, the interpolator, the decimator, and a low pass filter, whereby said calculate and control means receives the number of samples in the input sampled data and compares said number of samples in the input sampled data with the expected number of samples in the output sampled data, if the number of samples in the input sampled data is less than the expected number of samples in the output sampled data, the calculate and control means causes said interpolator to estimate the data sample values, if the number of samples in the input sampled data is greater than the expected data, the calculate and control means causes said decimator to remove the excess samples and extrapolate each data sample, and determines a cutoff frequency of said low pass filter.
2 Assignments
0 Petitions
Accused Products
Abstract
A method and device to synchronize sampled digital data transferred from an input section to an output section prevents data overrun or underrun due to timing differences of timing signals of the input and output section. The timing synchronization device has an input sampled data counter to determine a number of samples in a frame time of the input sampled data. The timing synchronization device further has an interpolator to estimate data sample values for each sample of the input sampled data to coincide with each sample of the output sampled data if the number of samples in said input sampled data is less than an expected number of samples in said output sampled data. If the number of samples in said input sampled data is greater than the expected number of samples in the output sampled data, the timing synchronization device has a decimator to remove any excess samples of the input sampled data and to extrapolate each data sample of the input sampled data to coincide with each sample of the output sampled data. The timing synchronization device has a low pass filter connected to the interpolator and the decimator to prevent any aliasing of the output sampled data and a calculate and control means connected to the input sampled data counter, the interpolator, the decimator, and the low pass filter to control the operation.
-
Citations
17 Claims
-
1. A timing synchronization device to eliminate timing misalignment of an input sampled data and an output sampled data comprising:
-
an input sampled data counter to determine a number of samples in said input sampled data;
an interpolator to estimate data sample values for each sample of the input sampled data to coincide with each sample of the output sampled data if the number of samples in said input sampled data is less than an expected number of samples in said output sampled data;
a decimator to remove any excess samples of the input sampled data and to extrapolate each data sample of the input sampled data to coincide with each sample of the output sampled data, if the number of samples in said input sampled data is greater than the expected number of samples in the output sampled data; and
a calculate and control means connected to the input sampled data counter, the interpolator, the decimator, and a low pass filter, whereby said calculate and control means receives the number of samples in the input sampled data and compares said number of samples in the input sampled data with the expected number of samples in the output sampled data, if the number of samples in the input sampled data is less than the expected number of samples in the output sampled data, the calculate and control means causes said interpolator to estimate the data sample values, if the number of samples in the input sampled data is greater than the expected data, the calculate and control means causes said decimator to remove the excess samples and extrapolate each data sample, and determines a cutoff frequency of said low pass filter. - View Dependent Claims (2, 3, 4, 5, 6)
where D2′
is an estimated data sample,D1 is a previous input data sample, D2 is a present input data sample, CNT is the number of samples in the input sampled data, and CNTexpected is the number of samples expected in the output sampled data.
-
-
4. The timing synchronization device of claim 1 wherein the decimator estimates the data sample values for each sample of the input sampled data by solving the formula:
-
where D2′
is an estimated data sample,D1 is a previous input data sample, D2 is a present input data sample, CNT is the number of samples in the input sampled data, and CNTexpected is the number of samples expected in the output sampled data.
-
-
5. The timing synchronization device of claim 1 wherein the low pass filter is coupled to the interpolator and the decimator to prevent any aliasing of the output sampled data.
-
6. The timing synchronization device of claim 5 wherein the low pass filter convolves said output sampled data into a frequency spectrum of said output sampled data and said low pass filter performs function of a form
-
x x of said frequency spectrum to provide the low pass filtering.
-
-
7. A method to synchronize a timing of an input sampled data to prevent data overrun and data underrun of said input sampled data due to timing differences of an input sampling clock and an output sampling clock, comprising the steps of:
-
counting the number of input sampled data within a data frame;
comparing said number of input sampled data with an expected number of output sampled data;
if the number of input sampled data is less than the expected number of output sampled data, interpolating each sample of the input sampled data to coincide with each sample of an output sampled data and inserting new estimated data samples for any samples of the output sampled data not coinciding with the input sampled data; and
if the number of input sampled data is greater than the expected number of output sampled data, extrapolating each sample of the input sampled data to coincide with each sample of the output sampled data and discarding excess data samples not coinciding with the output sampled data. - View Dependent Claims (8, 9, 10, 11)
where D2′
is an estimated data sample,D1 is a previous input data sample, D2 is a present input data sample, CNT is the number of samples in the input sampled data, and CNTexpected is the number of samples expected in the output sampled data.
-
-
9. The method of claim 7 wherein extrapolating estimates the data sample values for each sample of the input sampled data by solving the formula:
-
where D2′
is an estimated data sample,D1 is a previous input data sample, D2 is a present input data sample, CNT is the number of samples in the input sampled data, and CNTexpected is the number of samples expected in the output sampled data.
-
-
10. The method of claim 7 further comprising the step of low pass filtering the output sampled data to prevent any aliasing of the output sampled data.
-
11. The method of claim 10 wherein the low pass filtering convolves said output sampled data into a frequency spectrum of said output sampled data and said low pass filter performs function of a form
-
x x of said frequency spectrum to provide the low pass filtering.
-
-
12. A method to synchronize a timing of an input sampled data to a first timing signal to prevent data overrun and data underrun of said input sampled data due to timing differences between a second timing signal to which the input sampled data is synchronized and the first timing signal, comprising the steps of:
-
counting a number of input sampled data within a current data frame;
comparing said number of input sampled data with an expected number of input sampled data within the current data frame;
if the number of input sampled data is less than one less than the number of expected sampled data, interpolating a value using a last data sample of the input sampled data of the current data frame and a magnitude of a first data sample of the input sampled data of a next data frame, and appending said value to the input sampled data to form a current data frame of output sampled data; and
if the number of input sampled data of the current data frame is more than one greater than the number of expected sampled data, determining an average value of the last data sample of the input sampled data and a second to last data sample of the current data frame, inserting said average value to said second to last data sample, and discarding said last data sample to form the current data frame of the output sampled data. - View Dependent Claims (13, 14)
low pass filtering the current frame of the output sampled data to prevent any aliasing of said output sampled data.
-
-
14. The method of claim 13 wherein the low pass filtering performs a convolving of said output sampled data and said low pass filter performs function of a form
-
x x of a frequency spectrum to provide the low pass filtering.
-
-
15. A timing synchronization device to synchronize a timing of an input sampled data to a first timing signal to prevent data overrun and data underrun of said input sampled data due to timing differences of a second timing signal to which the input sampled data is synchronized and the first timing signal, comprising:
-
an input sampled data counter to determine a number of samples in a current frame of the input sampled data;
a count comparator to compare the number of samples in said current data frame of the input sampled data with an expected number of data samples of the current data frame of the input sampled data;
an interpolator to interpolate a value that is one half a sum of a magnitude of a last data sample of the input sampled data of the current data frame and a magnitude of the a first input data sample of a next data frame and to append said interpolated value after the last data sample of the input sampled data of the current data frame to form a current data frame of output sampled data, if the number of samples in said current data frame of the input sampled data is less than the expected number of data samples of the current data frame of the input sampled data; and
a decimator to determine an average value of the last data sample of the current data frame and a second to last data sample of said current data frame, to insert said average value to said second to last data sample of the current data frame, and to discard said last data sample to form a the current data frame of the output sampled data. - View Dependent Claims (16, 17)
of said frequency spectrum to provide the low pass filtering.
-
Specification