Restructure, robot hardware class and autocontroller