any chance this is working with one of these alternative boards?
Banana Pi M2 Berry
Banana Pi M5
Radxa Rock 3 A
Radxa Rock 4 C+
my first test with M2 Berry and the 16.04 official image was that the GrovePi is visible via $ sudo i2cdetect -y 2
the grove_rgb_lcd example works with the smbus number changed from 1 to 2.
but i did not get the grovepi.py to work. also i tried with setting it to hw smbus mode and tweaking the di_i2c.py script to use also use the bus ‘2’:
with this i get an exception at line 225
as after the first read the data variable just has a simple 0 in there. (not a list…)
anyone had this running?
i have cross-posted this request at the GrovePi github repro:
sudo pip uninstall RPI.GPIO
git clone https://github.com/BPI-SINOVOIP/RPi.GPIO.git
sudo python setup.py install
# cd ~
# sudo apt remove wiringpi
# # this installs the forked version from https://github.com/WiringPi/WiringPi-Python
# pip install wiringpi
# not needed anymore..
# as we use hw i2c
# tweak grovepi.py
# → to enable HW mode.
# tweak di_i2c.py
# self.i2c_bus = I2C("/dev/i2c-1")
# self.i2c_bus = I2C("/dev/i2c-0")
# remove lines
# import RPi.GPIO as GPIO
# rev = GPIO.RPI_REVISION
# if rev == 2 or rev == 3:
# bus = smbus.SMBus(1)
# so that only this line is there
# bus = smbus.SMBus(0)
@jimrh do you have a link / issue i should report to?
i have no repro for this project explicit - as it is just a test setup.
i am willing to create pull-requests for the GrovePi and RFR_Tools repros -
as these are the points where the board detection in python is failing…
this would need some help from others to cross test on orig RPIs as i do not have access to such…
The best way would be to create a repo for your project and then fork the repositories where you are having problems. You can use the forked repo’s in your project, and as you generate solutions you can generate pull requests from your fork.
Having a project specific repo is good because it allows you to both segregate and share your work with others who may wish to either learn from you, or help add to your efforts.