用于控制iRobot Roomba 980的Python客户端(通过Rest980)
pydorita的Python项目详细描述
此库为iRobot Roomba 980 Rest网关提供Python绑定 从https://github.com/koalazak/rest980
示例
frompydoritaimportPyDoritaClient# Connect to the REST980 gatewaypd=PyDoritaClient(hostname='rest980-gw.lan',port=3000,username='roomba',password='R0mB!')# Get the current state (ie. "run", "stuck" etc.)pd.phase# Get the current error codepd.error# Get the current battery percentagepd.battery# Get the current positionpd.position# Start cleaningpd.clean()# Stop and dockpd.stop_and_dock()