Abstract

The correct selection of sampling frequency when reading signals from sensors ensures high quality of digitized data and saves memory when storing such data. The complexity of automatic selection of the sampling frequency is explained by the fact that this frequency depends on the frequencies of the useful signal, which are not always known. Therefore, in the work the computer system for reading signals from temperature, humidity, and lighting sensors with automatic selection of the sampling frequency based on the Fourier spectrum analysis of the signals was developed. Signals from digital sensors (DHT22) are transmitted directly to the Raspberry Pi3 microcomputer. Signals from analog sensors (LM335M, light sensor) are fed to the Arduino Uno device. An algorithm for the analysis of Fourier spectra of one-dimensional signals has been developed, which is designed to determine the optimal sampling frequency and decimation coefficient of signals read from sensors. Based on the initial signals, their Fourier spectra are calculated, and by analyzing the spectra, the maximum frequency of the useful signal and the optimal sampling frequency are determined. Specified sampling frequency according to the sampling theorem is calculated as a double value of the maximum frequency of the useful signal. Decimation (thinning) of the signal is performed with a coefficient determined by the ratio of the initial and specified sampling frequencies. To assess the quality of the signal after decimation, the decimated values were interpolated by splines. The root mean square error of interpolation was calculated. Experimental testing of the developed tools for reading and analyzing signals from temperature, humidity and lighting sensors was carried out. In all considered cases, the sampling frequency is determined correctly. The resulting sampling rates can be used for decimation of signals or for subsequent reading of signals from sensors.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call