door_status stays at the same value on every pass, so HA never moves
last_changed and the logbook cannot show when the door was actually used.
An event entity's state is the timestamp of the last occurrence, so a repeated
event_type still updates it, and it is not restored across HA restarts — no
stale "entering" coming back after a reboot.
Both entities are derived from the same advertisement: door_status for the
current state, door_event for when it happened. heartbeat: 60s lets the same
event_type fire again after 60s, which is once per pass in practice.
Also teach scripts/validate.py the event platform, mirroring the app's
ConfigValidator rules: event_types required (error), map values missing from
event_types, absent decode.map, numeric metadata, and a publish rule whose
on_change_only suppresses repeats (warnings). The inherited publish rule
(sensor > device > defaults) is now threaded down to sensor validation.
Requires HassBle 1.5.0 or newer — event_types is a new key and older versions
parse config.yaml in strict mode.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
- Update scripts/validate.py with advertise block and control action validation
- Update templates.yaml with mytown_parking_beacon advertising TX template
- Add commented parking beacon TX/RX example to config.yaml
- Document advertise schema, counter_mode, counter_start, and control actions in README.md / README.ko.md
1. parking_beacon: manufacturer_hex_prefix "04" 추가
- SmartKey 인증 패킷(07xx, 22B)이 parking_floor/location을 오염시키던 문제 수정
- length: 14 (정확한 길이 일치)로 22B 패킷 디코드 단계에서도 차단
2. apt_key_door 신규 추가
- manufacturer_id 861 + prefix "02" → 출입 이벤트 6바이트 패킷만 매칭
- instance_mode: shared, MAC 지정 없음
- door_status: entering / exiting / idle 텍스트 센서
- publish.min_interval: 1s (기본 10s 오버라이드, 이벤트가 수 초 내 전환)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Remove redundant OBD initialization commands (ATZ, ATE0, ATL0, ATS0, ATH0) from configs. config.yaml now only uses ATSP6 for the device, and templates.yaml clears init_commands for one template and sets only ATSP6 for the other. This reduces unnecessary reset/echo/linefeed commands and relies on explicit protocol selection.
state_class: none is parsed as the string "none" by kaml/snakeyaml (not null).
ConfigValidator treated any unknown state_class as ERROR, so parking_floor was
silently excluded from entity declarations — it never reached Home Assistant.
- parking_floor: changed to state_class: measurement (correct for floor number)
- parking_location: removed state_class: none (meaningless for text_sensor)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
service_data_uuid + manufacturer_id 두 조건 AND 매칭이 실패 원인:
Android BLE 스캔 결과에서 F51C 서비스 UUID가 service data 또는 service UUID
목록에 포함되지 않으면 항상 NO MATCH 발생.
Fix: service_data_uuid 제거, manufacturer_hex_prefix "0215" (iBeacon 타입 마커)로
대체 → Apple 제조사 데이터(ID 76)로 시작하는 iBeacon 포맷 기기만 매칭.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Configure MAC-per-instance Jaalee decoding and manufacturer 0x035D parking time, battery, and location.
Co-authored-by: Cursor <cursoragent@cursor.com>