Open hardweb-it opened 1 year ago
After a bit of debug session I found the issue with Cloud mode by reading the json responses:
If cloud account password contain some special chars, such as $ (dollar), those are trimmed from the string, so the login fail. By forcing the password string inside "getcloudpassword.py", I manage to get API working, and then retreive the password which format is like this
:1:1234567890:AbCdEFgHiJKLM2NO6pqR
However, I tried to put that string on Home Assistant to connect with Roomba, but it return "Unable to connect". So I built myself the ./config.ini and by running ./roomba.py that's the log:
[2023-04-06 16:38:53,649][ INFO](Roomba ) *******************
[2023-04-06 16:38:53,650][ INFO](Roomba ) * Program Started *
[2023-04-06 16:38:53,650][ INFO](Roomba ) *******************
[2023-04-06 16:38:53,651][ INFO](Roomba ) Roomba.py Version: 2.0i
[2023-04-06 16:38:53,651][ INFO](Roomba ) Python Version: 3.8.10 (default, Mar 13 2023, 10:26:41) [GCC 9.4.0]
[2023-04-06 16:38:53,653][ INFO](Roomba ) Paho MQTT Version: 1.6.1
[2023-04-06 16:38:53,653][ INFO](Roomba ) CV Version: 4.7.0
[2023-04-06 16:38:53,654][ INFO](Roomba ) PIL Version: 9.5.0
[2023-04-06 16:38:53,654][ INFO](Roomba ) <CNTRL C> to Exit
[2023-04-06 16:38:53,655][ INFO](Roomba ) Roomba MQTT data Interface
[2023-04-06 16:38:53,656][ INFO](Roomba.Password ) Using Password version 2.1
[2023-04-06 16:38:53,657][ INFO](Roomba.Password ) reading/writing info from config file ./config.ini
[2023-04-06 16:38:53,658][ INFO](Roomba.Password ) 1 Roombas Found
[2023-04-06 16:38:53,658][ INFO](Roomba ) Creating Roomba object 192.168.1.152, Roomba
[2023-04-06 16:38:53,659][ INFO](Roomba.Password ) Using Password version 2.1
[2023-04-06 16:38:53,661][ INFO](Roomba.Roomba ) Posting DECODED data
[2023-04-06 16:38:53,663][ INFO](Roomba.Roomba ) MAP: Maps Enabled
[2023-04-06 16:38:53,663][ INFO](Roomba.Roomba ) Connecting...
[2023-04-06 16:38:53,664][ INFO](Roomba.Roomba ) Setting TLS
[2023-04-06 16:38:53,665][WARNI](Roomba.Roomba ) error loading font: %s, loading default font
[2023-04-06 16:38:53,670][ INFO](Roomba.Roomba ) Setting TLS - OK
[2023-04-06 16:38:53,693][ INFO](Roomba.Roomba ) MAP: Not drawing Room Outline
[2023-04-06 16:38:53,708][ INFO](Roomba.Roomba ) MAP: opening existing map_notext.png
[2023-04-06 16:38:53,709][WARNI](Roomba.Roomba ) MAP: unable to load map_notext.png: [Errno 2] No such file or directory: './Roombamap_notext.png': set to None
[2023-04-06 16:38:53,710][ INFO](Roomba.Roomba ) MAP: home_pos: (100,395)
[2023-04-06 16:38:53,710][ INFO](Roomba.Roomba ) MAP: Initialisation complete
[2023-04-06 16:38:53,712][ INFO](Roomba.Roomba ) MAP: loading floorplan: res/first_floor.jpg
[2023-04-06 16:38:53,841][ INFO](Roomba.Roomba ) loaded floorplan: res/first_floor.jpg
[2023-04-06 16:38:55,858][ERROR](Roomba.Roomba ) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed
[2023-04-06 16:38:56,861][ERROR](Roomba.Roomba ) Attempting retry Connection# 0
[2023-04-06 16:38:56,862][ INFO](Roomba.Roomba ) Attempting to Reconnect...
[2023-04-06 16:38:58,945][ERROR](Roomba.Roomba ) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed
[2023-04-06 16:38:59,948][ERROR](Roomba.Roomba ) Attempting retry Connection# 1
[2023-04-06 16:38:59,948][ INFO](Roomba.Roomba ) Attempting to Reconnect...
[2023-04-06 16:39:02,146][ERROR](Roomba.Roomba ) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed
[2023-04-06 16:39:03,148][ERROR](Roomba.Roomba ) Attempting retry Connection# 2
[2023-04-06 16:39:03,149][ INFO](Roomba.Roomba ) Attempting to Reconnect...
[2023-04-06 16:39:05,371][ERROR](Roomba.Roomba ) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed
[2023-04-06 16:40:05,374][ERROR](Roomba.Roomba ) Attempting retry Connection# 3
[2023-04-06 16:40:05,374][ INFO](Roomba.Roomba ) Attempting to Reconnect...
[2023-04-06 16:40:07,797][ERROR](Roomba.Roomba ) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed
I also tried by pressing 2 sec. the Home button (light become blue and rotating), with no luck. Which could be the thing that prevents Roomba to connect with?
Thanks for any suggestion.
There is generally two reasons why you can't connect:
1) Unable to Connect to roomba Roomba, make sure nothing else is connected (app?), as only one connection at a time is allowed 2) Encryption has changed
If it's 1), you have to force close the app on your phone. One HA has connected, you can open the app again, and it will use the cloud connection, instead of the local connection.
If it's 2), it's more of a problem, because the program has to be adapted to the new encryption, and that's hard to do as I don't have an i6 to test it on.
Finally I was able to manage the issue.
That's how (in this exact order):
Before doing all that things, I tried to only change my account password, logout from APP, and get the new one decoded, but anyway the HA connection doesn't worked as excpected.
I think that: Password containing "$" char (and I don't know if this is the only one), will produce a bad decoded password, so it can't working properly. AND moreover my device were stuck/locked for many reasons and only after perform the reset I get the device unlocked and responding correctly to the network.
However, after perform the full process, it goes fine! Hope this can help other people!
Thanks for your time.
Glad you figured it out. The whole "only one thing can be connected at a time" thing is a PITA.
Persistence pays off!
Hello, I'm trying to retrieve password of my Roomba i6 (sku:i615840, and sw:lewis+22.52.5+2023-02-16-7e788e611c3+Firmware-Build+2880) but with no luck.
I tried in more ways with Ubuntu 20 and Python 3.8, and with Win 10 Powershell python 3.9. No one works and get always the same error
Trying with "local mode" using: ./password.py -R ROOMBA_IP_ADDRESS I always get this:
And also tried with Cloud mode with: ./password.py "username" "password"
Any suggestion? Thank you in advance