The Diamond Planner machine, designed end to end
A machine that scans a rough diamond in 3D and plans the most valuable stones inside it, using our own gravity-based optimization. We designed all of it: the mechanics, the 6-axis controller board and the software.
Mechanics, electronics and software, all designed by us
The Diamond Planner was designed by one team, from the frame to the motor controller to the planning software, so every part was made to work with the others.
- disciplines, one team
- 3
- motor axes on our own board
- 6
- 01
Mechanical design
The machine itself, built to hold the stone steady and turn it precisely in front of the laser and camera.
- Frame and enclosure
- Scanning chamber and turntable
- Laser and camera mounts
- Stepper-driven motion axes
- 02
Electronics and firmware
Our own 6-axis stepper controller, designed for this machine, and the firmware that runs it.
- STM32F4 for real-time motion control
- Six stepper drivers on the board
- Protected 12–24 V input
- USB-C for power, control and data
- Limit switch, home sensor and encoder inputs
- 03
Software
One desktop app for the whole job, from the first scan to the marked stone.
- Laser-line scanning
- 3D reconstruction of the rough
- Gravity-based stone fitting
- Yield, carats and value for every plan
The challenge
A rough diamond is worth what can be polished out of it. Planning decides which stones to cut from an irregular rough and where to saw it, and a small error in the 3D model or in the plan costs carats. Doing it well takes an accurate scan, precise motion to turn and position the stone, and a planner that finds the most valuable combination of stones.
What we built
We designed the whole machine ourselves. The mechanics: frame, enclosure, scanning chamber, turntable and the mounts for the laser and camera. The electronics: our own 6-axis stepper controller, built around an STM32F4 with the motor drivers on the board, and its firmware. The software: a desktop app that scans the stone by laser-line triangulation, rebuilds it as a 3D surface, plans the polished stones with our own gravity-based optimization and marks the chosen plan.
Engineering highlights
- One team for the mechanics, the electronics and the software, so every part was designed around the others
- Our own 6-axis stepper controller: STM32F4, six stepper drivers on the board, protected 12–24 V input and USB-C
- Inputs for limit switches, home sensors and encoders on the same board
- Laser-line triangulation on a turntable, with the camera view, frame count and turntable angle shown live
- 3D reconstruction of the rough: point cloud, surface normals and a screened Poisson surface
- Our gravity-based optimization for one-stone and multi-stone plans, with saw planes, yield and value
Scan, plan, mark
- 01
Scan
The rough turns on the turntable while a laser line crosses it. The camera records the line in every frame, and the frames become a point cloud and then a closed 3D surface of the stone.
- Point cloud
- Poisson surface
- 3D model of the rough
- 02
Plan
Our gravity-based optimization fits polished stones inside the 3D model, with saw planes between them. Carats, yield and estimated value are shown for every plan, and a plan can be re-run with other stone parameters.
- Stone plan
- Saw planes
- Yield and value
- 03
Mark
The chosen plan is marked on the stone, ready for sawing and polishing, and can be exported.
- Marked stone
- Exported plan
Gravity-based optimization, our own algorithm
Instead of testing positions one by one, our planner lets physics do the search: each stone falls into place inside the scanned rough, then grows until it touches the walls.
Drop
A polished-stone model is dropped into the 3D model of the rough, and gravity settles it into the deepest pocket.
Spin and re-drop
Spinning the rough or dropping the stone again lets it find other resting places, not just the first one.
Grow to fit
The stone grows until it touches the walls of the rough: the largest stone that still fits inside.
Pin and add
The stone is pinned in place, and the next one drops into the space that is left, for multi-stone plans.
Saw planes
Cutting planes mark where the rough will be sawn, and the planner keeps the side that holds the stone.
Yield and value, live
Polished carats, yield and estimated value update with every move.
More work
All work
AI insideAn industrial controller you program by describing it
Our own STM32-based controller and the Shree-Mazu Workbench, which generates and flashes its firmware from a canvas or a plain-English request.
Read the case study
Complex high-speed boards, from our own RAM to AI cards
Our own RAM, SATA III, NVMe M.2 and PCIe SSDs, an AI card and a high-speed single-board computer, on PCBs from 4 to 12 layers, with signal-integrity, eye-diagram and crosstalk reports.
Read the case study
AI insideShree-Mazu Smart Home: design in VR, live in reality
It creates a virtual world with your own home and your own 3D character. Your family sets up lights, scenes and devices there like playing a game, and our AI transfers the result to your real home.
Read the case studyReady to make your machine smarter?
Tell us about the machine you run or the product you imagine. We reply within 24 hours on working days. We sign an NDA before you share details.




