ESP32-LD2410 - Pb réglage sur détection de lumière

Bonjour,
j’utilise le capteur de lumière intégré au LD2410 et fais l’automatisation directement dans le code du ESP.

avant je passais par une automatisation sur HA:

alias: Cuisine Auto Présence
description: ""
mode: single
triggers:
  - entity_id:
      - binary_sensor.s3_display_presence
    to: "on"
    id: "on"
    trigger: state
  - entity_id:
      - binary_sensor.s3_display_presence
    to: "off"
    id: "off"
    trigger: state
conditions: []
actions:
  - choose:
      - conditions:
          - condition: trigger
            id:
              - "on"
          - condition: numeric_state
            entity_id: sensor.s3_display_light
            below: 95
            enabled: true
        sequence:
          - data: {}
            target:
              entity_id: light.0x00158d000501ccd9
            action: light.turn_on
      - conditions:
          - condition: trigger
            id:
              - "off"
        sequence:
          - data: {}
            target:
              entity_id: light.0x00158d000501ccd9
            action: light.turn_off