Getting Started with Adafruit MEMENTO: Python Programmable DIY Camera Board

Published  September 23, 2020   0
Adafruit MEMENTO: Complete Guide

There have been many development boards recently built around the ESP32-S3. Most development boards come with a display, some also include cameras and buttons, and a few have speakers and microphones. Finding one that brings all these components together without compromising on quality has been the real challenge for makers and developers. Keeping all this in mind, we found a dev board that brings everything together in one module, the Adafruit MEMENTO.

With all these features, it makes a perfect choice for our upcoming Smart Home and Wearable Project Challenge, where you can win prizes of up to Rs. 7,00,000. You can also win a development board and some cool goodies just by sharing your project ideas. So don’t forget to check out the Smart Home and Wearable Project Challenge for more details.

So, without waiting any longer, let’s dive into the actual development board.

What Do We Get in the package?

This package is quite simple, containing just one main Memento Dev Board. You can see the unboxing image below.

Adafruit Memento

The board has scratch protection for its camera and display, along with four screw inserts at each corner. The PCB has a square design, placing the display, microphone, speaker, and some buttons on the front side, while the camera, SD card slot, all I/O connections, and an accelerometer are on the back. The boot and restart buttons, along with the Type-C input, are placed on the sides for easy access. All the components have been positioned with practicality in mind. Without a doubt, this board is perfectly made in every way. That was my first impression. Next, let’s take a detailed look at the features of this module.

Adafruit MEMENTO Part Marking Back ViewAdafruit Memento Part Marking Front View

Features of the Adafruit MEMENTO

To make this board outstanding and usable for most applications, it comes packed with a rich set of features:

Feature Description
ESP32-S3 module with 4 MB Flash, 2 MB PSRAM  Dual-core 240MHz Tensilica with Wi-Fi and BTLE.
OV5640 camera module with 72° field of view and auto-focus motor  5MP camera sensor with a built-in JPEG encoder.
1.54" 240x240 Color TFT  For previewing camera images or designing a user interface.
MicroSD card slot Store images or animations on any SPI-capable microSD card. Note: Supports cards up to 32GB capacity.
Two Digital/Analog Stemma Ports JST PH-3 connectors for A0, A1, and power+ground, allowing external buttons, LEDs, or sensors. Can provide 3V or 5V power.
I2C Stemma QT Port Connect almost any I2C sensor with a Stemma QT JST SH port, providing 3.3V power and logic.
LIS3DH Accelerometer A triple-axis accelerometer for detecting orientation, shaking, or movement.
LiPoly battery charging support  Works with a 3.7/4.2V 350mA or 420mA battery for on-the-go snaps.
6 User Buttons Change modes, preview saved images, or even play DOOM (?). Connected through a GPIO expander.
Buzzer Play tones or alerts, or indicate when a photo is successfully taken.
Analog Microphone Can be used as a sensor to detect loud sounds (not for recording video with audio).
Shutter/Boot button Connected to GPIO 0 for entering the ROM bootloader.
Reset button For entering the bootloader or restarting the board.
On/Off switch Cuts all power when using a battery.
USB Type-C For programming the ESP32-S3, REPL access in CircuitPython, and charging the optional LiPoly battery.
Breakout pads for hardware UART For deeper debugging needs, solder wires to the through-hole pads to connect to a console cable.
Four M3 standoffs For mounting or attaching to an enclosure.

On the software side, it can be programmed with both Arduino IDE and CircuitPython. Between CircuitPython and Arduino IDE, CircuitPython is definitely the easier one for coding and interfacing.

Some Applications of Adafruit MEMENTO

Below is the list of some possible applications of this MEMENTO Camera module:

Application Description
Photography:  Digital photos, timelapse, custom effects and filters
Security:  Motion detection, surveillance systems, automated monitoring
IoT Projects: Wireless camera control, remote photo capture, smart home integration
Education:  Learning programming with CircuitPython/Arduino, computer vision experiments
Creative Arts:  Interactive photo booths, art installations, custom camera apps
Development: Prototyping vision applications, testing camera algorithms
Automation: Scheduled photography, event-triggered image capture
Portable Projects: Handheld camera systems, field research documentation
Remote Control: Wireless operation via TouchOSC or custom interfaces
Data Collection: Scientific imaging, environmental monitoring, research projects

Physical Overview of the Memento

