implemented robot shutdown