Base Hat Raspberry Pi no ADC showing on I2C

Hello,

I got an Base Hat for Raspbery Pi and I’m trying to get the ADC chip working.
Although I activated the I2C interfsce for the Raspi I get no device showing on the command ‘i2cdetect -y 1’
Am I save to assume that the chip isn’t answering/ is broken? Or did I miss some basic steps?

The connection of digital pins is veryfied, I tried it on two raspis.

The output of ‘i2cdetect’ on my raspi is also different then the ones I see posted on the net. My first entry always starts at address 0×08 while the posted ones always show entries starting at 0x03. As I’m new to this topic I can’t say what that tells me.

Hi @JueBag ,
Try i2cdetect -y -a 1 0x03 0x77.

https://lab.seeed.co.jp/entry/2024/02/27/120000

Thanks for this hint.
To return of this i2cdetect looks as all the other ones posted on the net.
However, all entries are “–”.

So on I’m still uncertain about the ADC on the Hat (is it broken or…?).

Regarding the pisted link, I can’t read those posts (wrong language) . The parts that are readable look like they are talking about the changed address for the ADC in the code. In my case no ADC shows (IMHO) neither on address 0x04 nor on 0x08

Hi @JueBag ,
Could you tell me the following?

  1. Type of Raspberry Pi used. (Raspberry Pi 4 Model B?)
  2. /boot/firmware/issue.txt or /boot/issue.txt
  3. /boot/firmware/config.txt or /boot/config.txt
  4. dpkg -l i2c-tools
  5. i2cdetect -y -a 1 0x03 0x77
  6. Marking of ADC chip (32F030? Please attach a photo.)

1.) Raspi 3B
2.) From /boot/issue.txt:

Raspberry Pi reference 2023-12-05
Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, 02b371de1a87bbe70cfcbd498527067a7d2ee6ca, stage5
3.) from /boot/firmware/config.txt:
# For more options and information see
# http://rptl.io/configtxt
# Some settings may impact device functionality. See link above for details

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on
#dtparam=i2s=on
#dtparam=spi=on

# Enable audio (loads snd_bcm2835)
dtparam=audio=on

# Additional overlays and parameters are documented
# /boot/firmware/overlays/README

# Automatically load overlays for detected cameras
camera_auto_detect=1

# Automatically load overlays for detected DSI displays
display_auto_detect=1

# Automatically load initramfs files, if found
auto_initramfs=1

# Enable DRM VC4 V3D driver
dtoverlay=vc4-kms-v3d
max_framebuffers=2

# Don't have the firmware create an initial video= setting in cmdline.txt.
# Use the kernel's default instead.
disable_fw_kms_setup=1

# Disable compensation for displays with overscan
disable_overscan=1

# Run as fast as firmware / board allows
arm_boost=1

[cm4]
# Enable host mode on the 2711 built-in XHCI USB controller.
# This line should be removed if the legacy DWC2 controller is required
# (e.g. for USB device mode) or if USB support is not required.
otg_mode=1

[all]

max_usb_current=1
hdmi_force_hotplug=1
config_hdmi_boost=7
hdmi_group=2
hdmi_mode=87
hdmi_drive=1
hdmi_cvt 800 400 60 6 0 0 0

4.) Gewünscht=Unbekannt/Installieren/R=Entfernen/P=Vollständig Löschen/Halten
| Status=Nicht/Installiert/Config/U=Entpackt/halb konFiguriert/
Halb installiert/Trigger erWartet/Trigger anhängig
|/ Fehler?=(kein)/R=Neuinstallation notwendig (Status, Fehler: GROSS=schlecht)
||/ Name Version Architektur Beschreibung
++±==============-============-============-==================================>
ii i2c-tools 4.3-2+b2 armhf heterogeneous set of I2C tools for>
l
5.) 0 1 2 3 4 5 6 7 8 9 a b c d e f
00: – – – – – – – – – – – – –
10: – – – – – – – – – – – – – – – –
20: – – – – – – – – – – – – – – – –
30: – – – – – – – – – – – – – – – –
40: – – – – – – – – – – – – – – – –
50: – – – – – – – – – – – – – – – –
60: – – – – – – – – – – – – – – – –
70: – – – – – – – –
6.) will post picture

Hi @JueBag ,
I prepared a Raspberry Pi 3 Model B and tested it.

pi@raspberrypi:~ $ cat /boot/issue.txt
Raspberry Pi reference 2023-12-05
Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, 02b371de1a87bbe70cfcbd498527067a7d2ee6ca, stage4
pi@raspberrypi:~ $ dpkg -l i2c-tools
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-========================================
ii  i2c-tools      4.3-2+b2     armhf        heterogeneous set of I2C tools for Linux
pi@raspberrypi:~ $ i2cdetect -y -a 1 0x03 0x77
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- 04 -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
pi@raspberrypi:~ $

In my environment, 0x04 is displayed.

It may be a hardware problem. :cry:

1 Like

Thanks for effort.
I ordered a new one, will report (probably at the weekend).

1 Like

Received the new Base Hat (this one was build in 2020 acc the lable). The ‘i2cdetect’ command shows the ADC at address 0x04 (with a build-date of 2020 I wouldn’t have expected that address).

New problem, the detected ADC is not detected by the test software.
Running the test I get the ‘Check wether I2C is enabled and Grove Base Hat…’, which is coming from adc.py.

I changed (back) the line 57 of both adc.py files back to read

  def __init__(self, address =0x04):

Files located in ‘/grove.py/build/lib/grove/’ and /grove.py/grove/’.
However that didn’t solve the problem. I had to search the whole SD-card to find the used version under ‘/user/local/lib/python3.11/dist-packages/grove/’

It was a way with some hurdles, but I made it!

@takashi : Thanks for the support, without your information I would still be searching for false setups issues made by myself.

1 Like