python3?
Forums:
Hi, am trying to get the Ultraborg working in the latest version of Webiopi, but getting a synthax errors on the print statements from UltraBorg.py when I run it.
I read on the forum that you provided a fixed file for the picoborgrev to a user from the downloads, do you perhaps have a working python3 lib for the UltraBorg too?
Really want to use your board with webiopi ;)
thx!
piborg
Tue, 08/04/2015 - 22:41
Permalink
Python 3 / WebIOPi and UltraBorg
No problem, the fix to the script is fairly simple so I have uploaded a version which should be WebIOPi and Python 3 compatible.
Like with the PicoBorg Reverse, there are two problems:
The first problem is easy to fix, it simply requires a version using the correct print statements
To use this version you will need to change the import statement to
Then you can use it normally.
The second problem is a bit more tricky, what we can do is rebuild smbus for Python 3 by making some small changes to the source:
This should make the smbus module available to Python 3, and hopefully make everything work happily.
You only need to do the smbus module changes once, so if you have already done this for PicoBorg Reverse it can be skipped.
noxgenus
Wed, 08/05/2015 - 22:15
Permalink
Thanks so much piborg :) all
Thanks so much piborg :) all working fine from webiopi now! Moving servo with html/js now, time to order some of those sensors and fill up the board :)
morpfl
Thu, 04/21/2016 - 19:16
Permalink
the link seems to be offline :(
Hello everybody,
i tried the method to get the i2c-dev.h file. Unfortunately, the website is offline.
Is there another link, which I can try?
Thank you,
morpfl
piborg
Fri, 04/22/2016 - 10:19
Permalink
Python 3 and I2C
It looks like this is much easier now on recent copies of Raspbian:
http://www.linuxcircle.com/2015/05/03/how-to-install-smbus-i2c-module-fo...
You should only need to do the following to get the Python 3 smbus module: