Added function to execute arm trajectories.