Temperature & Humidity Sensor with AM2320 + ESP32


Has anyone managed to get an AM2320 to work with an ESP32 under ESPHome ?

Because the help is very basic…



i don’t know what u need…
u have to put wire…
esp32 am2320 – Recherche Google
and write this in your device.yaml

  - platform: am2320
      name: "Living Room Temperature"
      name: "Living Room Humidity"
    update_interval: 60s

AM2320 Temperature+Humidity Sensor — ESPHome

flash and you ll find sensor.Living_Room_blabla in hassio


I don’t understand how it can work because I don’t indicate the PIN ?


It’s a I2C so define pins in the i2c component:

Thanks @orange-assistant

It works but I have exactly the same problem as here, an idea ?


Did you try this here?

I found that SI7021 has built-in pull-up resistors (Chineese GY-21, 10k), and AM2320 doesn’t, after I connected resistors my AM2320 it started working.

Source: AM2320 not found on cold boot · Issue #1742 · esphome/issues · GitHub

Yes, i already use the resistors (4.7K) :thinking:

[17:07:19][C][logger:233]: Logger:
[17:07:19][C][logger:234]:   Level: DEBUG
[17:07:19][C][logger:235]:   Log Baud Rate: 115200
[17:07:19][C][i2c.arduino:032]: I2C Bus:
[17:07:19][C][i2c.arduino:033]:   SDA Pin: GPIO21
[17:07:19][C][i2c.arduino:034]:   SCL Pin: GPIO22
[17:07:19][C][i2c.arduino:035]:   Frequency: 50000 Hz
[17:07:19][I][i2c.arduino:048]: Scanning i2c bus for active devices...
[17:07:19][I][i2c.arduino:060]: Found no i2c devices!
[17:07:19][D][am2320:063]: AM2320:
[17:07:19][C][am2320:064]:   Address: 0x5C
[17:07:19][E][am2320:066]: Communication with AM2320 failed!
[17:07:19][C][am2320:068]:   Temperature 'Température Chambre'
[17:07:19][C][am2320:068]:     Device Class: 'temperature'
[17:07:19][C][am2320:068]:     State Class: 'measurement'
[17:07:19][C][am2320:068]:     Unit of Measurement: '°C'
[17:07:19][C][am2320:068]:     Accuracy Decimals: 1
[17:07:19][C][am2320:069]:   Humidity 'Humidité Chambre'
[17:07:19][C][am2320:069]:     Device Class: 'humidity'
[17:07:19][C][am2320:069]:     State Class: 'measurement'
[17:07:19][C][am2320:069]:     Accuracy Decimals: 1

You have any other i2c devices on the same bus?

No, only the AM2320.

Did you double check all the i2c connections/wires/solderpoints/etc.?

Does the sensor always work with a “warm start”? Might need to tweak the resistor value a little bit to get it stable :thinking:

Connections is ok.

The sensor doesn’t work with a warm start only after a soft reboot.

It’s very strange.