ESP32 Cam

ESP32 Cam EZB

Hardware: ESP32 Cam ESP32 Cam

Author: DJ Sures

This firmware converts a ESP32 Cam into an EZB for ARC to connect to it.

This firmware transforms the ESP32 Cam module into a fully functional EZ-B with an integrated Synthiam ARC camera, providing a powerful all-in-one solution for robotics and IoT applications. The firmware allows the ESP32 Cam to simultaneously operate as a video streaming device and a controller for peripherals like servos and sensors, making it an ideal choice for compact, feature-rich projects.

Key Features:

  1. EZ-B Compatibility: The firmware enables the ESP32 Cam to emulate an EZ-B, making it compatible with Synthiam ARC for controlling robotics systems and IoT devices.
  2. Integrated Camera: The ESP32 Cam’s built-in camera streams video directly to Synthiam ARC, offering real-time visual feedback alongside EZ-B functionality.
  3. Dual Functionality: Supports servo control and camera streaming simultaneously, making it versatile for applications requiring both visual monitoring and peripheral actuation.

Recommended GPIO Pins for Servos:

To ensure smooth operation of both the camera and peripheral controls, the following pins are recommended for use in servo control while the camera is active:

  • D2
  • D12
  • D13
  • D14
  • D15

These pins are optimized to avoid conflicts with the camera's operation and other internal processes, ensuring reliable performance in EZ-B mode.

How It Works:

  1. EZ-B Functionality: The ESP32 Cam handles peripheral controls, such as servo motors, sensors, and other devices, through Synthiam ARC commands.
  2. Video Streaming: The built-in camera streams video directly to Synthiam ARC, enabling real-time monitoring and control.
  3. Resource Allocation: The firmware ensures efficient management of the ESP32 Cam's resources, prioritizing critical functions like video streaming and servo control.

Benefits:

  1. Compact All-in-One Solution: Combines the functionality of an EZ-B and a camera into a single, compact device, saving space and reducing complexity in your projects.
  2. Cost-Effective: Offers a budget-friendly alternative to traditional EZ-B and camera setups while retaining full compatibility with Synthiam ARC.
  3. Versatile Applications: Suitable for robotics, home automation, surveillance, and other IoT projects requiring simultaneous video streaming and peripheral control.

Use Case Example:

This setup is perfect for robotic systems that require both camera feedback and precise control of servos or other peripherals. For instance:

  • A robotic arm with a camera for object recognition and manipulation.
  • A mobile robot with live video streaming and servo-driven navigation or gripper control.

By converting the ESP32 Cam into an EZ-B with an integrated camera, this firmware unlocks a versatile and efficient solution for advanced robotics and IoT applications.


  1. Install libraries into arduino ide: https://dl.espressif.com/dl/package_esp32_index.json

  2. Board manager install ESP32 by Espressif Systems

This project builds using...

  • Espressif Systems esp32 library version 3.0.7
  • ESP32Servo by Kevin Harrington version 3.0.6
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • Added editable definitions at the top of the ino source file for enabling/disabling features
Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • Increase the auto compression adjustment jump from 1 to 5 so it responds quicker.
Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • Works with servo & Camera at the same time
  • Added a note that the default IP address in AP Mode is (192.168.50.1)
Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • Works with servos & camera at the same time
Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • added dynamic camera compression

  • mapped Dx to GPIOx (i.e. ARC D4 = GPIO4, which is the FLASH LED)

Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

Version Information

  • First check-in of the ESP32 Cam firmware

*Note: For servo use with EZ-Cam, only pins 2,4,12-19,21-23,25-27,32-33 are recommended.

Click to show supported capabilities
Supported Capabilities
  • 12 Byte Unique Identifier
    Each controller has a unique identifier that can be referenced. This is to keep track in EZ-Builder projects which controller is being used and user logic specific to the ID.
  • ADC with 12 bit Resolution
    The ADC captures analog voltage at 8 bit resolution. This means the native value will be an 8 bit (0-4095) from the controller.
  • Can stream video v4 codec
    The controller supports the streaming Video v4 codec on a TCP or UART or USB connection.
  • Hardware UART TX/RX with DMA buffer and adjustable baud rate
    Contains 1 or more hardware UARTs with TX/RX functionality and DMA RX buffering.
  • Native WiFi Connectivity from ARC
    Controller supports WiFi connectivity using TCP between your computer with ARC.
  • PWM Duty on digital ports
    Digital ports can output a PWM between 0% and 100%.
  • PWM servos on digital ports
    The controller supports PWM Servos on digital ports. These are also called Hobby servos.
  • PWM servos on digital ports can release their position
    PWM servo driver on digital ports support the feature to release their holding position.
  • Read/Write Digital I/O Ports
    The ports marked as being digital will respond to Read and Write commands of boolean logic. The status of the digital port will be either TRUE or FALSE when voltage is detected or not, respectively.
  • Transmit Uart TX on all digital ports
    All digital ports support the ability to transmit (TX) serial/uart data at various pre-determined baud rates.

ARC Pro

Upgrade to ARC Pro

Unlock the true power of automation and robotics by becoming a proud subscriber of Synthiam ARC Pro.

PRO
USA
#17  

what is flashed ESP?

PRO
USA
#19   — Edited

Here is my esp32 cam and FTDI adapter on ARC with a pictures of DJ's modified code for my network, using 192.168.1.17 (came from the Arduino code and serial monitor)

I open ARC and took the 192.168.1.17 and put it in the connect and the camera controls,

here is my results:

User-inserted image

this esp32 cam is the easiest one, no wires to connect - just plug in  :-)

https://www.amazon.com/Aideepen-ESP32-CAM-Bluetooth-ESP32-CAM-MB-Arduino/dp/B08P2578LV/ref=sr_1_6?dchild=1&keywords=ESP32+Cam&qid=1612713883&sr=8-6  thanks

EzAng

PRO
Synthiam
#20  

Your version of the esp32 cam doesn’t have as many artifacts and lines in the camera view as @ninks and mine.

mine is pretty distorted often but not as bad as nink’s is. I believe they keep the cost low by using camera components that  don’t pass QA

PRO
USA
#21   — Edited

the esp32 cam I posted above from Amazon works better and clearer then the one I used with the  FTDI adapter and all the wires

check it out

Here is some info on it:

The HK-ESP32-CAM-MB module is a small camera module with a size of 39.8MM*27MM HK-ESP32-CAM-MB adopts Micro USB interface, convenient and reliable connection method, convenient to apply to various IoT hardware terminal occasions HK-ESP32-CAM-MB module can work independently as the smallest system

A new WiFi+Bluetooth dual-mode development board based on ESP32 design, using PCB on-board antenna, with 2 high-performance 32-bit LX6CPU, using 7-level pipeline architecture, main frequency adjustment range 80MHz to 240Mhz Ultra-low power consumption, deep sleep current is as low as 6mA. It is an ultra-small 802.11b/g/n Wi-Fi + BT/BLE SoC module

PRO
Canada
#22  

EzAng looks like he has somewhat more of a self contained solution with short neat wires and then there is mine (and I suspect yours looks about the same as mine DJ) so maybe I am getting a lot of electromagnetic interference. Reading the forums though it says Short wires. Only a single power supply,  remove FTDI, make sure you are close to wifi and run at about 5.3v and lines should disappear.  With that in mind, I tried it and No Lines (see new video).

https://youtube.com/shorts/IFF7pNFF4z0

EzAng

User-inserted image

Mine :-) 

User-inserted image

PRO
Canada
#24  

No Wires ?  OK I guess you could build a Tesla coil but then we are back to the electromagnet interference problem.