ESP-12E
Posted: Fri Jul 27, 2018 1:09 pm
Hi
I have a new ESP-12E nodeMCU v3.0 I got it to replace my arduino nano and ESP01 so I wouldn't have to deal with extra wiring, etc.
I am able to turn on LEDs, but not able to read from DHT11 and 22. Not sure why. When I open the serial window, I see "nan". In my searches I read something about pins mislabeled and I got a this table, but I am not sure whether D0 is the pin on the board or D0 is pin 0 in the programming. The code is the same code that I use for nano.
static const uint8_t D0 = 16;
static const uint8_t D1 = 5;
static const uint8_t D2 = 4;
static const uint8_t D3 = 0;
static const uint8_t D4 = 2;
static const uint8_t D5 = 14;
static const uint8_t D6 = 12;
static const uint8_t D7 = 13;
static const uint8_t D8 = 15;
static const uint8_t D9 = 3;
static const uint8_t D10 = 1;
I have a new ESP-12E nodeMCU v3.0 I got it to replace my arduino nano and ESP01 so I wouldn't have to deal with extra wiring, etc.
I am able to turn on LEDs, but not able to read from DHT11 and 22. Not sure why. When I open the serial window, I see "nan". In my searches I read something about pins mislabeled and I got a this table, but I am not sure whether D0 is the pin on the board or D0 is pin 0 in the programming. The code is the same code that I use for nano.
static const uint8_t D0 = 16;
static const uint8_t D1 = 5;
static const uint8_t D2 = 4;
static const uint8_t D3 = 0;
static const uint8_t D4 = 2;
static const uint8_t D5 = 14;
static const uint8_t D6 = 12;
static const uint8_t D7 = 13;
static const uint8_t D8 = 15;
static const uint8_t D9 = 3;
static const uint8_t D10 = 1;