0

I followed below link in github and made all tweaks, (i2c working well and sensor gives output for other codes found in internet, but this code has this problem/s)

GY-80

errors come as this,

Python 2.7.9 (default, Mar  8 2015, 00:52:26) 

[GCC 4.9.2] on linux2
Type "copyright", "credits" or "license()" for more information.
>>> ================================ RESTART    
>>> 
Starting...

Traceback (most recent call last):
  File "/home/pi/raspi/i2c-sensors/bitify/python/sensors/gy80.py",    line    202, in <module>
    imu = GY80()
  File "/home/pi/raspi/i2c-sensors/bitify/python/sensors/gy80.py", line 69, in __init__
    bus = smbus.SMBus(i2c_raspberry_pi_bus_number())
IOError: [Errno 2] No such file or directory

and speciallybus = smbus.SMBus(i2c_raspberry_pi_bus_number()) IOError: [Errno 2] No such file or directory error was there as I was calling other support files (adxl345.py, hmc5883l.py bmp085.py, l3g4200d.py , i2cutils.py and imu.py etc..) to gy80.py.

can anyone explain how to correct this?

0
1

Looks like the I2C has been disabled by the device tree overlay

See this discussion which appears to be the same as your code.

you can enable the I2C device using the raspi-config tool.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.