How to implement pick-and-place on the machine?

Please see this explanation for the solution I was able to put together. Might be late but hope it helps!