A test for a digital envelope detector using a rectifier and a low-pass filter. The program first creates sample vectors for sinusoidal waves of 2Hz and 20Hz (considering 1kHz sampling frequency). Then, every 10ms it generates a new sample for a modulated wave (multiply both waves), and passes it through a full-wave rectifier and a Chebyshev low-pass filter with cutoff frequency of 5Hz. Then it sends the original wave and the recovered envelope through serial port in CSV format. I used 10ms interval instead of 1ms because otherwise the serial speed would have to be too high.

Dependencies:   mbed

mbed.bld

Committer:
quevedo
Date:
2014-08-26
Revision:
0:1ba9469c839f

File content as of revision 0:1ba9469c839f:

http://mbed.org/users/mbed_official/code/mbed/builds/9327015d4013