Guide
Edge AI in manufacturing runs ML models on microcontrollers at the production line — quality inspection, predictive maintenance, and energy monitoring without sending factory data to external servers. Processing stays local, latency stays under 100 ms, and the system works offline.
Published 2026-04-01
Manufacturing runs on determinism. Production lines need predictable behavior, predictable timing, and predictable data handling. Cloud AI introduces three variables that conflict with these requirements:
Network latency. A quality inspection camera that sends images to the cloud for classification adds 200-2,000 ms per frame. At line speeds of 60+ parts per minute, the part has already passed the reject gate by the time the cloud responds.
Network reliability. A cloud-dependent quality system goes blind when the factory’s internet connection drops. An edge system keeps running. For manufacturers in rural industrial zones or multi-building campuses, connectivity is a real constraint.
Data sovereignty. Vibration patterns from a CNC machine encode spindle speed, feed rate, and tool engagement profiles. Current signatures reveal motor loading patterns. This is process IP. Many manufacturers — particularly in Germany’s Mittelstand — will not send operational data to external cloud services. Edge AI keeps it on-premises.
Manual visual inspection at production line speeds is error-prone. Human inspectors miss 5-15% of defects during sustained operation. The cost of a missed defect escalates at each stage — catching it at station 3 costs $1, at final assembly costs $50, at the customer costs $500+.
A camera mounted above the production line captures images of each part. An MCU with a classification model classifies each image as pass or fail in real time. Failed parts trigger a reject mechanism.
Hardware: ESP32-S3 with a camera module. It is among the most cost-effective MCUs with integrated Wi-Fi, camera interface, and ML acceleration. For simple binary defect detection (part present/absent, label correct/incorrect, obvious surface defects), this is sufficient. Complex defects requiring high-resolution analysis need higher-end edge hardware.
Realistic expectations: MCU-based vision handles binary classification well. It does not handle subtle cosmetic defects, dimensional measurement, or sub-millimeter precision. Know the limits before committing to a deployment.
| Metric | ESP32-S3 | STM32H7 |
|---|---|---|
| Frame rate | 5-10 fps | 3-7 fps |
| Classification latency | 100-200 ms | 80-150 ms |
| Image resolution | 96x96 to 240x240 | 96x96 (DCMI available) |
| Power consumption | ~240 mW | ~400 mW |
Estimated ranges — benchmark on target hardware for production. Performance varies with model architecture and optimization.
The STM32H7 has a DCMI parallel camera interface with DMA support, but lacks the integrated PSRAM of the ESP32-S3, making large image buffers more constrained within its 1 MB SRAM.
The most proven edge AI use case in manufacturing. See our detailed predictive maintenance guide for the full technical breakdown.
In brief: Mount vibration sensors on critical rotating equipment. Train an anomaly detection model on healthy vibration data. Deploy on an ESP32 or STM32F4. The model flags vibration patterns that deviate from the learned baseline, giving maintenance teams days to weeks of advance warning before failure.
Why manufacturers adopt this first: No process integration needed. The monitoring system is completely independent of the production process. You deploy it on one motor today without changing anything about how the factory operates.
Manufacturing facilities consume significant energy, but most lack per-machine monitoring. Without granular data, efficiency improvements are guesswork.
Current transformers on individual motor supply cables feed into MCUs running load classification models. The edge device identifies operating states (idle, running, loaded, overloaded) and detects anomalies — excessive startup current, irregular load patterns indicating mechanical binding.
Hardware: STM32L4 for battery-powered nodes or ESP32-C3 for nodes with Wi-Fi reporting. Models are typically under 20 KB — well within the smallest ML-capable MCUs.
Practical benefit: Identifying one motor running inefficiently (wrong operating point, worn bearings increasing friction, oversized motor at partial load) can save 5-15% of that motor’s energy consumption. Across a facility with 100+ motors, the savings compound.
| Requirement | Edge AI | Cloud AI |
|---|---|---|
| Line-speed inspection | Under 200 ms | 200-2,000 ms latency |
| Works during internet outage | Fully offline | System goes blind |
| Factory data stays on-premises | Data never leaves device | Data transmitted to server |
| No per-inference cost at scale | Hardware is sunk cost | $0.001-0.10 per call |
| PLC integration | GPIO, Modbus, local MQTT | Requires internet roundtrip |
Cloud still has a role in manufacturing AI: model training, fleet-wide dashboarding, historical trend analysis, and model retraining on aggregated data. But the inference — the real-time decision at the production line — belongs at the edge.
Do not start with the most interesting technical challenge. Start with the problem that costs the most money. Talk to the maintenance manager: “What was your last unplanned downtime event, and what did it cost?”
Deploy a single monitoring node on the identified machine. ESP32 with Edge Impulse is the fastest path to a working prototype. Edge Impulse handles training, quantization, and export as a ready-to-compile library.
Collect 2-4 weeks of baseline data before expecting useful predictions. The model needs to learn the machine’s normal operating profile across different loads, shifts, and ambient conditions.
When the model flags an anomaly, have maintenance inspect the machine. Track hit rate: how often does a flagged anomaly correspond to a real issue? Adjust detection thresholds based on this feedback.
Once validated on one machine, replicate to similar machines. The same model architecture works — you may need to retrain per machine if operating conditions differ significantly.
Connect edge AI alerts to existing infrastructure:
“Edge AI replaces our PLC.” No. Edge AI is a monitoring and advisory layer. It does not control machinery. The PLC handles real-time control with its deterministic loop. Edge AI tells maintenance where to look — it does not actuate machines.
“We need thousands of failure examples to train.” No. Anomaly detection models train on normal data only. Collect 1-2 weeks of healthy vibration patterns and the model learns what “normal” looks like. Failures are detected as deviations from that baseline.
“Our machines are too old for AI.” If the machine has a motor, bearing, or any rotating component, a vibration sensor can be mounted externally. Age is irrelevant — the sensor reads the machine’s mechanical signature regardless of the machine’s vintage. Some of the best predictive maintenance ROI comes from monitoring legacy equipment that lacks built-in diagnostics.
Run object detection on STM32H7 with TFLite Micro. 1 MB SRAM, 480 MHz Cortex-M7, CMSIS-NN acceleration for real-time inference.
Deploy predictive maintenance on STM32F4 with TFLite Micro. A widely used Cortex-M4 for cost-effective vibration monitoring in industrial settings.
Deploy vibration-based predictive maintenance on ESP32 with Edge Impulse. Sensor setup, model training, and continuous monitoring guide.
Deploy ultra-low-power anomaly detection on STM32L4 with TFLite Micro. Battery-operated monitoring with shutdown current under 100 nA.
Run object detection on ESP32-S3 with TFLite Micro. Hardware specs, compatibility analysis, getting started guide, and alternatives.
ForestHub is designed to connect sensors to ML models to action outputs — in a visual workflow. One platform, any MCU, no cloud required for inference.
Get Started Free