02-18-2017, 12:16 PM
(02-18-2017, 06:49 AM)JasperBrown Wrote: [ -> ]- pip(ed) the Rasp.Pi GPIO
Whit the above line, you seem to try to compile RaspberryPi version, not the A64.
(02-18-2017, 06:49 AM)JasperBrown Wrote: [ -> ]- pip(ed) the Rasp.Pi GPIO
(02-18-2017, 12:16 PM)martinayotte Wrote: [ -> ]Whit the above line, you seem to try to compile RaspberryPi version, not the A64.
sudo python setup.py install
(02-21-2017, 04:43 AM)JasperBrown Wrote: [ -> ]Which system image did you use?
(02-21-2017, 04:43 AM)JasperBrown Wrote: [ -> ]Which system image did you use?
#!/usr/bin/env python3
from RPi import I2C
I2C.init("/dev/twi1")
I2C.open(0x76)
# set power mode to forced
I2C.write([0xF4,0x01])
sleep(1)
# dump data
I2C.write([0xF7])
value = I2C.read(1)
print(value)
I2C.close()
quit()
Traceback (most recent call last):
File "./bmp280_readonce.py", line 2, in <module>
from RPi import I2C
File "/usr/lib64/python3.4/site-packages/RPi/I2C/__init__.py", line 4, in <module>
from RPi._I2C import *
ImportError: dynamic module does not define init function (PyInit__I2C)
Traceback (most recent call last):
File "./bmp280_readonce.py", line 5, in <module>
I2C.open(0x76)
IOError: [Errno 2] No such file or directory