Support Forum

Share your projects and post your questions

Register   or   Sign In
The Forum

OSError : [Errno 121] Remote I/O error

19742 Views - Created 17/04/2019

17/04/2019

Posted by:
Ikram

Ikram Avatar

Hello,

I'm approaching to IOPi by using tutorial2.py.

When i run command python tutorial2.py on RPi 3 B, this error is raised:


Traceback (most recent call last):  File "/media/pi/OTTT/ABElectronics_Python_Libraries-master/IOPi/demos/tutorial2.py", line 60, in <module>    main()  File "/media/pi/OTTT/ABElectronics_Python_Libraries-master/IOPi/demos/tutorial2.py", line 52, in main    if bus.read_pin(1) == 1:  # check to see if the button is pressed  File "/usr/local/lib/python3.4/dist-packages/IOPi/IOPi.py", line 304, in read_pin    self.__ioaddress, self.GPIOA)OSError: [Errno 121] Remote I/O error


Any help?

Many thanks

17/04/2019

Posted by:
andrew

andrew Avatar

Location:
United Kingdom

andrew Twitter  andrew Website  

Hello

A remote I/O error means that the python library is having trouble communicating with the IO Pi.

Please can you try running the command "sudo i2cdetect -y 1" and see what it returns? It should show a list of the devices on the I2C bus. The IO Pi Plus would normally show up on addresses 0x20 and 0x21.

If the IO Pi does not appear on the I2C bus or you get an error then I would recommend going through all of the steps in our I2C tutorial to make sure the I2C bus is configured correctly. Also, try checking the solder joints on the GPIO header to make sure there are no solder bridges between the pins or any dry joints.

17/04/2019

Posted by:
Ikram

Ikram Avatar

Thanks for replying,

Actually, I configured the I2C bus using your official I2C tutorial and the "sudo i2cdetect -y 1" command returns this:



forum image

It seems to me that my IO Pi Plus I2C addresses are well affected.

17/04/2019

Posted by:
andrew

andrew Avatar

Location:
United Kingdom

andrew Twitter  andrew Website  

The IO Pi is showing up on 0x20 and 0x21 so it should be working. Do you have any other devices connected to the I2C bus that may be using the same addresses?

18/04/2019

Posted by:
Ikram

Ikram Avatar

Hello,

Thanks for your last answer. It makes me review the wiring. I was connecting RPi Display SDA and SCL to I2C pins which is not necessary. Now after removing them, it works perfectly.

Thank you again.

Sign in to post your reply

Note: documents in Portable Document Format (PDF) require Adobe Acrobat Reader 5.0 or higher to view, download Adobe Acrobat Reader or other PDF reading software for your computer or mobile device.