|
|
@@ -5,7 +5,7 @@
|
|
|
|
|
|
(See the README.md file in the upper level 'examples' directory for more information about examples.)
|
|
|
|
|
|
-This example uses the sigma-delta driver to generate modulated output on a GPIO. If you filter the output signal with an active or passive filter, you can get a 1 KHz sine wave.
|
|
|
+This example uses the sigma-delta driver to generate modulated output on a GPIO. If you filter the output signal with an active or passive filter, you can get a 100 Hz sine wave.
|
|
|
|
|
|
## How to use example
|
|
|
|
|
|
@@ -46,21 +46,17 @@ Once the upload is complete and the board is reset, the program should start run
|
|
|
I (299) main_task: Calling app_main()
|
|
|
I (309) gpio: GPIO[0]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 1| Pulldown: 0| Intr:0
|
|
|
I (309) sdm_dac: Sigma-delta output is attached to GPIO 0
|
|
|
-I (319) sdm_dac: Timer allocated with resolution 10000000 Hz
|
|
|
-I (329) sdm_dac: Timer callback registered, interval 10 us
|
|
|
+I (319) sdm_dac: Timer allocated with resolution 1000000 Hz
|
|
|
+I (329) sdm_dac: Timer callback registered, interval 100 us
|
|
|
I (329) sdm_dac: Timer enabled
|
|
|
I (339) sdm_dac: Output start
|
|
|
```
|
|
|
|
|
|
After the output stated, you can monitor the output signal by an oscilloscope.
|
|
|
|
|
|
-If you monitor on the GPIO directly, you can see the raw SDM output, it consists by square waves (i.e. pulse) with different density
|
|
|
+If you monitor on the GPIO directly, you can see the raw SDM output, it consists of square waves (i.e. pulse) with different densities (see the blue wave in the figure), and if you monitor the signal after a low-pass filter, you can see the pulses are filtered into a sine wave already (see the yellow wave in the figure).
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-If you monitor the signal after a low-pass filter, you can see the pulses are filtered into a sine wave already
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
|
|
|
## Troubleshooting
|
|
|
|