Accurate data acquisition is crucial in embedded systems. This study aimedto evaluate the data acquisition ability of the ESP32 Analog to Digital Converter (ADC) module when combined with the I2S module to collect high-frequency data. Sine waves at various frequencies and white noise were recorded in this mode. The recorded data were analyzed by the fast Fourier transform (FFT) to assess the accuracy of the recorded data and evaluate the generated noise. Digital filters are proposed to improve the quality of the collected signals. A 2D spectrogram imaging algorithm isproposed to convert the data to time-frequency domain images. The results showedthat the ADC module couldeffectively collect signals at frequencies up to 96 kHz; frequency errors were proportional to the sampling rate, and the maximum was79.6 Hz, equivalent to 0.38%. The execution time of the lowpass and highpass filters wasabout 6.83 ms and for the bandpass filter about 5.97 ms;the spectrogram imaging time was 40 ms;while the calculation time for an FFT transform was approximately 1.14 ms, which is appropriate for real-time running. These results are significant for data collection systems based on microcontrollers and are a premise for deploying TinML networks on embedded systems.
Tạp chí khoa học Trường Đại học Cần Thơ
Lầu 4, Nhà Điều Hành, Khu II, đường 3/2, P. Xuân Khánh, Q. Ninh Kiều, TP. Cần Thơ
Điện thoại: (0292) 3 872 157; Email: tapchidhct@ctu.edu.vn
Chương trình chạy tốt nhất trên trình duyệt IE 9+ & FF 16+, độ phân giải màn hình 1024x768 trở lên