Method of robot control is disclosed that includes the steps of: providing a user interface for introducing data indicative of a drug to be subjected to a reconstitution process accessing an internal data base for outputting, for a selected drug, a list of primitive movements P1, P2, . . . Pi, . . . Pn to be used in the reconstructing process operating the robot for executing sequentially the primitives and moving a container according to the instructions of the primitives measuring, during the movement of the container under robot action, physical positions in the space and dynamic parameters of the container creating a list of registered data comparing the measured positions in the space and the dynamic parameter with the corresponding ones of the primitive movements for selecting a list of eligible primitives if a sufficient approximation level is reached elaborating selected eligible primitives together to generate instructions for the robot allowing a complex movement encompassing the simple movements and using the robot for shaking the container according to the complex movement.