Dumb But Great Point and Shoot Camera With ESP32 CAM
by Arnov Sharma in Circuits > Arduino
5478 Views, 20 Favorites, 0 Comments
Dumb But Great Point and Shoot Camera With ESP32 CAM
Hey everyone what's up, so here's something cool, an esp32 cam-based point and shoot camera.
So the idea here was to take this very useful esp32 cam board and flash it with a sketch that lets us take an image and save it on the memory card.
kinda like a proper point-and-shoot camera but this setup won't have any kind of display on it.
which is a bummer but it works.
To be honest, images captured by this esp32 cam are pretty bad but the camera itself works, we have a camera at our disposal that is handheld and can take images which is a cool thing.
In this Instructables, I'm gonna show you guys how you can make this setup in few easy ways.
Let's get started
Supplies
these are the stuff that I used in this project.
- ESP32 cam board
- Custom PCB
- Lithium Cell 3.7V
- USB Micro Port
- IP5306 Power management IC
- 10uF 0805 Capacitor
- 2R 0603 Resistance (I didn't have the same package so I used 0805 Resistors)
- SMD LEDs 0603
- 1uH inductor
- Battery JST connectors
- Female Header pins
- Tick Tack switch
- 3D Printed body
PROLOGUE
ESP32 CAM is quite a useful development board, it is equipped with a 2MP OV2640 camera module and an SD Card Reader on the bottom side of the board.
Also, It cost around 10$ which is a pretty sweet price tag for such a capable Microcontroller.
The WIFI module used in this Version is ESP-32S which has a built-in 32Mbit of Flash and 512KB Internal plus external 4M PSRAM.
It's five volts tolerant which means we can power the ESP32 Cam with a voltage less than 5V, if you provide it a voltage greater than 5V, it will get destroyed.
Here's a fun project for this Board, a point-and-shoot camera that will capture an image and save it into the SD Card. Previously, I have made a Security Cam concept with this ESP32 Cam board and it worked.
I've placed it outside my home and it's still working.
https://www.instructables.com/DIY-ESP32-Security-C...
My point here is, ESP32 CAM can handle all sorts of stuff, from streaming a video to capture images and stuff. It does heat white streaming live footage which is a flaw but for a setup like a video recording cam, a cooling fan can be added to decrease the temp of the module.
Basic Structure
- Before making a PCB Edition of this project, I first flash the ESP32 Cam with the main sketch of this project, I made a temporary setup on a perf board just for testing
- then I added this setup with a 5V power source which is this LiPo boost module that you can buy online.
- After connecting the 5V and GND of Boost module with ESP32 Cam's 5V and GND, we can power this board reliably.
- For capturing a picture, we just press the reset button and this camera setup will capture an image with a delay of 3 seconds.
Now let's move on to the next step or next variant which is the PCB edition of this ESP32 Cam setup.
PCB Edition- IP5306 Setup- Schematic
Now to make the PCB of this ESP32 Camera Setup, I really don't have to do the whole R&D thing in this project as this setup is just an ESP32 Camera powered by a LiPo boost converter circuit.
So what I did was, I first got the IP5306 IC which is a Power management IC that has an inbuilt LiPo-Lithium cell charging feature inbuilt with low cut and high cut both available, it also boosts their voltage up to 5V 2A which is a lot.
I studied its datasheet and then prepared a schematic in my PCB CAD Software.
The Schematic is relatively simple, there's a minimal IP5306 Setup.
the output of IP5306 goes into the 5V and GND of ESP32 Cam breakout pins.
I have also added a separate switch to the PCB, it's not connected to the board or anything, it is completely isolated with only two connectors. that's because I will manually solder wires from both terminals of the reset button on ESP32 to these pads.
After completing the Schematic, I then converted it into a PCB design.
PCB Design
After completing the Schematic, I then converted it into a PCB design.
I place all the components in the right order and then connected their tracks to each other properly.
I also added few artistic elements on this PCB which includes a custom Silkscreen, logo, and a bongo cat.
Getting PCBs From PCBWAY
After finishing the design, I exported its Gerber data and send it to PCBWay for samples.
I've been using the PCBWAY service for a long time now and for this project, I got PCBs in Purple Soldermask. This was my first time getting a Purple PCB and the experience of that was just great, I really liked the overall quality of the solder mask and custom silkscreen that I placed all over the board.
Check out PCBWAY for getting great PCB Service at less cost!
ASSEMBLY PROCESS
The Assembly process of this PCB includes three major things, which are
- solder paste dispensing
- pick and place process
- Hotplate reflow
- Adding THT components
SOLDERPASTE DISPENSING
First, we place solder paste on each components pad, I'm using a generic solder paste (SN-Pb Ratio 63-37) with a solder paste dispensing syringe.
PICK AND PLACE
Then we add components to their assigned place one by one. You could see the schematic for the precise location of each component.
HOTPLATE
After adding components to their location, we carefully lift the PCB and put it on an SMT hotplate.
I'm using my DIY SMT Hotplate here which you can check out from here-
https://www.instructables.com/DIY-SMT-Hotplate-Pro...
Hotplate heats the PCB from below up to the solder paste melting temp, as soon as the PCB reaches that temp, Solder paste melts and all the components get soldered to their pads. we lift the PCB and then place it on a cooler surface for a little bit, to cool down the heat of PCB.
THT Components
After completing the SMD Process we add remaining THT components like the USB port, header pins, Battery connector.
TESTING 5V Output
After completing the circuit, I added a lithium cell to the circuit and checked the output voltage at 5V and GND.
Originally I wanted to use a LiPo Cell but I ended up using a Lithium-Ion cell of 3.7V 2600mAh instead.
Adding ESP32 on the PCB
After checking the board and making sure that everything is nice and dandy
I added ESP32 Board on the PCB but before that, I added wires on both terminals of the SMD Button which is on the ESP32.
I then connected those wires to the Connecting Pads provided on Circuit. Basically, I'm just adding this switch in parallel with the SMD Button of ESP32.
Now we can reset the board from the custom PCB instead of pressing the reset button on the ESP32 CAM.
Uploading the Main Sketch
The sketch is already added to the ESP32 CAM, for a detailed programming process, check this post of mine.
https://www.instructables.com/ESP32-CAM-WEB-Server...
But basically, we first wire the ESP32 CAM with an FTDI Module in the following order-
- Set FTDI output to 5V
- Connect the FTDI's VCC (which is 5V) to 5V of ESP32 CAM
- GND to GND
- RX to U0T
- TX to U0R
- GPIO0 which is IO0 to GND (this will put the ESP32 CAM in Flash Mode)
Flashing Step-
- Go to Tools and select the right board which is in our case AI-Thinker ESP32-CAM.
- Select the right port and hit upload.
- After uploading is completed, plug out the USB from FTDI Module and remove the jumper between GPIO0 and GND.
Now we add SD Card to the ESP32 and power the whole board by pressing the Power on the switch of the IP5306 IC.
Then we press the Reset button and our camera will take a photograph with a delay of 3 seconds.
Downloads
RESULT
As you can see, the camera is working, and clicking images with it is possible.
Image quality however is not really great but hey!
what did you expect, it's an ESP32 CAM with an OV2640 which is a 2 MP Image sensor from 2005.
3D Printed Body
Now the PCB of this project looks and works great but it is meant to be a portable device so I designed its Body in fusion360 and then 3D Printed it on my ender 3.
I used PLA for this project but other materials can be used as well.
Final Project
So this is the final form of my ESP32 Camera Project, it looks awesome but it doesn't work very well.
Maybe I could make a better camera setup with an RPI camera module but that would be cheating as I will be porting this project from ESP32 to a Raspberry Pi which is a freaking computer on a chip!
We'll see what happens in the next iteration of this project, until then, stay tuned and I'll be back with another project soon!
Peace