Comments (19)
You mean i7 as in the processor? That has nothing to do with your issue.
You need to check carefully your pre-reqs (python versions, paho mqtt version etc.)
Can you show your output?
from roomba980-python.
i7 and i7+ are new models. i7+ is just i7 with a dirt bin base.
Here is the output I'm getting:
[I 2018-10-05 14:13:51,435] *******************
[I 2018-10-05 14:13:51,436] * Program Started *
[I 2018-10-05 14:13:51,436] *******************
[I 2018-10-05 14:13:51,436] Roomba.py Version: 1.2.3
[I 2018-10-05 14:13:51,436] Python Version: 3.5.3 (v3.5.3:1880cb95a742, Jan 16 2017, 15:51:26) [MSC v.1900 32 bit (Intel)]
[I 2018-10-05 14:13:51,436] Paho MQTT Version: 1.4.0
[I 2018-10-05 14:13:51,436] CV Version: 3.4.3
[I 2018-10-05 14:13:51,437] PIL Version: 5.3.0
[I 2018-10-05 14:13:51,437] to Exit
[I 2018-10-05 14:13:51,437] Roomba 980 MQTT data Interface
[I 2018-10-05 14:13:51,437] reading info from config file ./config.ini
[W 2018-10-05 14:13:51,437] No roomba or config file defined, I will attempt to discover Roombas, please put the Roomba on the dock and follow the instructions:
[I 2018-10-05 14:13:51,437] Using Password version 1.2.2
waiting on port: 5678 for data
[W 2018-10-05 14:13:51,438] supplied address 255.255.255.255 does not match discovered address 192.168.2.116, using discovered address...
[W 2018-10-05 14:13:51,517] supplied address 255.255.255.255 does not match discovered address 192.168.2.12, using discovered address...
json decode error: the JSON object must be str, not 'bytes'
RECEIVED: %s (b'{"ver":"3","hostname":"iRobot-E21988B837404711A2301616CC00009C","robotname":'
b'"Roomba","robotid":"E21988B837404711A2301616CC00009C","ip":"192.168.2.12","m'
b'ac":"50:14:79:0F:1A:26","sw":"lewis+1.2.7+lewis-day-0-ota+9","sku":"i755020"'
b',"nc":0,"proto":"mqtt","cap":{"binFullDetect": 1, "dockComm": 1, "maps": 3, '
b'"edge": 0, "area": 1, "eco": 1, "multiPass": 2, "pose": 1, "pp": 0, "5ghz": '
b'1, "prov": 3, "sched": 1, "svcConf": 1, "ota": 2, "log": 2}}')
No Roombas found, try again...
[I 2018-10-05 14:14:01,519] reading info from config file ./config.ini
[E 2018-10-05 14:14:01,520] No Roombas found! You must specify RoombaIP, blid and roombaPassword to run this program, or have a config file, use -h to show options.
from roomba980-python.
from roomba980-python.
Thx so much.
I'm using this on windows but have a nas box that can run docker which can give this a try on Python 2.7
from roomba980-python.
from roomba980-python.
Hello,
I got a bit further with Python 2.7. However, it says BLID = None
c:\Python27>python2 -m roomba -R 192.168.2.109
[I 2018-10-06 15:23:49,653] *******************
[I 2018-10-06 15:23:49,653] * Program Started *
[I 2018-10-06 15:23:49,653] *******************
[I 2018-10-06 15:23:49,653] Roomba.py Version: 1.2.3
[I 2018-10-06 15:23:49,653] Python Version: 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:53:40) [MSC v.1500 64 bit (AMD64)]
[I 2018-10-06 15:23:49,653] Paho MQTT Version: 1.2.3
[I 2018-10-06 15:23:49,653] CV Version: 3.4.3
[I 2018-10-06 15:23:49,653] PIL Version: 5.3.0
[I 2018-10-06 15:23:49,653] to Exit
[I 2018-10-06 15:23:49,653] Roomba 980 MQTT data Interface
[I 2018-10-06 15:23:49,653] reading info from config file ./config.ini
[W 2018-10-06 15:23:49,653] No roomba or config file defined, I will attempt to discover Roombas, please put the Roomba on the dock and follow the instructions:
waiting on port: 5678 for data
found 1 Roomba(s)
Make sure your robot (Roomba) at IP 192.168.2.109 is on the Home Base and powered on (green lights on). Then press and hold the HOME button on your robot until it plays a series of tones (about 2 seconds). Release the button and your robot will flash WIFI light.
Press Enter to continue...
Received: {
"robotname": "Roomba",
"sku": "i755020",
"nc": 1,
"ver": "3",
"proto": "mqtt",
"ip": "192.168.2.109",
"hostname": "iRobot-E21988B837404711A2301616CC00009C",
"sw": "lewis+1.2.7+lewis-day-0-ota+9",
"robotid": "E21988B837404711A2301616CC00009C",
"mac": "50:14:79:0F:1A:26",
"cap": {
"pp": 0,
"sched": 1,
"log": 2,
"ota": 2,
"area": 1,
"binFullDetect": 1,
"prov": 3,
"maps": 3,
"pose": 1,
"eco": 1,
"dockComm": 1,
"edge": 0,
"svcConf": 1,
"multiPass": 2,
"5ghz": 1
}
}
Roomba (Roomba) IP address is: 192.168.2.109
blid is: None
Password=> xxx <= Yes, all this string.
Use these credentials in roomba.py
[I 2018-10-06 15:24:33,819] reading info from config file ./config.ini
[I 2018-10-06 15:24:33,821] Success! 1 Roombas Found!
[I 2018-10-06 15:24:33,821] Creating Roomba object 192.168.2.109
[I 2018-10-06 15:24:33,822] connecting Roomba 192.168.2.109
[W 2018-10-06 15:24:33,822] CSS file not found, creating ./style.css
[W 2018-10-06 15:24:33,828] html file not found, creating ./Roombaroomba_map.html
No handlers could be found for logger "roomba.main"
Traceback (most recent call last):
File "C:\Python27\lib\runpy.py", line 174, in run_module_as_main
"main", fname, loader, pkg_name)
File "C:\Python27\lib\runpy.py", line 72, in run_code
exec code in run_globals
File "C:\Python27\lib\site-packages\roomba_main.py", line 590, in
main()
File "C:\Python27\lib\site-packages\roomba_main.py", line 572, in main
myroomba.connect()
File "C:\Python27\lib\site-packages\roomba\roomba.py", line 290, in connect
if not self._connect():
File "C:\Python27\lib\site-packages\roomba\roomba.py", line 320, in _connect
if exc_type == socket.error or exc_type == ConnectionRefusedError:
NameError: global name 'ConnectionRefusedError' is not defined
from roomba980-python.
Few simple changes get the library working with the i7
First:
Hostname is now iRobot - previously iRoomba
"hostname": "iRobot-E21988B837404711A2301616CC00009C",
Change:
password.py line 117
if hostname[0] == 'Roomba':
blid = hostname[1]
to
if hostname[0] == 'Roomba' or hostname[0]=='iRobot':
blid = hostname[1]
Second:
Password return now a null string attached to the end which needs to be removed.
password.py line 171
password = str(data[7:].decode())
Change to
password = str(data[7:]).partition(b'\0')[0]
Using python partition to split on the null return and take all the string before.
(in my usage I don't use decode - which may impact this)
Works with both i7 and 980.
Glenn
from roomba980-python.
Thanks for that, Is there still a python 3.5 issue?
from roomba980-python.
I've pushed a fixed version - can you try the password discovery out in python 3.5 again? (I think I fixed the 3.5 issue as well). Just rename your .ini file and try again.
from roomba980-python.
Will do after I get home today.
from roomba980-python.
Hi Nick,
I tried to do an upgrade to Roomba980-python via:
pip3 install git+https://github.com/NickWaterton/Roomba980-Python.git
the console is saying there is no upgrade....
Tried using:
pip3 install Roomba980-Python==1.1.2
But console says the current version is 1.2.1 which is what I already have...
from roomba980-python.
Yes, this is because I don't maintain the PyPi version of this (was packaged by someone else).
I have updated the pip version to 1.2.2, see if that upgrades now.
from roomba980-python.
Ok, it got further in Python 3.5, but not as far as Python 2.7, here is what I'm getting:
[I 2018-10-09 20:15:52,909] *******************
[I 2018-10-09 20:15:52,909] * Program Started *
[I 2018-10-09 20:15:52,910] *******************
[I 2018-10-09 20:15:52,910] Roomba.py Version: 1.2.3
[I 2018-10-09 20:15:52,910] Python Version: 3.5.3 (v3.5.3:1880cb95a742, Jan 16 2017, 15:51:26) [MSC v.1900 32 bit (Intel)]
[I 2018-10-09 20:15:52,910] Paho MQTT Version: 1.4.0
[I 2018-10-09 20:15:52,910] CV Version: 3.4.3
[I 2018-10-09 20:15:52,910] PIL Version: 5.3.0
[I 2018-10-09 20:15:52,910] to Exit
[I 2018-10-09 20:15:52,911] Roomba 980 MQTT data Interface
[I 2018-10-09 20:15:52,911] reading info from config file ./config.ini
[W 2018-10-09 20:15:52,911] No roomba or config file defined, I will attempt to discover Roombas, please put the Roomba on the dock and follow the instructions:
waiting on port: 5678 for data
supplied address 255.255.255.255 does not match discovered address 192.168.2.116, using discovered address...
supplied address 255.255.255.255 does not match discovered address 192.168.2.109, using discovered address...
found 1 Roomba(s)
Make sure your robot (Roomba) at IP 192.168.2.109 is on the Home Base and powered on (green lights on). Then press and hold the HOME button on your robot until it plays a series of tones (about 2 seconds). Release the button and your robot will flash WIFI light.
Press Enter to continue...
Received: {
"sku": "i755020",
"robotid": "E21988B837404711A2301616CC00009C",
"ip": "192.168.2.109",
"cap": {
"maps": 3,
"prov": 3,
"edge": 0,
"ota": 2,
"5ghz": 1,
"sched": 1,
"svcConf": 1,
"binFullDetect": 1,
"log": 2,
"multiPass": 2,
"pp": 0,
"area": 1,
"dockComm": 1,
"eco": 1,
"pose": 1
},
"sw": "lewis+1.2.7+lewis-day-0-ota+9",
"ver": "3",
"nc": 0,
"robotname": "Roomba",
"mac": "50:14:79:0F:1A:26",
"hostname": "iRobot-E21988B837404711A2301616CC00009C",
"proto": "mqtt"
}
Roomba (Roomba) IP address is: 192.168.2.109
Traceback (most recent call last):
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\runpy.py", line 193, in run_module_as_main
"main", mod_spec)
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\runpy.py", line 85, in run_code
exec(code, run_globals)
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\site-packages\roomba_main.py", line 590, in
main()
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\site-packages\roomba_main.py", line 485, in main
Password(file=arg.configfile)
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\site-packages\roomba\password.py", line 39, in init
self.get_password()
File "C:\Users\Hilman\AppData\Local\Programs\Python\Python35-32\lib\site-packages\roomba\password.py", line 173, in get_password
password = str(data[7:]).partition(b'\0')[0].decode() #for i7 - has null termination
TypeError: Can't convert 'bytes' object to str implicitly
from roomba980-python.
Bloody bytes vs string I'm sure the python 3 people had a good reason for it but...
Anyway, pushed another fix, see how far it gets this time.
from roomba980-python.
Thx, I tried to do a upgrade using pip but I guess the version wasn't updated...?
EDIT: I did a downgrade and then upgrade, so this is working with python 3.5 which is great.
from roomba980-python.
this is what I get with the I7:
Connection Error EOF occurred in violation of protocol (_ssl.c:590)
Traceback (most recent call last):
File "./getpassword.py", line 39, in
main()
File "./getpassword.py", line 34, in main
Password(file=arg.configfile)
File "/Users/gemasantamaria/Documents/Roomba980-Python-master/roomba/password.py", line 39, in init
self.get_password()
File "/Users/gemasantamaria/Documents/Roomba980-Python-master/roomba/password.py", line 136, in get_password
wrappedSocket.send(packet)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ssl.py", line 687, in send
v = self._sslobj.write(data)
ssl.SSLError: [SSL: SSL_HANDSHAKE_FAILURE] ssl handshake failure (_ssl.c:1647)
from roomba980-python.
I would need to know a lot more. What OS is this? what is the full output?
Your libraries are probably out of date, especially if you are using python 2.7, many libraries (eg ssl) have not been updated in a long time.
It's possible that Roomba has implemented some new SSL security, but this would be the first time if they have.
Of course, the other possibility is that you already have a device connected to the Roomba (the app for instance). This is what causes 99% of the failures with Roomb.py connections.
This is a function of the Roomba itself, it only allows one connection at a time, so if the app is connected, nothing else can connect, and you get errors like this.
The app can still be connected even if it's closed.
from roomba980-python.
I have Macos Mojave 10.14.6, I am using python 3.7 the last one.
I have already tried again, turning off my mobile phone to be sure the app it is not runing, but I got the same error, please sorry for mi ignorance I do not know nothing about python I saw a youtube video to do this with terminal.
This is the message I get
Make sure your robot (Roomba) at IP 192.168.1.67 is on the Home Base and powered on (green lights on). Then press and hold the HOME button on your robot until it plays a series of tones (about 2 seconds). Release the button and your robot will flash WIFI light.
Press Enter to continue...
Received: {
"robotname": "Roomba",
"sku": "i755840",
"nc": 0,
"ver": "3",
"proto": "mqtt",
"ip": "192.168.1.67",
"hostname": "xxxxxxxx",
"sw": "lewis+1.6.6+lewis-day-0-ota+29",
"robotid": "xxxxxxxxx",
"mac": "50:14:79:06:49:06",
"cap": {
"pp": 0,
"svcConf": 1,
"sched": 1,
"log": 2,
"ota": 2,
"area": 1,
"binFullDetect": 1,
"prov": 3,
"maps": 3,
"pose": 1,
"eco": 1,
"dockComm": 1,
"edge": 0,
"team": 1,
"multiPass": 2,
"5ghz": 1
}
}
Roomba (Roomba) IP address is: 192.168.1.67
Connection Error EOF occurred in violation of protocol (_ssl.c:590)
Traceback (most recent call last):
File "./getpassword.py", line 39, in
main()
File "./getpassword.py", line 34, in main
Password(file=arg.configfile)
File "/Users/gemasantamaria/Documents/Roomba980-Python-master/roomba/password.py", line 39, in init
self.get_password()
File "/Users/gemasantamaria/Documents/Roomba980-Python-master/roomba/password.py", line 136, in get_password
wrappedSocket.send(packet)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ssl.py", line 687, in send
v = self._sslobj.write(data)
ssl.SSLError: [SSL: SSL_HANDSHAKE_FAILURE] ssl handshake failure (_ssl.c:1647)
Thanks for your help
from roomba980-python.
zhouF96@ede7e95 fixed the SSL handshake for me
from roomba980-python.
Related Issues (20)
- Using app at same time HOT 1
- It seems that .split(',') is missing to support GET call with multiple regions
- Is the a way to sync user_pmapv_id between local and cloud?
- Getting an error when running this on python 3.10 HOT 3
- I Can't access to the REST interface on my LAN HOT 3
- Getting your username/blid and password from the iRobot cloud HOT 2
- Creating mapping data on i3 without cloud HOT 1
- How to control my roomba HOT 1
- SSL: unsafe legacy renegotiation disabled HOT 2
- Docker image?
- Unable to retrieve password for i6 HOT 5
- Roomba i9 send_region_command not working
- DeprecationWarning: ssl.SSLContext() without protocol argument is deprecated. HOT 12
- Error: 403, {"message":"Signature not yet current: 20230804T000000Z is still later than 20230803T172233Z (20230803T171733Z + 5 min.)"}
- Even after i factory reset the roomba it shows number of mission and time it cleaned in app
- Can't get username/blid and password from iRobot cloud - urllib3.packages.six.moves error HOT 2
- ValueError: check_hostname requires server_hostname with Roomba password.py HOT 13
- mapUploadAllowed: true HOT 1
- Problem getting Password HOT 3
- argument -m (--drawmap) not working HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from roomba980-python.