I try to get the status of the bot since 2 days, but all I get is None.
I'm creating the issue here, since @bmartin5692 doesn't allow issues on his repo?
This error seems to be like #57, but I didn't even see the response, just the commands I sent.
If I do sucks charge, it waits, till the bot finds the dock and charges.
On running Clean(), vacbot.disconnect(wait=True) didn't wait till it finishes cleaning (no idea if this is intended and only waits for starting to clean).
So I assume cli.py can get the status, since it can wait till the bot starts to charge?
import os
import configparser
import itertools
import logging
from sucks import *
config_file = os.path.expanduser('~/.config/sucks.conf')
parser = configparser.ConfigParser()
with open(config_file) as fp:
parser.read_file(itertools.chain(['[global]'], fp), source=config_file)
config = parser['global']
api = EcoVacsAPI(config['device_id'], config['email'], config['password_hash'],
config['country'], config['continent'])
my_vac = api.devices()[0]
vacbot = VacBot(api.uid, api.REALM, api.resource, api.user_access_token, my_vac, config['continent'], monitor=True)
vacbot.connect_and_wait_until_ready()
logger = logging.getLogger('sucks')
logger.setLevel('DEBUG')
#vacbot.run(VacBotCommand("SetWaterPermeability", {"v": "3"}))
vacbot.request_all_statuses()
#vacbot.send_ping()
# Everything bellow returns None
print(getattr(vacbot, 'vacuum_status'))
vacbot.run(GetCleanState())
vacbot.run(GetChargeState())
vacbot.run(GetBatteryState())
# I've tried these a while back, I assume these are wrong anyways
#print(vacbot.run(VacBotCommand("GetError")))
#print(vacbot.run(VacBotCommand("GetChargeState")))
#print(vacbot.run(VacBotCommand("GetBatteryInfo")))
#print(vacbot.run(VacBotCommand("GetVersion", {"name": "FW"})))
#print(vacbot.run(VacBotCommand("GetLog")))
#vacbot.run(Clean()) # start cleaning
vacbot.disconnect(wait=True)
I try to get the status of the bot since 2 days, but all I get is None.
I'm creating the issue here, since @bmartin5692 doesn't allow issues on his repo?
This error seems to be like #57, but I didn't even see the response, just the commands I sent.
If I do
sucks charge, it waits, till the bot finds the dock and charges.On running Clean(),
vacbot.disconnect(wait=True)didn't wait till it finishes cleaning (no idea if this is intended and only waits for starting to clean).So I assume cli.py can get the status, since it can wait till the bot starts to charge?