← Back to Experience

Blister Inspection

Industrial Visual Inspection System • C++/Qt & AI • Proprietary

In the pharmaceutical industry, Quality Control (QC) is critical. A single defective blister pack reaching a consumer can have severe health and legal consequences. This project involved building a high-speed Visual Inspection System designed to redefine precision through the fusion of C++, hardware synchronization, and AI.

700ms Latency per Channel
81.2% Market-Ready Yield
3 Units Industrial Deployment
4+ Types Defects Classified

1. The Challenge: Speed vs. Stability

High-speed production lines present a unique set of engineering hurdles:

2. Architecture: Power Through Decoupling

I implemented the MVVM (Model-View-ViewModel) pattern to decouple the heavy computational backend logic from the modern QML user interface. This separation ensures that the UI remains highly responsive even when the system is processing massive data throughput from high-speed production lines.

MVVM System Architecture
System Architecture: Decoupling Backend Logic from QML UI via MVVM Pattern.

To maximize system reliability, the AI inference engine operates as a separate process managed via QProcess. This architectural choice creates a "sandboxing" effect: even if a complex AI algorithm encounters an unexpected edge case and crashes, the core production line interface remains unaffected, preventing costly industrial downtime.

3. Core Technical Implementations

High-Performance Multithreading

I designed a triple-thread architecture: UI Thread, Image Acquisition Thread, and Command Manager. To prevent race conditions, I utilized QMutex and Signal/Slot with QueuedConnections for thread-safe data transfer.

Low-Latency Raw Image Rendering

Rendering high-resolution RAW frames without UI lag was a major bottleneck. I customized the rendering pipeline by inheriting from QQuickPaintedItem to handle direct C++ coordinate calculations, resulting in seamless Zoom/Pan functionality even during full-speed production.

Hardware Interfacing & Socket Programming

Utilizing the Producer-Consumer pattern, I developed the logic for PLC communication via Sockets. This ensures that every "Eject" signal for a defective product is delivered with microsecond precision.

"A successful industrial system isn't just about the AI model; it's about the stability of the pipeline that delivers data to that model."

4. Key Outcomes