Be the first to know.
Get our Manufacturing weekly email digest.

A Journey into Automatic Optical Inspection

Come with us on a journey of integration – from prototype to production – in the narrative framework of fictional company Precision Parts Inc.

author avatar

03 Sep, 2025. 4 minutes read

Imagine being an R&D engineer at Precision Parts Inc., a fictional global manufacturer renowned for its intricate automotive components. Its Quality Assurance Manager – we’ll call her Sarah – comes to you with a significant challenge. The company’s current manual visual inspection process for finished parts is leading to inconsistent quality, slow defect detection, and a concerning amount of material waste due to human error and fatigue. Sarah knows she needs an automated solution that is both precise and efficient, and asks you to find a way to integrate smart technology into the production line. Where would you look?

Luckily, you’ve heard about the Arduino Portenta Proto Kit VE (Vision Environment) and are ready to test its comprehensive capabilities for rapid prototyping in machine vision and environmental monitoring.

Motion, Vision and Environmental Sensing: All in One Kit

For the critical aspect of vision and edge AI, you position a Nicla Vision module – a compact color camera designed for AI on the Edge, included in the kit – directly above the test rig, mounted on a robotic arm. This setup is able to continuously capture images of each component as it moves around the Device Under Test at a speed of 20 frames per second.

To simulate real-world conditions, you create a test rig that mimics the actual inspection station: plastic parts mounted on a bigger component under the camera’s field of view. 

Leveraging the compact form factor of the Nicla, the core of this part of the project involved training a basic convolutional neural network (CNN), designed to identify and classify a range of surface defects. This CNN was specifically engineered to detect critical manufacturing anomalies, including precise mounting positioning, ensuring components are placed correctly and securely, and verifying the existence of all required components, 

Regarding control and actuation, if the AI model detects a defective component, the Nicla Vision is connected to a Portenta H7 through the Portenta Mid Carrier Proto Shield (both included in the kit), instantly triggering a visual alarm. 

The alarm stops the arm indicating the faulty component. To provide an immediate alert to nearby operators, you also decide to incorporate a Buzzer Modulino node (also included in the kit!), which emits an audible signal whenever a defect is identified. 

From Compatibility to Easy Connections

The Portenta Mid Carrier Proto Shield’s compatibility with Arduino UNO shields, Qwiic, and ESLOV connectors made integrating these components straightforward.

Qwiic is an I²C interface that allows users to easily interconnect modules and sensors. 

The Qwiic connector is polarized, so it’s virtually impossible to insert it wrong.

I²C (Inter-Integrated Circuit) is a synchronous, multi-nodes serial communication protocol developed by Philips. It uses two bidirectional open-drain lines: SDA (Serial Data) and SCL (Serial Clock), pulled up with resistors. Devices on the bus are identified by unique 7-bit or 10-bit addresses, and communication is controlled by a master device that initiates data transfers.

For connectivity and cloud integration, your solution can securely transmit all inspection results, including the specific type of defect and the exact timestamp, both to the Arduino Cloud and locally to the production line software management. 

For this, you simply leveraged the 4G GNSS Module Global (included in the Proto Kit VE Kit) to provide high-speed, reliable cellular connectivity supporting 4G and fallbacks to 2G, 3G.

The 4G Module is GNSS compliant and can add relevant info on GPS and other constellations.


Success at Precision Parts Inc.!

Sarah can now see real-time updates on a dashboard pulled up directly via Arduino Cloud for Business – not just on her computer but also on her smartphone. This allows her to monitor quality trends across shifts, get statistics on defect rates, and receive instant notifications if a critical threshold of defects is reached. 

The data collected in the Arduino Cloud also provides invaluable insights, allowing Precision Parts Inc. to continually refine their manufacturing processes. This specific continuous data flow will help Sarah and her team to create a database to train the AI model even further, to achieve greater accuracy over time.

And what if Sarah’s boss wants to have a custom report inside his preferred tool? You’re ready for that, too. Using the APIs available in Arduino Cloud, you can simply push data from the cloud to a local database, and create such report mixing real production data with finance reporting figures.

What’s more, you’ve managed to develop and iterate on this entire automated quality inspection system – from setting up the camera and deploying the AI model to programming the defect detection logic and integrating with the cloud – in days instead of weeks, or perhaps even hours instead of days. 

What’s next? The modular design of the Portenta Mid Carrier and Portenta Mid Carrier Proto Shield make modifying or expanding the hardware simple. So Precision Parts Inc. could seamlessly transition from this functional prototype to full-scale production with minimal redesign efforts. 


This story may be fictional, but the accessibility and flexibility of Arduino’s platform is a reality for thousands of companies like yours, every day.

24,000+ Subscribers

Stay Cutting Edge

Join thousands of innovators, engineers, and tech enthusiasts who rely on our newsletter for the latest breakthroughs in the Engineering Community.

By subscribing, you agree to ourPrivacy Policy.You can unsubscribe at any time.