@GonzoG
Code: Select all
const byte PWM_PIN[20] = {
PA1, PA2, PA3,
PA6, PA7, PB0, PB1, PB10, PB11,
PB5, PB4, PB3, PA15, PA11, PA10, PA9, PA8, PB15, PB14, PB13,
};
#define LED PC13
void setup(){
//------------------------------------------------------------------------//
Serial.begin(115200);
for (uint8_t i = 0; i < 20; i++) { pinMode(PWM_PIN[i],OUTPUT); }
pinMode(LED, OUTPUT);
delay(100);
//------------------------------------------------------------------------//
//------------------------------------------------------------------------//
digitalWrite(LED,LOW);
for (uint8_t i = 0; i < 20; i++) { analogWrite(PWM_PIN[i], 150); }
delay(1000);
//------------------------------------------------------------------------//
//------------------------------------------------------------------------//
Serial.println(" SETUP OK!");
//------------------------------------------------------------------------//
}
Only 10 out of 20 'PWM PIN' works.
What's the reason?
I wonder. I can't understand.