-
-
Notifications
You must be signed in to change notification settings - Fork 92
Open
Labels
topic: codeRelated to content of the project itselfRelated to content of the project itselftype: imperfectionPerceived defect in any part of projectPerceived defect in any part of project
Description
On the Uno R4 Minima and Uno R4 WiFi, pin 13 is made an output after reset, so if you do:
void setup() {
Serial.begin(9600);
delay(5000);
}
void loop () {
Serial.println(digitalRead(13));
delay(1000);
}
and apply 5V to the pin (via a resistor for safety), you still get 0.
The usual Arduino convention is that all digital pins are inputs after reset, and to make a pin an output you have to call pinMode(13, OUTPUT)
, for example. As far as I know no other Arduino board does this.
The way it is currently working is undesirable, because you might have pin 13 connected to a voltage input; an accidental reset could then cause excessive dissipation in the output driver.
Note: Originally posted on the Early Access Program forum, but still an issue.
Metadata
Metadata
Assignees
Labels
topic: codeRelated to content of the project itselfRelated to content of the project itselftype: imperfectionPerceived defect in any part of projectPerceived defect in any part of project