diff --git a/cores/arduino/validation/test.cpp b/cores/arduino/validation/test.cpp index 3f16d4f75a4b6ed9b40e5ba84f1cbe0b2a3b6bac..fc7b2b23e1a2d0c736085f6c4b7290f9d690dbab 100644 --- a/cores/arduino/validation/test.cpp +++ b/cores/arduino/validation/test.cpp @@ -81,7 +81,7 @@ void loop( void ) Serial.write( "test2" ) ; // send another string */ - // Test digitalRead: connect pin 2 to either GND or 3.3V. !!!! NOT on 5V pinZZ !!!! + // Test digitalRead: connect pin 2 to either GND or 3.3V. !!!! NOT on 5V pin !!!! pin_value=digitalRead( 2 ) ; // Serial.write( "pin 2 value is %s\n", (pin_value == LOW)?"LOW":"HIGH" ) ; delay( 1000 ) ; // wait for a second diff --git a/cores/arduino/wiring.c b/cores/arduino/wiring.c index 8ba09d3ecb813375c53155a09a16ed2feb08c930..e7f6167c7afb06af141583af8d77e6f7ee0d978b 100644 --- a/cores/arduino/wiring.c +++ b/cores/arduino/wiring.c @@ -67,9 +67,9 @@ void init( void ) PM->APBCMASK.reg |= PM_APBCMASK_ADC | PM_APBCMASK_DAC ; // Setup all pins (digital and analog) in INPUT mode (default is nothing) -// for ( ul = 0 ; ul < NUM_DIGITAL_PINS ; ul++ ) + for ( ul = 0 ; ul < NUM_DIGITAL_PINS ; ul++ ) { -// pinMode( ul, INPUT ) ; + pinMode( ul, INPUT ) ; } // Initialize Serial port U(S)ART pins