EspHome avec ads1115 et clamp

Bonjour à tous,
sur la base d’un esp8466 avec un ads1115, j’ai réalisé un module qui reprend les données du linky, d’un compteur annexe et de 3 pinces ampérométriques SCT0.13 30A/1V.

Home assistant me rapporte bien les infos (conso globale et celles des 4 postes ) donc c’est super sauf que lorsque je regarde les logs de mon esp, j’ai un message d’avertissement récurent et je ne vois pas trop comment solutionner la chose:

[13:22:07][D][ct_clamp:048]: 'Courant P1' - Raw AC Value: 0.003A after 458 different samples (458 SPS)
[13:22:07][D][sensor:093]: 'Courant P1': Sending state 0.08755 A with 2 decimals of accuracy
***[13:22:08][W][component:214]: Component ct_clamp.sensor took a long time for an operation (0.67 s).***
***[13:22:09][W][component:215]: Components should block for at most 20-30ms.***
[13:22:20][D][ct_clamp:048]: 'Courant P2' - Raw AC Value: 0.003A after 472 different samples (472 SPS)
[13:22:20][D][sensor:093]: 'Courant P2': Sending state 0.10274 A with 2 decimals of accuracy
***[13:22:21][W][component:214]: Component ct_clamp.sensor took a long time for an operation (0.61 s).***
***[13:22:22][W][component:215]: Components should block for at most 20-30ms.***
[13:22:23][D][ct_clamp:048]: 'Courant P3' - Raw AC Value: 0.003A after 478 different samples (478 SPS)
[13:22:24][D][sensor:093]: 'Courant P3': Sending state 0.09837 A with 2 decimals of accuracy
***[13:22:25][W][component:214]: Component ct_clamp.sensor took a long time for an operation (0.60 s).***
***[13:22:26][W][component:215]: Components should block for at most 20-30ms.***
[13:22:27][D][ct_clamp:048]: 'Courant P1' - Raw AC Value: 0.003A after 471 different samples (471 SPS)
[13:22:27][D][sensor:093]: 'Courant P1': Sending state 0.07020 A with 2 decimals of accuracy
***[13:22:28][W][component:214]: Component ct_clamp.sensor took a long time for an operation (0.67 s).***
***[13:22:29][W][component:215]: Components should block for at most 20-30ms.***
[13:22:29][D][ads1115:233]: 'adc_sensor3': Got Voltage=1.572625V
[13:22:30][D][sensor:093]: 'adc_sensor3': Sending state 1.57263 V with 3 decimals of accuracy
***[13:22:31][W][component:214]: Component ads1115.sensor took a long time for an operation (1.09 s).***
***[13:22:32][W][component:215]: Components should block for at most 20-30ms.***

Voici le code que j’utilise :

esphome:
  name: tableau-electrique-general
  friendly_name: Tableau Electrique général

esp8266:
  board: nodemcu

external_components:
  - source: github://ssieb/esphome@vsampler
    components: [ voltage_sampler, ct_clamp, ads1115 ]
    refresh: 1min

# Enable logging
logger:

# Enable Home Assistant API
api:
  encryption:
    key: XXX

ota:
  password: XXX

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: XXX
    password: XXX

captive_portal:

# configuration du I2C
i2c:
  sda: 4
  scl: 5
  scan: True
  frequency: 200000

# configuration de l ADC
ads1115:
  address: 0x48
  continuous_mode: True

# configuration de l uart
uart:
  rx_pin: 3
  tx_pin: 1
  baud_rate: 1200
  parity: EVEN
  data_bits: 7

# configuration du Linky
teleinfo:
  id: myteleinfo
  update_interval: 60s
  historical_mode: true

# configuration des capteurs de courant et pinces
sensor:
  # sensors source
  - platform: ads1115
    multiplexer: 'A1_GND'
    gain: 4.096
    name: "adc_sensor1"
    id: "adc_sensor1"
  - platform: ct_clamp
    sensor: adc_sensor1
    name: "Courant P1"
    sample_duration : 1s
    update_interval : 20s
    filters:
      - calibrate_linear:
          # Measured value of 0 maps to 0A
          - 0 -> 0
          # Known load: 4.0A
          # Value shown in logs: 0.1333A
          - 0.3 -> 8.3 

  - platform: ads1115
    multiplexer: 'A2_GND'
    gain: 4.096
    name: "adc_sensor2"
    id: "adc_sensor2"
  - platform: ct_clamp
    sensor: adc_sensor2
    name: "Courant P2"
    sample_duration : 1s
    update_interval : 20s
    filters:
      - calibrate_linear:
          # Measured value of 0 maps to 0A
          - 0 -> 0
          # Known load: 4.0A
          # Value shown in logs: 0.1333A
          - 0.27 -> 8.2

  - platform: ads1115
    multiplexer: 'A3_GND'
    gain: 4.096
    name: "adc_sensor3"
    id: "adc_sensor3"
  - platform: ct_clamp
    sensor: adc_sensor3
    name: "Courant P3"
    sample_duration : 1s
    update_interval : 20s
    filters:
      - calibrate_linear:
          # Measured value of 0 maps to 0A
          - 0 -> 0
          # Known load: 4.0A
          # Value shown in logs: 0.1333A
          - 0.27 -> 8.2

