Automation Project (NDA Signed)
A real-time automation system I built at Vitrosens Biotechnology: machine-vision object detection driving axis motors over EtherCAT, in Rust and Python on a Raspberry Pi, with a TypeScript and FastAPI interface. It was built under a confidentiality agreement, so this covers the engineering, not the product or its purpose.
- Rust
- Python
- TypeScript
- FastAPI
- Raspberry Pi
- EtherCAT
Summary. A real-time automation system that pairs machine-vision object detection with axis-motor motion control. A fast detection pass followed by an accurate one cut a typical job from about 40 seconds to about 10, and the detection model went from 67% to 94% accuracy, then wrapped in handlers and retries that have not hit a failure case in operation. It is written in Rust and Python with a TypeScript and FastAPI interface, running on a Raspberry Pi over EtherCAT.
Software that operates the physical world
The system senses, decides, and acts in a loop: machine-vision sensors and a machine-learning model detect objects, the software decides what to do, and axis motors move accordingly, with the moving parts tied together over EtherCAT. I wrote the control and detection in Rust and Python, with a TypeScript and FastAPI interface for operators and for handling the detected objects. It runs on a Raspberry Pi today, with a move to dedicated chips planned.
Quick first, then accurate
Detection runs in two passes, back to back. A fast pass locates candidates immediately, and an accurate pass confirms them. Doing the cheap work first and the careful work only where it is needed cut a typical job from about 40 seconds to about 10.
From 67% to no failures yet
The detection model started at 67% accuracy. I brought it to 94%, then wrapped it in handlers and retries that catch the remaining edge cases, and so far no failure case has been seen in operation. On a separate operation, the same approach cut failure cases by around 60%, which also brought completion times down.
Built to move to hardware
Rust and Python keep the time-critical parts fast and the rest quick to change, and it runs on modest hardware, a Raspberry Pi, with a path to dedicated chips. The operator side is TypeScript and FastAPI.
This project was built under a confidentiality agreement. It describes the engineering only, not the product, the client, or its purpose.
Questions
Why detect in two passes instead of one?
A single accurate pass is slow. A fast pass finds candidates immediately and an accurate pass confirms them, so the careful work only runs where it is needed. Together they cut a typical job from about 40 seconds to about 10.
How reliable is the detection?
The model improved from 67% to 94% accuracy, and handlers and retries cover the remaining edge cases, so no failure case has been seen in operation. On a separate operation the same approach cut failure cases by around 60%.
What can you share about it?
The engineering only. It was built under a confidentiality agreement, so the product, the client, and its purpose stay private.