Modelling and control of mechatronic and robotic systems