Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Bumped by Community user
Moved code sample into main body
Source Link
goobering
  • 10.5k
  • 3
  • 37
  • 63

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to a Pi. Both are working fine. Then I connected the SDA and SCL pins of the sensors and then to Pi. All of the devices are displayed using the command:

pi@raspberrypi:~ $ i2cdetect -y 1
 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- --
70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address is id 0x76, it gives the error:

File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main
bus.write_byte(0x76, 0x58)
IOError: [Errno 5] Input/output error 

bus.write_byte(0x76,0x1E), which is reset command, works perfectly while any other command generates error. The error generating code section is:

import smbus 
import time 

bus = smbus.SMBus(1) 
#0x1E(30) Reset command 
bus.write_byte(0x76, 0x1E) 
time.sleep(0.5) 

def main() 
    #0x40(64) Pressure conversion(OSR = 256) 
    command bus.write_byte(0x76, 0x50) ### THIS LINE CAUSES ERROR 

Any help will really be appreciated.

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to a Pi. Both are working fine. Then I connected the SDA and SCL pins of the sensors and then to Pi. All of the devices are displayed using the command:

pi@raspberrypi:~ $ i2cdetect -y 1
 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- --
70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address is id 0x76, it gives the error:

File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main
bus.write_byte(0x76, 0x58)
IOError: [Errno 5] Input/output error 

Any help will really be appreciated.

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to a Pi. Both are working fine. Then I connected the SDA and SCL pins of the sensors and then to Pi. All of the devices are displayed using the command:

pi@raspberrypi:~ $ i2cdetect -y 1
 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- --
70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address is id 0x76, it gives the error:

File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main
bus.write_byte(0x76, 0x58)
IOError: [Errno 5] Input/output error 

bus.write_byte(0x76,0x1E), which is reset command, works perfectly while any other command generates error. The error generating code section is:

import smbus 
import time 

bus = smbus.SMBus(1) 
#0x1E(30) Reset command 
bus.write_byte(0x76, 0x1E) 
time.sleep(0.5) 

def main() 
    #0x40(64) Pressure conversion(OSR = 256) 
    command bus.write_byte(0x76, 0x50) ### THIS LINE CAUSES ERROR 

Any help will really be appreciated.

Multiple I2C devices connected to a Raspberry Pi

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to RPIa Pi. Both are working fine. Then I connected the SDA and SCL pins of the sensors and then to RPIPi. All of the devices are displayed using the command: pi@raspberrypi:~ $ i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- -- 70: -- -- -- -- -- -- 76 77

pi@raspberrypi:~ $ i2cdetect -y 1
 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- --
70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address is id 0x76. It, it gives the error File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main bus.write_byte(0x76, 0x58) IOError: [Errno 5] Input/output error

File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main
bus.write_byte(0x76, 0x58)
IOError: [Errno 5] Input/output error 

. Any help will really be appreciated.

Multiple I2C devices connected to Raspberry Pi

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to RPI. Both are working fine. Then I connected SDA and SCL pins of sensors and then to RPI. All the devices are displayed using the command: pi@raspberrypi:~ $ i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- -- 70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address id 0x76. It gives the error File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main bus.write_byte(0x76, 0x58) IOError: [Errno 5] Input/output error

. Any help will really be appreciated

Multiple I2C devices connected to a Raspberry Pi

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to a Pi. Both are working fine. Then I connected the SDA and SCL pins of the sensors and then to Pi. All of the devices are displayed using the command:

pi@raspberrypi:~ $ i2cdetect -y 1
 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- --
70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address is id 0x76, it gives the error:

File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main
bus.write_byte(0x76, 0x58)
IOError: [Errno 5] Input/output error 

Any help will really be appreciated.

Source Link

Multiple I2C devices connected to Raspberry Pi

I've got one GY-80 IC and one ms5803 pressure sensor, interfaced to RPI. Both are working fine. Then I connected SDA and SCL pins of sensors and then to RPI. All the devices are displayed using the command: pi@raspberrypi:~ $ i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1e -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 50: -- -- -- 53 -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- 69 -- -- -- -- -- -- 70: -- -- -- -- -- -- 76 77

But when I tried to read pressure sensor whose I2C address id 0x76. It gives the error File "/home/pi/workspace/src/gy_80/Psensor_node.py", line 50, in main bus.write_byte(0x76, 0x58) IOError: [Errno 5] Input/output error

. Any help will really be appreciated