From dae3b64753403c72c119a9d0fb5431c35380ec70 Mon Sep 17 00:00:00 2001 From: sen Date: Wed, 16 Oct 2024 20:59:04 +0800 Subject: [PATCH] Experimental YAML Configurations for 1wx --- 1wx/yaml/experiment/README.yaml | 3 + .../human-sensor-1wx-experiment-v1 2.yaml | 156 ++++++++++++++++++ 2 files changed, 159 insertions(+) create mode 100644 1wx/yaml/experiment/README.yaml create mode 100644 1wx/yaml/experiment/human-sensor-1wx-experiment-v1 2.yaml diff --git a/1wx/yaml/experiment/README.yaml b/1wx/yaml/experiment/README.yaml new file mode 100644 index 0000000..07b2601 --- /dev/null +++ b/1wx/yaml/experiment/README.yaml @@ -0,0 +1,3 @@ +Experimental YAML Configurations + +The YAML configuration files in this directory are experimental and are intended for testing and exploratory development purposes. They have not undergone comprehensive testing or validation and may contain unresolved bugs and issues. Please use these configurations with caution, keeping in mind that they are meant solely for experimentation and learning, and their functionality and stability cannot be guaranteed. \ No newline at end of file diff --git a/1wx/yaml/experiment/human-sensor-1wx-experiment-v1 2.yaml b/1wx/yaml/experiment/human-sensor-1wx-experiment-v1 2.yaml new file mode 100644 index 0000000..81526ad --- /dev/null +++ b/1wx/yaml/experiment/human-sensor-1wx-experiment-v1 2.yaml @@ -0,0 +1,156 @@ +esphome: + name: screek-humen-sensor-1wx + comment: Screek Human Sensor 1WX + friendly_name: Human Sensor 1WX + name_add_mac_suffix: True + platformio_options: + board_build.flash_mode: dio + project: + name: Screek.Human_Sensor + version: 1W + +external_components: + - source: + type: git + url: https://github.com/screekworkshop/custom_components_support_for_screek_1w + ref: main + components: [esp32, uart] + +esp32: + board: esp32-c3-devkitm-1 + +logger: + +api: + +ota: + - platform: esphome + password: "YOUR_OTA_PASSWORD" + +wifi: + # ssid: !secret wifi_ssid + # password: !secret wifi_password + # fast_connect: True + + power_save_mode: NONE + # output_power: 20dB + # Enable fallback hotspot (captive portal) in case wifi connection fails + ap: + ssid: "HUMAN-SENSOR 1WX" + +captive_portal: + +web_server: + port: 80 + +binary_sensor: + - platform: status + name: Online + id: ink_ha_connected + - platform: ld2410 + has_target: + name: Presence + has_moving_target: + name: Moving Target + has_still_target: + name: Still Target + +sensor: + - platform: template + id: sys_esp_temperature + name: ESP Temperature + lambda: return temperatureRead(); + unit_of_measurement: °C + device_class: TEMPERATURE + update_interval: 30s + entity_category: "diagnostic" + - platform: uptime + name: Uptime + id: sys_uptime + update_interval: 10s + - platform: wifi_signal + name: RSSI + id: wifi_signal_db + update_interval: 1s + entity_category: "diagnostic" + - platform: template + id: esp_memory + icon: mdi:memory + name: ESP Free Memory + lambda: return heap_caps_get_free_size(MALLOC_CAP_INTERNAL) / 1024; + unit_of_measurement: 'kB' + state_class: measurement + entity_category: "diagnostic" + - platform: ld2410 + moving_distance: + name : Moving Distance + id: moving_distance + still_distance: + name: Still Distance + id: still_distance + moving_energy: + name: Move Energy + still_energy: + name: Still Energy + detection_distance: + name: Detection Distance + light: + name: Sun Light + +time: + - platform: sntp + id: time_now + servers: + - ntp.aliyun.com + +uart: + id: uart_ld2410 + tx_pin: GPIO7 + rx_pin: GPIO6 + baud_rate: 256000 + parity: NONE + stop_bits: 1 + +switch: + - platform: ld2410 + engineering_mode: + name: "engineering mode" + bluetooth: + name: "control bluetooth" + +ld2410: + id: ld2410_radar + +text_sensor: + - platform: ld2410 + version: + name: "firmware version" + mac_address: + name: "mac address" + +button: + - platform: ld2410 + factory_reset: + name: "ld2410 factory reset" + restart: + name: "LD2410 Reboot" + icon: mdi:radar + entity_category: "config" + - platform: restart + icon: mdi:power-cycle + name: "ESP Reboot" + - platform: factory_reset + disabled_by_default: True + name: Factory Reset + id: factory_reset_all + +number: + - platform: ld2410 + timeout: + name: timeout + light_threshold: + name: light threshold + max_move_distance_gate: + name: max move distance gate + max_still_distance_gate: + name: max still distance gate \ No newline at end of file