This shows you the differences between two versions of the page.
pm:lab:lab0xc0-4 [2020/04/07 11:52] iuliana.brinzoi [Tasks] |
pm:lab:lab0xc0-4 [2020/04/07 21:54] (current) iuliana.brinzoi [Tasks] |
||
---|---|---|---|
Line 13: | Line 13: | ||
=== Sampling Rate === | === Sampling Rate === | ||
The sampling rate represents the time at which the values of the analog input signal are read. The time is divided into discrete intervals, each sampling a value from the input signal. The Nyquist frequency tells us that it is mandatory for the sampling rate to be at least twice the frequency of the analog input signal so that the signal can be reconstructed afterwards. | The sampling rate represents the time at which the values of the analog input signal are read. The time is divided into discrete intervals, each sampling a value from the input signal. The Nyquist frequency tells us that it is mandatory for the sampling rate to be at least twice the frequency of the analog input signal so that the signal can be reconstructed afterwards. | ||
- | There appears a problem where frequencies above half the Nyquist rate are sampled because they are incorrectly detected as lower frequencies. This process is called aliasing. | + | There appears a problem where frequencies above half the Nyquist frequency are sampled because they are incorrectly detected as lower frequencies. This process is called aliasing. |
{{ :pm:lab:adc_2.png?600 |}} | {{ :pm:lab:adc_2.png?600 |}} | ||
Line 126: | Line 126: | ||
Sketch is available here: {{:pm:lab:lab3.zip|}} | Sketch is available here: {{:pm:lab:lab3.zip|}} | ||
<hidden> | <hidden> | ||
- | Solution is available here: {{:pm:lab:lab0xc3_sol_asistenti.zip|}} | + | Solution is available here:{{:pm:lab:lab0xc3_sol_asistenti.zip|}} |
</hidden> | </hidden> | ||
- To the PA1 pin there is connected a voltage divider. Push buttons control the output voltage. Read the value from the pin using polling and print the corresponding voltage to the serial console. | - To the PA1 pin there is connected a voltage divider. Push buttons control the output voltage. Read the value from the pin using polling and print the corresponding voltage to the serial console. |