# consommation prise voiture
  - platform: pulse_meter
    name: 'Puissance prise voiture'
    pin: 
      number: 15
      mode:
        input: True
    unit_of_measurement: 'kW'

    device_class: power
    state_class: measurement
    internal_filter: 20ms # Assuming maximum load of 16 kW and 10000 impulses per kWh, any pulses faster than 22.5 ms would exceed load. -10% ~= 20 ms.
    accuracy_decimals: 0
    filters:
      - multiply: 0.06  # (60s/1000 pulses per kWh)

    total:
      unit_of_measurement: 'kWh'
      name: 'Consommation prise voiture'
      filters:
        - multiply: 0.001  # (1/1000 pulses per kWh)

  # configuration des infos du linky
  - platform: teleinfo
    tag_name: "BBRHCJB"
    name: "Heures Creuses Jours Bleus"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "BBRHPJB"
    name: "Heures Pleines Jours Bleus"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "BBRHCJW"
    name: "Heures Creuses Jours Blancs"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "BBRHPJW"
    name: "Heures Pleines Jours Blancs"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "BBRHCJR"
    name: "Heures Creuses Jours Rouges"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "BBRHPJR"
    name: "Heures Pleines Jours Rouges"
    unit_of_measurement: "Wh"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "PAPP"
    name: "Puissance apparente triphasée soutirée"
    unit_of_measurement: "VA"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "IINST1"
    name: "Intensité Instantanée P1"
    unit_of_measurement: "A"
    icon: mdi:flash
    teleinfo_id: myteleinfo   
  - platform: teleinfo
    tag_name: "IINST2"
    name: "Intensité Instantanée P2"
    unit_of_measurement: "A"
    icon: mdi:flash
    teleinfo_id: myteleinfo
  - platform: teleinfo
    tag_name: "IINST3"
    name: "Intensité Instantanée P3"
    unit_of_measurement: "A"
    icon: mdi:flash
    teleinfo_id: myteleinfo

# suite des informations du linky
text_sensor:
  - platform: teleinfo
    tag_name: "PTEC"
    name: "Période Tarifaire en cours"
    teleinfo_id: myteleinfo   
  - platform: teleinfo
    tag_name: "DEMAIN"
    name: "Couleur du lendemain"
    teleinfo_id: myteleinfo 

J’ai déjà pas mal cherché sur différents forums et mon code a l’air correct donc je ne sais pas ce qui peut causer cet avertissement ni même si je dois m’en soucier (j’aimerais au moins comprendre).

Est-ce que l’un d’entre vous aurait une idée, une piste?

merci d’avance et belle journée.

Manu

Ma configuration


System Information

version core-2024.1.6
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.11.6
os_name Linux
os_version 6.1.63-haos-raspi
arch aarch64
timezone Europe/Brussels
config_dir /config
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Home Assistant Supervisor
host_os Home Assistant OS 11.4
update_channel stable
supervisor_version supervisor-2023.12.1
agent_version 1.6.0
docker_version 24.0.7
disk_total 228.5 GB
disk_used 9.0 GB
healthy true
supported true
board rpi4-64
supervisor_api ok
version_api ok
installed_addons Mosquitto broker (6.4.0), File editor (5.7.0), ESPHome (2023.12.9), Grafana (9.1.3), Terminal & SSH (9.7.1), Studio Code Server (5.15.0), InfluxDB (5.0.0), Node-RED (15.0.0)
Dashboards
dashboards 1
resources 0
views 3
mode storage
Recorder
oldest_recorder_run 19 janvier 2024 à 10:20
current_recorder_run 5 février 2024 à 09:44
estimated_db_size 198.67 MiB
database_engine sqlite
database_version 3.41.2
___