Giter Site home page Giter Site logo

Comments (4)

NickWaterton avatar NickWaterton commented on August 14, 2024

Did you run sudo python setup.py install Then you execute by simply entering roomba

The original instructions were written for before the script was packaged for pypi. The script now expects the library to be installed, which is why it’s not found - you haven’t installed it.

The next issue on the RPi3 is that you need opencv installed (it’s one of the pypi requirements), and you can’t install it via pip (don’t know why). You have to build it as described here
https://www.pyimagesearch.com/2016/04/18/install-guide-raspberry-pi-3-raspbian-jessie-opencv-3/

I need to revisit this whole thing, but I didn’t package it for pypi, so I don’t know what exactly changed since I posed the original.

from roomba980-python.

NickWaterton avatar NickWaterton commented on August 14, 2024

Actually, just tried this and it still doesn’t work on a RPi3 (which I have lying around).

I suggest, for now you edit roomba.py, line 25.
from roomba.password import Password

And change it to
from password import Password

Hopefully that should fix it.
The problem is that the script now expects to be installed, but on an RPi one of the dependencies is opencv-python (which would normally be automatically installed via pip), but this doesn’t work on RPi, so the script doesn’t complete installation, so it can’t find the installed module “roomba”.

Let me know if this works, and I’ll see if I can fix it.

Not keen on the whole pypi thing, it sort of makes it easy to install, but it sure messes thing up cross platform...

from roomba980-python.

NickWaterton avatar NickWaterton commented on August 14, 2024

No, just tried that, and seems there are problems if you don’t have opencv or pillow installed, neither of which install properly via pip on an RPi.

Also, if you can’t install the program (because of the RPi pip issues), the program is main.py not roomba.py, roomba.py is the library which is supposed to be installed, main.py gets copied to roomba when it’s installed properly.

Looks like there is some work to be done to get this to work on a RPi, sorry I never tested it on an RPi before. Should not be much to do. I’ll see what I can do.

from roomba980-python.

NickWaterton avatar NickWaterton commented on August 14, 2024

OK,

I have patched the files so that you can run roomba directly without installing on RPI. I don't know how to fix the dependencies issues (but they are not really dependencies, roomba will work just fine without openCV and Pillow - just no maps).

You can install Pillow/OpenCV yourself (just not via pip or apt-get - you have to compile it yourself as you need a recent version of these -less than a couple of years old). There are guides around on how to do this.

Whether you have openCV or PIllow or not, once you have run

git clone https://github.com/NickWaterton/Roomba980-Python.git
cd Roomba980-Python/roomba

Do Not Install the program you can now just run it directly, by running:
./roomba_direct.py

This discovers my roomba on my RPi, but I haven't gone beyond that, as I'm already ruining roomba.py on my Ubuntu server, and only one device at a time can connect to the roomba. Command line option should work as well.

If you manage to install Pillow or openCV, roomba_direct.py should pick them up automatically next time it is run.

I suggest you start with PIL (Pillow) as it's less painful to install than openCV.

from roomba980-python.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.