3

I've try to connect a Heart Rate Sensor with raspberry pi Zero. to do it, I use the I2C port communication. I have a sensor in 0x50 adress and work correctly, but when I did a loop for a long time, the error appear (110).

For example, I put a while to see continuosly the data and the error appeared (after half minut), and now the sensor doesn't connected to the I2C bus. (with the comand i2cdetect -y 1 I don't see any sensor connected, where before, It was. I've had to disconnect and connect to use it again, and when I do a number of reads, come back again the error,

You know why? Can you help me?

import smbus
    while True:
    bus = smbus.SMBus(1)
    b = bus.read_byte_data(0x50,0)
    print b

0 Answers0