esphome:
name: dara-tes-esp
min_version: 2025.9.1
build_path: build/dara-tes-esp
esp32:
board: esp32dev
framework:
type: esp-idf
logger:
# level: DEBUG # aktifkan sementara kalau mau scan BLE
api:
ota:
- platform: esphome
wifi:
ssid: "Dara@Home"
password: "rejeki88"
manual_ip:
static_ip: 192.188.1.236
gateway: 192.188.1.1
subnet: 255.255.255.0
ap:
ssid: "ESP Fallback"
password: "fallback1234"
web_server:
port: 80
captive_portal:
# ===== JK (Jikong) BMS via BLE - komponen lokal =====
external_components:
- source:
type: local
path: components # -> /config/esphome/components
components: [jk_modbus, jk_bms_ble]
esp32_ble_tracker:
scan_parameters:
active: true
# 1) Definisikan BLE client dengan MAC BMS
ble_client:
- mac_address: "AA:BB:CC:DD:EE:FF" # <-- GANTI MAC BLE JK-BMS kamu
id: client0
# 2) Hub JK-BMS BLE mengacu ke ble_client_id dan WAJIB pilih protocol_version
# Umum: JK02_32S (hw v11 ke atas). Untuk hw lama: JK02_24S atau JK04.
jk_bms_ble:
- ble_client_id: client0
protocol_version: JK02_32S # <-- ganti jika perlu: JK02_24S / JK04
throttle: 5s
id: bms0
# --- I2C utk OLED ---
i2c:
sda: GPIO21
scl: GPIO22
scan: true
font:
- id: font_14
file: "gfonts://Roboto"
size: 14
# Jika gfonts bermasalah:
# file: "/config/esphome/fonts/arial.ttf"
# ================
# S E N S O R
# ================
sensor:
# DHT11 di GPIO4
- platform: dht
pin: GPIO4
model: DHT11
temperature:
name: "Suhu DHT11"
id: suhu
humidity:
name: "Kelembapan DHT11"
id: kelembapan
update_interval: 10s
# JK-BMS
Comments
Post a Comment