I understand the esp8266 only has 2 gpio pins I could use to connect to sensors. Currently I have a simple setup where an esp01s samples data from a dht22. The esp01s is running on its own as a mcu.
I want to add a UV sensor and an mq sensor and maybe even a dust and light sensor. Would I need to move up to a nano or is there something I can do and keep my esp on its own?
Marciokoko:
I understand the esp8266 only has 2 gpio pins I could use to connect to sensors.
that's right but you can free rx/tx and use them as GPIOs as well
void setup() {
pinMode(1, FUNCTION_3); //GPIO 1 (TX) swap the pin to a GPIO.
// pinMode(1,OUTPUT);
pinMode(3, FUNCTION_3); //GPIO 3 (RX) swap the pin to a GPIO.
// pinMode(3,OUTPUT);
}
but make sure you have 100uF electrolytic cap. across RST and Gnd to make sure it(esp01) won't lock into a boot mode