Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++SEEEDUINO XIAO génrateur de triangle pour moduler l'ESP32+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- //+++++++++++++++++++++++++++++++++++++++++++++++A UTILISER AVEC LE CODE ESP32SIWAVE0002_AnnexeRampeXIAO POUR LE SEEDUINO XIAO+++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- //==================================================================claude.dufourmont@laposte.net======================================================================================
- //===========================================================https://www.youtube.com/c/ClaudeDufourmont================================================================================
- //..........Ce petit dispositif est très intéressant en tant que petit générateur BF de labo, personnellement je le garde monté sur breadboard (en incluant ou pas les MCU)............
- //===========================================================================FONCTIONNE================================================================================================
- #define DAC_PIN A0
- int i =0;
- void setup()
- {
- analogWriteResolution(10); // Set analog out resolution to max, 10-bits
- analogReadResolution(12); // Set analog input resolution to max, 12-bits
- }
- void loop()
- {
- for (int i = 0; i <= 950; i = i + 1)
- {
- analogWrite (A0,i);
- delay (5);
- }
- for (int i = 950; i >= 0; i = i - 1) {
- analogWrite (A0,i);
- delay (5);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement