Page 1 of 1

Uno vs Wemos - the differences

Posted: Wed Jun 15, 2016 1:56 pm
by arduino4fun
This is the difference between the Arduino UNO pins assignement and the WeMos-D1R2 board.

for example, the on-board LED on the UNO is connected to pin 13, on the WeMos-D1R2 the on-board LED is connected to pin 14

Sketch for the blinking LED on the WeMos :

Code: Select all

// ----------------------------------------------------------------------------------------------
 // This sketch allows to check the WeMos D1 board thru a led connected on pin #13
 //
 // https://www.facebook.com/arduino4fun
 // http://www.arduino4fun.com
 // ----------------------------------------------------------------------------------------------

//‪#‎define‬ MY_LED BUILTIN_LED
 #define MY_LED 14 // WeMos D1R2 on pin #14 ! change to 13 for the Arduino UNO

// the setup function runs once when you press reset or power the board
 void setup()
 {
 // initialize MY_LED as an output.
 pinMode(MY_LED, OUTPUT);
 }

// the loop function runs over and over again forever
 void loop()
 {
 digitalWrite(MY_LED, HIGH); // turn the LED on (HIGH is the voltage level)
 delay(200); // wait for a second
 digitalWrite(MY_LED, LOW); // turn the LED off by making the voltage LOW
 delay(200); // wait for a second
 }


Image