def readCommandsFromNeato(): port = rospy.get_param('~port', "/dev/ttyACM0") robot = Botvac(port) doc = "" commands = robot.getAllCommands() for c in commands: com = robot.getCommandDescription(c) doc += "### " + com.command + "\n\n" doc += "**Description:** " + com.description + "\n\n" if len(com.arguments) > 0: doc += "**Options:** \n\n| Flag | Description |\n|------|-------------|\n" for arg in com.arguments: doc += "| " + arg + " | " + com.arguments[arg] + " |\n" doc += "\n\n" robot.exit() return doc