Variable quantity of products in assembly


I have the following issue, I want to stack 10 plates in a box in the PlateBuffer process. For this I have created an assembly that consists of the box and the plates. Now a mobile robot transports the box from the process (PlateBuffer) with 10 plates to the next process (PlateStack_2) in which the plates are then taken out of the box one by one. The mobile robot transports the box only if it is filled with 10 plates, but I want the mobile robot to transport a variable number between 2 and 10 plates as soon as there are no more plates in the box of the process (PlateStack_2).
My idea was to trigger a while loop in the process (PlateBuffer) with a GetProperty Capacity statement from the process (PlateStack_2) and so interrupt the TransportIn command but I couldn’t get it to work.
Does anyone have an idea how it could work?
The pictures below show the two processes.