> If you (or anyone else) think there shall be any
other sorting options, please tell me. I'm happy to append them
to the PR.
Haven't looked at the PR yet (no time 😭), but of course the best sorting order (short of a real planner solution), would be the part's feeder pick locations.
It is not perfect of course. It ignores nozzle tip changes (as
you said) and does not account for parts with multiple feeders
where one can run out (feeder switch-over), and also not accounts
for feeders with changing pick location (strip feeder, tray etc).
Also it assumes that travel between feeders is much larger than
travel between placement locations, i.e. it blindly favors feeder
co-location optimization over board/panel placement co-location
optimization.
So it is still just a heuristic solution, but it would go a long
way towards optimizing the travel between picks, at least as long
as you start the Job with two identical nozzle tips for the most
numerous parts (passives), and typically those absolutely dominate
the job time, right?
Bonus variant: Go through each nozzle tip. Group all placements that are compatible (some will have multiple takers). Sort by group size, descending. Go through the groups in that order, and remove all but the first taker. Then do 1. 2. 3. as listed above per group, then concatenate the resulting sort order lists. 😎
_Mark
I don't understand, looks perfect to me. Sorted by Y.
Obviously, it only considers feeders that have parts in the placements of the job. So it skips feeders hat remain unused by the job, hence the gaps.
Am I missing something?
_Mark
> the sorting/optimization is done as part the plan-step for every pick/place cycle.
I had no idea! 🙁
> We could move the optimization out of the plan step into the job preparation step
No, I would keep it in the Plan step. But introduce a lazy evaluation flag, whether it is already optimized. If not, do the Travelling Salesman and copy the visit index onto the JobPlacement.
Then in both cases, do the sort by the visit index.
> but void the principle that jobs can be stopped and changed everywhere and continue to run fully optimized
Not if you keep it in the Plan step.
Whenever the job is paused or stopped, void the lazy evaluation
flag. So on resume it will redo the Travelling Salesman with the
fresh/changed data.
_Mark