Wednesday, 4 November 2020

ESP32 lessons

Past days I learned a lot about the ESP32 microcontroller. Internet taught me how to connect an LCD to the controller and how to read analog inputs.

I installed the Arduino IDE with the Espressif files to be able to program the ESP32 development kit in "C".

At this moment I have a working prototype of a CO2 sensor circuit. I used an MG-812, CO2 sensor.

This is how the setup looks now:

CO2 sensor setup


The circuit consists of an analogue and digital part:

CO2 sensor analogue circuit with 10x gain opamp


CO2 sensor digital circuit




This is my first program in "C":

It was an interesting voyage to get the module in action. Lots of features are there to be discovered; wifi and bluetooth function, I2C protocol, PWM outputs etc.

Notes; 

-The electrolytic capacitor of 10 uF between EN and GND on the ESP32 module was necessary to upload the program to the module. It took me a couple of days to find that out.

-The max input voltage of the ADC inputs is 3.3 V. That's why I installed a 3V3 zenerdiode after the output of the opamp.


Update 21 Nov 2020:

I added the wifi functionality to the software. I can read out the CO2 concentration via the internet:




Also placed the ESP32 module onto the board:




Updated 5 Dec 2020;


Housed


No comments:

Post a Comment