Con
STM32 |
// 817.7 khz //__________ #define pinLED1 PA0 void setup() { pinMode(pinLED1, OUTPUT); } void loop() { salto: digitalWrite(pinLED1, LOW); digitalWrite(pinLED1, HIGH); goto salto; } |
Con
Arduino |
// 94060 Hz void setup() { pinMode(13, OUTPUT); } void loop() { digitalWrite(13, HIGH); digitalWrite(13, LOW); } |
// 96920 Hz void setup() { pinMode(13, OUTPUT); } void loop() { salto: digitalWrite(13, HIGH); digitalWrite(13, LOW); goto salto; } |
// 2648.6 KHz void setup() { DDRB = DDRB | B00100000; } void loop() { salto: PORTB = PORTB | B00100000; PORTB = PORTB & B11011111; goto salto; } |
// 3972.9 KHz void setup() { DDRB = DDRB | B00100000; } void loop() { salto: PORTB = 0; PORTB = 255; goto salto; } |