Packing white and red capsules in a sorting machine