mmWave Human detection kit and MR24HPB1 sensor

Hi,
I bought the mmWave Human detection kit. Everything works as expected in HomeAssistant and ESPHome.
Now I bought as a replacement a 24GHz mmWave Sensor - Human Stationary Presence Module (MR24HPB1) sensor and replace the original one. In HomeAssitant the sensors are unavailable.
So I tried the code for ESP home from this web page: GitHub - thefipster/esphome-mmwave-sensors: ESPHome integration for mmWave Sensors from Seeed Studio

It does not work. The ESPHome logs shows this error. Any idea where to find the ESPHome config ?

ESP-ROM:esp32c3-api1-20210207
Build:Feb  7 2021
rst:0x15 (USB_UART_CHIP_RESET),boot:0x8 (SPI_FAST_FLASH_BOOT)
Saved PC:0x4205b878
SPIWP:0xee
mode:DIO, clock div:1
load:0x3fcd6100,len:0x438
load:0x403ce000,len:0x918
load:0x403d0000,len:0x24e4
entry 0x403ce000

Here my config file for ESPHome. I added the esp32: part and the rx and tx pin based on the orginal ESPHome config for the buildin mmWave sensor.

substitutions:
  device_id: test-mmwave-mr24hpb1
  device_name: Test mmWave MR24HPB1
  header_frame: headers/mr24hpb1_frame.h
  header_sensor: headers/mr24hpb1.h
  uart_rx_pin: "4"
  uart_tx_pin: "5"

esphome:
  name: ${device_id}
  friendly_name: ${device_name}
  includes:
  - ${header_frame}
  - ${header_sensor}

esp32:
  board: esp32-c3-devkitm-1
  variant: ESP32C3
  framework:
    version: 4.4.5
    sdkconfig_options: {}
    advanced:
      ignore_efuse_mac_crc: false
    components: []
    source: ~3.40405.0
    platform_version: platformio/[email protected]
    type: esp-idf


logger:
  logs:
    sensor: INFO
  
uart:
  id: soft_uart2
  baud_rate:  9600
  rx_pin: ${uart_rx_pin}
  tx_pin: ${uart_tx_pin}

sensor:
  - platform: custom
    lambda: |-
      auto mr24hpb1 = new MR24HPB1(id(soft_uart2)); 
      App.register_component(mr24hpb1);
      return {mr24hpb1->presence_sensor, mr24hpb1->motion_sensor, mr24hpb1->proximity_sensor, mr24hpb1->body_sensor};
    sensors:
      - id: presence_sensor
        name: Internal Presense Sensor
        internal: true
        on_value:
          - binary_sensor.template.publish:
              id: presence_template
              state: !lambda return x > 0;
      - id: motion_sensor
        name: Internal Motion Sensor
        internal: true
        on_value:
          - binary_sensor.template.publish:
              id: motion_template
              state: !lambda return x > 0;
      - id: proximity_sensor
        name: Proximity
        state_class: measurement   
      - id: body_sensor
        name: Body Movement
        state_class: measurement   
        
binary_sensor:
  - id: presence_template
    platform: template
    name: Presence
    device_class: occupancy
  - id: motion_template
    platform: template
    name: Motion
    device_class: motion

Hello, I didn’t see the configuration of packages in your configuration file. Is it changed to packages/mr24d.yaml?

Hello,
thanks for your question. I copied the packages to my homeassistant and used the following config:

substitutions:
  device_id: my-mr24hpb1-sensor
  device_name: My MR24HPB1 Sensor
  
esphome:
  name: seeek_studio_mmwave
  platformio_options:
    board_build.flash_mode: dio
    board_build.mcu: esp32c3


esp32:
  board: esp32-c3-devkitm-1
  variant: esp32c3
  framework:
    type: esp-idf


# Enable Home Assistant API
api:
  encryption:
    key: "****"

ota:
  password: "****"

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


packages:
  device_base: !include packages/mr24hpb1.yaml

In addition in changed the rx and tx to GPIO 4 and 5 in the mr24hpc1.yaml

substitutions:
  device_id: test-mmwave-mr24hpc1
  device_name: Test mmWave MR24HPC1
  header_frame: headers/mrx_frame.h
  header_sensor: headers/mr24hpc1.h
  uart_rx_pin: "4"
  uart_tx_pin: "5"

Now I am able to see the following sensors:
image

Just out of curiosity - why do you want to replace MR24HPC1 sensor with MR24HPB1?

Seeed Studio site stated:
This product is in EOL phase, click here to view the new version
and new version is MR24HPC1

Thanks

Did you manage to change sensitivity and/or max distance?
I see exactly the same sensors, but I do not see any available settings