Now that you know more about the features of the MEMENTO, let's move to the physical overview, where we take a look at the overall hardware and its pinouts in detail.

Adafruit Memento Front and Back View

Above, you can see the front and back images of the MEMENTO.

Adafruit Memento LCD Display

On the front side of the MEMENTO, the LCD (1.54" 240x240 Colour TFT) takes up most of the space. This is useful for previewing camera images or creating your own user interface design. It uses the ST7789 driver, which is supported by both Arduino and CircuitPython.

It uses the following pins for communication:

Pin GPIO CircuitPython Access Arduino Access
MOSI GPIO35 board.MOSI  MOSI
SCK GPIO36 board.SCK  SCK
MISO GPIO37 board.MISO   MISO
DC GPIO40 board.TFT_DC   TFT_DC
CS GPIO39 board.TFT_CS  TFT_CS
Backlight GPIO45 board.TFT_BACKLIGHT TFT_BACKLIGHT.
Reset GPIO38.  board.TFT_RESET TFT_RESET or TFT_RST.

Adafruit Memento Function Button

There are a total of six buttons for the user interface. These buttons are more than enough for most designs. One thing to note is that these buttons are not directly connected to the ESP32-S3. Instead, they use the AW9523 GPIO Expander. The pin mapping is:

Button Pin
OK button pin 11
Select button pin 1
Up button pin 13
Down button pin 15
Left button pin 14
Right button pin 12

Both the Arduino and CircuitPython PyCamera libraries have built-in support for these buttons, making them easy to use.

Adafruit Memento Function Button

On the front side of the MEMENTO, above the four user buttons, is the analog MEMS microphone, labelled Mic on the board’s silkscreen. It can be used as a sensor to detect loud sounds. It is not intended for recording video with audio.

The analog input from the microphone is connected to GPIO2. It’s accessible in CircuitPython with board. MIC and in Arduino with 2.

Adafruit Memento Speaker Module

Below the TFT display, between two of the user buttons, is the speaker, also labelled Speaker in the silkscreen.

The output from the speaker is connected to GPIO46. It’s accessible in CircuitPython with board.SPEAKER and in Arduino with SPEAKER.

Note: The speaker is muted via pin 0 on the AW9523 GPIO expander, so don’t forget to unmute it before expecting any sound!

Adafruit Memento ESP32 S3

Now, looking at the back side, you’ll find the hero of the dev board:  the Espressif ESP32-S3 with 3.3V logic/power. It has 4MB of Flash and 2MB of PSRAM. This MCU comes with Wi-Fi and BLE, making IoT-related tasks much easier.

Camera Module Adafruit Memento


Next, of course, our attention moves toward the camera module at the center of the board. Unlike other ESP32-CAM modules, this is no ordinary camera. It has a built-in motor that enables the auto-focus feature. And yes, it’s a 5MP sensor with a 72° field of view.

Below the camera connector, there is a jumper to providing 3.3V to the auto-focus motor. You can cut the jumper to disconnect DATA1 from 3.3V and disable auto-focus.

The camera uses the following pins:

VSYNC GPIO5. Accessible in CircuitPython with board.CAMERA_VSYNC and in Arduino with VSYNC_GPIO_NUM.
HREF GPIO6. Accessible in CircuitPython with board.CAMERA_HREF and in Arduino with HREF_GPIO_NUM.
XCLK GPIO8. Accessible in CircuitPython with board.CAMERA_XCLK and in Arduino with XCLK_GPIO_NUM.
PCLK

GPIO11. Accessible in CircuitPython with board.CAMERA_PCLK and in Arduino with PCLK_GPIO_NUM.

PWDN GPIO21. Accessible in CircuitPython with board.CAMERA_PWDN and in Arduino with PWDN_GPIO_NUM.
DATA2  GPIO13. Accessible in CircuitPython with board.CAMERA_DATA2 and in Arduino with Y2_GPIO_NUM.
DATA3  GPIO15. Accessible in CircuitPython with board.CAMERA_DATA3 and in Arduino with Y3_GPIO_NUM.
DATA4  GPIO16. Accessible in CircuitPython with board.CAMERA_DATA4 and in Arduino with Y4_GPIO_NUM.
DATA5  GPIO14. Accessible in CircuitPython with board.CAMERA_DATA5 and in Arduino with Y5_GPIO_NUM.
DATA6 GPIO12. Accessible in CircuitPython with board.CAMERA_DATA6 and in Arduino with Y6_GPIO_NUM.
DATA7 

GPIO10. Accessible in CircuitPython with board.CAMERA_DATA7 and in Arduino with Y7_GPIO_NUM.

DATA8  GPIO9. Accessible in CircuitPython with board.CAMERA_DATA8 and in Arduino with Y8_GPIO_NUM.
DATA9  GPIO7. Accessible in CircuitPython with board.CAMERA_DATA9 and in Arduino with Y9_GPIO_NUM.
RESET  GPIO47. Accessible in CircuitPython with board.CAMERA_RESET and in Arduino with RESET_GPIO_NUM.

We already know there’s a heavy demand for the peripherals we’ve seen above, so the MEMENTO includes the AW9523 GPIO Expander IC to provide additional GPIO pins. You can spot this IC near the camera, specifically to the left of the camera module.

The I2C address of the GPIO expander (AW9523) is 0x58.

GPIO Expander and Accelerometer Memento

Near the AW9523, there is a LIS3DH Accelerometer. It’s a triple-axis accelerometer that can detect orientation, shaking, or movement. It communicates over I2C at address 0x19. Its interrupt (IRQ) pin is connected to GPIO3, which is accessible in CircuitPython with board.IRQ and in Arduino with 3.

JST-PH Connectors Memento

For user I/O, there are two JST-PH connectors on the left side of the board, labelled A0 and A1. These are 3-pin JST connectors that can be used for sensors, NeoPixels, or analog input/output.

  • A0 is connected to GPIO17 (accessible in CircuitPython with board.A0 and in Arduino with A0).

  • A1 is connected to GPIO18 (accessible in CircuitPython with board.A1 and in Arduino with A1).

You don’t need to worry about voltage on these pins, as they can be configured to either 3.3V or 5V. By default, they provide 5V. Between the two connectors is a jumper labelled 5V3. This jumper can be cut and re-soldered to switch the VCC signal from 5V to 3V.

I2C Connector Memento

Between A0 and A1, you’ll find a tiny connector labelled I2C on the silkscreen. This is a 4-pin Stemma QT connector. The I2C lines have pull-ups to 3.3V.

  • SDA – GPIO34

  • SCL – GPIO33

In an Arduino, you can use this connector with a wire. In CircuitPython, you can use it with board.SCL, board.SDA, board.I2C(), or board.STEMMA_I2C().

SD Card Slot Memento

Towards the bottom-left corner on the back of the MEMENTO is the microSD card slot. It can be used to store images or animations on any SPI-capable microSD card.

  • SDCS (chip select pin) – connected to GPIO48. Accessible in CircuitPython with board.CARD_CS and in Arduino with SD_CS or SD_CHIP_SELECT.

  • SDCD (card detect pin) – connected to pin 9 on the AW9523.

NeoLED, Switch and Buttons Memento

Along the top edge of the board are two buttons:

  1. The Boot button, labelled Boot and Shutter on the silkscreen, is connected to GPIO0. Accessible in CircuitPython with board.BUTTON and in Arduino with SHUTTER_BUTTON. Hold it while pressing reset to enter ROM bootloader mode.

  2. The Reset button, labelled RST on the silkscreen, is connected to the ESP32-S3 reset pin. Press once to restart your firmware, or press again after about half a second to enter bootloader mode.

To the right of the boot button is the NeoPixel. This addressable RGB LED works as a status LED (in CircuitPython and the bootloader) and can also be controlled with code. It’s connected to GPIO1, accessible in CircuitPython with board.NEOPIXEL and in an Arduino with PIN_NEOPIXEL or NEOPIXEL_PIN.

On the top-right edge of the board is the On/Off switch, labelled On on the silkscreen. This sliding switch cuts all power to the board.

To the right of the switch is the power LED, a green LED that lights up whenever the board has power.

NeoLED, Switch and Buttons on Memento

USB-C port Used for both powering and programming the board. Any USB-C cable will work. When plugged in, it also charges the LiPoly battery.
LiPoly connector/charger A JST 2-PH port for plugging in any 350mAh or larger 3.7/4.2V LiPoly battery. The MEMENTO can run from the battery and charge it while USB is plugged in. The board silkscreen includes an outline sized perfectly for the 420mAh battery available in the shop.
Battery Monitor Pin Monitor battery percentage via an ADC pin, accessible in CircuitPython with board.BATTERY_MONITOR and in Arduino with BATT_MONITOR.
Power Selection Jumper Located above the TFT display ribbon cable. It selects whether the 2.8V supply is powered from 3.3V or 5V. You can cut and re-solder it to switch to 5V.

With this, we’ve completed the physical overview of the MEMENTO. Next, to make using the MEMENTO simpler, we’ll look at some official resources to get started.

Official Resources Available for Exploring Memento

Unlike other Adafruit modules, this dev board is also perfectly documented to get started. You can begin by referring to the Adafruit MEMENTO Camera Board .

In this article, you will find: Overview, Pinouts, Installing CircuitPython, microSD Card Formatting, Notes, CircuitPython MEMENTO Starter Projects, Frames to GIFs, Arduino IDE Setup, Arduino MEMENTO Library Installation and Starter Projects, Factory Reset, and Downloads.

Hopefully, these resources will be all you need. Next, let’s do a quick exploration of Memento using the Arduino IDE. If you wish, you can also go with CircuitPython.

Getting Started with MEMENTO (Arduino IDE)

With a dedicated board selection and library already available for this module, the first test program is quite simple.

Setting Up

There are three primary steps needed to set up the Arduino environment:
1. Update the ESP32 Board Library to the latest version.

Update the ESP32 Board Library

2. Install the Adafruit PyCamera Library along with all dependencies. Even if you already have most of them installed, enabling this option will update the existing ones or install the missing ones.

Install the Adafruit PyCamera

3. Uploading the Example Code
Once installed, navigate to the Examples folder. You’ll find two sketches:

Selection of Example Programs

Differences Between Pycamera_test and Memento_factory_test,

Analog readings: Pycamera_test reads both A0 and A1, while Memento_factory_test only reads A0.
OK button: Does nothing in Pycamera_test; cycles through ring light colors in Memento_factory_test.
SEL button:  Does nothing in Pycamera_test; adjusts ring light brightness in Memento_factory_test.
Ring light control:  Not present in Pycamera_test; fully implemented in Memento_factory_test.
Interrupt handling:  Missing in Pycamera_test; IRQ pin 3 interrupt added in Memento_factory_test.
Ring light variables:  Absent in Pycamera_test; includes color array and brightness control in Memento_factory_test.

The ring light is an optional attachment for this board. If you have it, you can use these extra features. Otherwise, both examples provide the same basic camera functions, but Memento_factory_test includes extra testing features.

4. Board Selection

  1. Connect the MEMENTO Dev Board to your PC.

  2. Hold the Boot button and press the Reset button once. This puts the board into upload mode.

  3. In Arduino IDE, select:
    Board → ESP32 → Adafruit PyCamera S3

Selecting Adafruit PyCamera S3
Now, click Compile and Upload. The code will be uploaded to your MEMENTO board.

Using the PyCamera

By default, the captured image won’t be stored unless you insert an SD card.

Note: The Arduino SD library supports both FAT16 and FAT32 filesystems, so format your SD card accordingly.

Once the SD card is inserted, you can take pictures by pressing the Shutter button at the top right.

And there is two extra feature ,

Color Filters – Use the Left and Right buttons to cycle through filters:

  1. Normal/None

  2. Black & White

  3. Sepia

  4. Negative

  5. Greenish

  6. Reddish

  7. Bluish

Resolution Adjustment – Use the Up and Down buttons to change image resolution. Available options:

QQVGA: 160×120
QVGA: 320×240
HVGA: 480×320
VGA: 640×480
SVGA: 800×600
XGA:  1024×768
HD: 1280×720
SXGA: 1280×1024
UXGA: 1600×1200
QXGA: 2048×1536
QSXGA: 2560×1920

The resolution of the images can be adjusted in real time.

After a deep dive into the Adafruit MEMENTO, it's clear why we chose this board for this year's contest. It's not just another ESP32 camera module-it’s a way to combine your creativity and skills into a fun project. This article gives you a basic idea of its features, and we can’t wait to see your innovative ideas for this year’s contest! 

To help you get going, check out this sample project: IoT Window Bird Feeder with Camera. This project uses 3D printing along with IoT on Adafruit IO, making it a great source of inspiration.

Add New Comment

Login to Comment Sign in with Google Log in with Facebook Sign in with GitHub