ADS1115 banana pi zero python3

Moderators: adafruit_support_bill, adafruit

Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
Locked
User avatar
lucasgeo
 
Posts: 2
Joined: Tue Aug 16, 2022 2:26 pm

ADS1115 banana pi zero python3

Post by lucasgeo »

I try to use:

Code: Select all

pip3 install adafruit-blinka
pip3 install adafruit-circuitpython-ads1x15
I have success ads1115 in raspberry pi zero, but dont work in banana pi zero.
Return erro in import board in python:

Code: Select all

Traceback (most recent call last):
  File "testes.py", line 1, in <module>
    import board
  File "/usr/local/lib/python3.5/dist-packages/board.py", line 204, in <module>
    raise NotImplementedError("Board not supported {}".format(board_id))
NotImplementedError: Board not supported None
In file /usr/local/lib/python3.5/dist-packages/board.py in raspberry pi zero, board_id is 'RASPBERRY_PI_ZERO'
but in Bananapi zero board_ir is NONE

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: ADS1115 banana pi zero python3

Post by adafruit_support_mike »

The code that handles I2C communication starts by calling a function that looks for a board ID, then uses that to find the I2C interface the device uses. The error message you posted says the code couldn't find a board ID or I2C interface for the Banana Pi.

Check to see if you can find a CircuitPython port for the Banana Pi.

User avatar
lucasgeo
 
Posts: 2
Joined: Tue Aug 16, 2022 2:26 pm

Re: ADS1115 banana pi zero python3

Post by lucasgeo »

Yes, but i2c existis, i check with i2cdetect -y 0

Code: Select all

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- 48 -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- 68 -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --
Same as the raspberry pi zero, but in raspberry is i2cdetect -y 1

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: ADS1115 banana pi zero python3

Post by adafruit_support_mike »

`i2cdetect` isn't written in CircuitPython. It's written in C using a library that already knows what I2C port to use.

The fact that CircuitPython can't locate the I2C interface doesn't mean there is no I2C interface. It means a config file with information like "what I2C interface should I use?" is missing. To get that config file, you need to find a version of the CircuitPython core libraries configured for the Banana Pi.

Locked
Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/

Return to “Adafruit Raspberry Pi® accessories”