I am testing using my new air quality 5 click sensor with my Raspberry Pi (https://www.mikroe.com/air-quality-5-click) using command line.

When I enter i2cdetect -y 1it appears at address 48.

Then when I enter pigs i2co 1 0x30 0 It returns 0 as usual.

However when I try pigs i2crd 0 1 It returns

ERROR: I2C read failed -83

I am not sure how many bytes the returned data is supposed to be, but there does not appear to be any being returned. I have tried a range of lengths(0-9, 0-122) and the error message did not change.

I am using a Raspberry Pi zero W V1.1 that has successfully used these same commands to get data from the previous version of this sensor (2 click) and I can’t find any other people who have had the same problem online. I have tried killall then restarting with pigpiod but no change.

  • It looks like the sensor contains more than one 16 bit register. So you probably need to select a register then read from it. E.g. to select register 3 and read 2 bytes try "pigs i2cwd 0 3 i2crd 0 2"
    – joan
    Commented Apr 18, 2019 at 15:08
  • That returns -82 write failed then -83 read failed Commented Apr 18, 2019 at 16:10
  • I think you'll have to give a link to the device specs (if there is such a thing). I had a quick look at the software but it was contained in an unreadable to me mpkg format,
    – joan
    Commented Apr 18, 2019 at 18:14
  • What specs exactly? I have provided a link to the website that has the data sheets on it Commented Apr 19, 2019 at 11:13
  • The I2C registers to read/write to use the device.
    – joan
    Commented Apr 19, 2019 at 15:41

1 Answer 1


The sensor that you are using has 3 lines from the MICS6814 air quality sensor connected to the ADC which is ADS1015 and this is what is connected to the Pi over I2C. strong text I do not think you can read from this ADC directly from the shell however there are python scripts available to read from the ADC. You can install the python libraries here and try out this example and see if it works for you (Please use the ADS1015 in the code by uncommenting line 15 and commenting out line 11). What you want is the data from channel 0,1 and 2 which should give you the sensor values.

  • i have a version working now thank you for helping and sorry for not replying at the time Commented Aug 6, 2019 at 11:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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