Skip to main content
Version: FILS English

Thermal Imaging Embedded System (STM32 + MLX90640)

A portable handheld thermal camera that captures, processes, and displays live infrared data in real time.

info

Description

This project is a battery-powered embedded thermal imaging system built on STM32, using the MLX90640 (32x24 IR array) to capture temperature frames and render them on a TFT display.

Motivation

I chose this project because it combines real-time data acquisition, embedded data processing, and graphical rendering in a single portable system. It is a practical and technically challenging alternative to simpler IoT projects.

Architecture

Main software and system components:

  • Sensor Acquisition Module: reads raw IR frames from MLX90640 over I2C.
  • Processing Pipeline: calibration, normalization, temperature-to-color mapping.
  • Rendering Engine: draws thermal image and overlays on TFT display.
  • Storage Manager: saves captured frames to microSD.
  • UI Controller: joystick-driven menus and capture actions.
  • Communication Module (optional): sends frames to mobile app via WiFi.

How components connect:

MLX90640 Sensor
|
| I2C
v
Sensor Acquisition Module
|
v
Processing Pipeline
|
+---------------------> Storage Manager (microSD)
|
+---------------------> Communication Module (WiFi -> Mobile App)
|
v
Rendering Engine -> TFT Display
^
|
UI Controller (Joystick)

Log

Week 5 - 11 May

  • Initial idea was a reflex-based system.
  • Pivoted to thermal imaging after feedback.
  • Selected MLX90640 as core sensor.
  • Studied MLX90640 communication and frame format.

Week 12 - 18 May

  • Defined system blocks and data flow.
  • Selected peripherals: TFT display, microSD, joystick, optional WiFi.
  • Planned local processing pipeline (normalization and color mapping).

Week 19 - 25 May

  • Planned hardware integration order.
  • Planned first bring-up tests for I2C communication with MLX90640.
  • Planned display pipeline validation with test frames.

Hardware

The system uses an STM32 NUCLEO-U545RE-Q for development, an MLX90640 thermal sensor, a TFT display for visualization, a microSD module for storage, and a joystick for navigation. An ESP8266/ESP32 module can be added for WiFi transfer to a mobile app.

Schematics

MLX90640 (I2C)STM32 NUCLEO-U545RE-QMain ControllerTFT Display (SPI)microSD (SPI)Joystick + WiFi (UART)

Bill of Materials

DeviceUsagePrice
STM32 NUCLEO-U545RE-QMain controller125 RON
MLX90640Thermal sensor (32x24 IR array)~150 RON
TFT DisplayReal-time thermal visualization~40 RON
microSD ModuleFrame storage~15 RON
Joystick ModuleMenu navigation and input~10 RON
ESP8266/ESP32Optional WiFi communication~25 RON
Battery / Power BankPortable power supply~50 RON
Misc. Wires and ConnectorsIntegration accessories~50 RON

Software

LibraryDescriptionUsage
embassy-stm32Async HAL for STM32Hardware access for I2C/SPI/UART/GPIO
embassy-executorAsync task executorSchedules concurrent firmware tasks
embassy-timeEmbedded timersFrame timing and periodic operations
embedded-halHAL traitsDriver abstraction across peripherals
mlx9064xMLX90640 driverSensor frame acquisition and temperature extraction
embedded-graphics2D drawing libraryRendering thermal pixels and UI overlays
st7735-lcd / ili9341TFT display driversSending rendered buffers to the display
heaplessNo-std data structuresFixed-capacity buffers without allocator
embedded-sdmmcFAT filesystem supportSaving captured thermal frames
expressNode.js web frameworkLightweight API backend for mobile add-on
multer / sharpUpload and image processingFrame upload handling and optional JPEG encoding
expo-image / expo-media-libraryReact Native media toolsDisplay and save captured images on mobile
axiosHTTP clientAPI communication from mobile app
zustandState managementLocal app state for stream/history/settings
  1. OpenTemp Thermal Imager Project
  2. mlx9064x crate documentation
  3. Embassy framework
  4. MLX90640 Datasheet Page
  5. Project Inspo