Version History - MiWiFi XiaoHack Edition
📡 Automatic releases from GitHub
The latest versions are synchronized automatically from GitHub.
Showing 36–40 of 76 releases
📦 v3.4.3 – XiaoHack Edition
Date: 2025-11-07 11:40:32
View original release on GitHub
📝 Changelog — MiWiFi Integration
📦 Version v3.4.3 — 2025-11-07
🆕 Compatibility Model
- ✅ Added support for new router model RD04 #150
✅ Fixes & Stability
- NAT / Port Forwarding autodiscovery: if the default
xqnetwork/portforwardpath fails, the integration now falls back to __HTML_PLACEHOLDER_1__ and updates the whole NAT route group (add/delete/apply) accordingly. This restores NAT rules on firmwares that usexqsystem/*. - More resilient handling of logout/ROM/NAT calls by reading paths from the new routing map instead of hard-coded strings.
- Minor cleanup of obsolete calls and debug messaging.
⚙️ Improvements
- Introduced a centralized __HTML_PLACEHOLDER_0__ map (in
luci.py) and internal __HTML_PLACEHOLDER_2__ usage across all API methods (login, status, Wi‑Fi, QoS, NAT, ROM…).
→ Per-model path customization is now straightforward and localized.
- Clear debug logs indicating which NAT path was selected (default vs. fallback) and why.
- Model normalization to lowercase to avoid case-sensitive mismatches.
🧩 Compatibility
- Confirmed compatibility for NAT endpoints on firmwares that expose __HTML_PLACEHOLDER_0__ (e.g., RC06 and similar variants).
- No breaking changes. Minimum Home Assistant version unchanged.
📘 How to Update
- HACS: Open HACS → *Integrations* → MiWiFi → Update → Restart Home Assistant.
- Manual: Replace the folder
custom_components/miwifi/with the new release → Restart Home Assistant. - After restarting, verify:
- NAT rules list correctly under your main router.
- Adding/removing rules works as expected.
- (Optional) Check logs for the selected NAT path (default or fallback).
ℹ️ Additional Information
- If you previously patched endpoints per model, the new centralized map will take precedence.
- For diagnostics, enable debug logging for
custom_components.miwifiand look for messages about autodiscovered NAT paths.
🙌 Acknowledgements
Huge thanks to Harpik for the API path customization groundwork and to Jose Manuel Usero for the improved NAT detection insights. Your contributions made this release possible. 💪
Summary of changes
| Area | File(s) | What changed |
|---|---|---|
| Routing / Core | custom_components/miwifi/luci.py | Added API_PATHS map and refactored all API calls to use self._api_paths[...] (no more hard-coded endpoints). |
| NAT Compatibility | custom_components/miwifi/compatibility.py | Autodetect xqnetwork vs xqsystem port-forward paths and switch the entire NAT route group on the fly. |
📦 v3.4.2 – XiaoHack Edition
Date: 2025-10-23 07:56:41
View original release on GitHub
📝 Changelog — MiWiFi Integration
📦 Version v3.4.2 – 2025-10-23
✨ New Features
- 🔐 Auto Protocol Detection (HTTPS-first):
The integration now automatically tries HTTPS first and safely falls back to HTTP if the router doesn’t respond properly. Added constants: ``python PROTOCOL_AUTO = "auto" PROTOCOL_HTTP = "http" PROTOCOL_HTTPS = "https" DEFAULT_PROTOCOL = PROTOCOL_AUTO PROTOCOL_OPTIONS = [PROTOCOL_AUTO, PROTOCOL_HTTP, PROTOCOL_HTTPS] `` The base URL is dynamically composed based on the detected protocol, which is cached for faster requests.
- 🧠 Main Router Fallback (single integration):
When only one MiWiFi instance is configured, it’s automatically marked as the main router (is_main=True) with traceability flags: ``python is_main_auto = True auto_reason = "single_integration_fallback" `` preventing “no main router” conditions and keeping dependent sensors consistent.
🛠 Critical Fixes
- 🧩 Protocol robustness: avoids “indecisive” states — any non-5xx response locks the protocol safely.
- 🧭 Improved main-router detection: more predictable logic when mixing manual and auto configurations.
✅ Fixes & Stability
- 📝 Clearer logs: explicit
debugmessage when the router is set via *single_integration_fallback*. - 🔄 Cached protocol detection:
_detect_protocol()now stores its result to avoid repeated tests per router.
⚙️ Backend Improvements
- 🧱 Added
_get_url()to build the base URL dynamically using the detected protocol. - 🧪
_detect_protocol()now uses an async HTTP client with a 5-second timeout for non-blocking testing. - ⚙️ All protocol constants grouped under a dedicated Protocol constants block with proper documentation.
🧹 Code Cleanup
- ♻️ Reordered constants and docstrings for clarity.
- 🧽 Removed redundant branches in main-router detection logic.
✅ Compatibility
- ✅ Compatible with Home Assistant 2025.5.0 +
- ✅ Fully compatible with all MiWiFi Panels 1.3.0 +
📘 How to Update
- Replace your
custom_components/miwifi/folder with this version. - Restart Home Assistant.
- Check the Home Assistant DEBUG logs to confirm protocol detection and proper main-router assignment.
🙌 Credits
- 💡 Harpik — for the concept and technical groundwork of the HTTPS-first protocol detection.
- 🔍 José Manuel Usero — for improving main-router detection and fallback accuracy.
- 💖 Huge thanks to the entire XiaoHack community for testing, reporting, and supporting the project.
💖 Support & Donations
If you enjoy this integration and want to support development:
Thank you for your support! 🙌
Summary of Changes (v3.4.1 → v3.4.2)
| Area | Change | Details |
|---|---|---|
| Connectivity | Auto-detect protocol | HTTPS → HTTP fallback with caching |
| Topology | is_main fallback | Automatically marks router when only one instance exists |
| Logging | Clarity | Explicit debug logs and traceability |
| Cleanup | Protocol constants | Consolidated and documented section |
📦 v3.4.1 – XiaoHack Edition
Date: 2025-10-13 09:14:23
View original release on GitHub
📝 Changelog — MiWiFi Integration
📦 Version v3.4.1 – 2025-10-13
🆕 Compatibility Model
- ✅ Added support for new router model RN09
✅ Compatibility
- ✅ Compatible with Home Assistant 2025.8.0 and above.
📘 How to Update
- Replace all files inside your
custom_components/miwifi/directory with the contents of this release. - Restart Home Assistant completely.
- Add your first router manually to trigger automatic mesh discovery for the remaining devices.
💖 Support & Donations
If this project helps you, consider supporting development. Thank you for keeping the XiaoHack ecosystem alive!
Thank you for your support! 🙌
ℹ️ This release improves detection clarity, reliability, and visual feedback—especially for users with multiple routers.
Maintained with ❤️ by @JuanManuelRomeroGarcia
📦 v3.4.0 – XiaoHack Edition
Date: 2025-09-09 14:46:39
View original release on GitHub
📝 Changelog — MiWiFi Integration
📦 Version v3.4.0 – 2025-09-09
🆕 Compatibility Model
- ✅ Added support for new router model CR8809
✅ Compatibility
- ✅ Compatible with Home Assistant 2025.8.0 and above.
📘 How to Update
- Replace all files inside your
custom_components/miwifi/directory with the contents of this release. - Restart Home Assistant completely.
- Add your first router manually to trigger automatic mesh discovery for the remaining devices.
💖 Support & Donations
If this project helps you, consider supporting development. Thank you for keeping the XiaoHack ecosystem alive!
Thank you for your support! 🙌
ℹ️ This release improves detection clarity, reliability, and visual feedback—especially for users with multiple routers.
Maintained with ❤️ by @JuanManuelRomeroGarcia
📦 v3.3.9b1 – XiaoHack Edition
Date: 2025-08-28 12:32:46
View original release on GitHub
📝 Changelog — MiWiFi Integration
📦 Version v3.3.9 – 2025-08-29
✨ New Features
- 🧹 Global Auto-Purge of inactive devices.
A single, domain-wide scheduled task (main + mesh) that automatically removes stale entities/devices.
- Global, persistent configuration in
.storage/miwifi/auto_purge.json. - Runs every _N_ days at time H and, by design, the inactivity threshold = _N_.
- Kickoff ~60 s after the integration loads so it works even without restarts.
- Self-reschedules after each run; no manual intervention required.
- 🧰 New service:
miwifi.purge_inactive_devices
Manual purge (or dry-run) supporting:
days(threshold),only_randomized,include_orphans,
include_orphans_without_age, include_entities_without_age, verbose, apply (dry-run when false).
- Dry-run preview via notification (“Purge preview”).
- Safe removal order: entities first, then orphaned devices.
▶️ Service Examples
Dry-run (no deletions): ```yaml service: miwifi.purge_inactive_devices data: days: 5 only_randomized: false include_orphans: true include_orphans_without_age: true include_entities_without_age: true verbose: true apply: false
```
Apply changes (delete): ``yaml service: miwifi.purge_inactive_devices data: days: 5 only_randomized: false include_orphans: true include_orphans_without_age: true include_entities_without_age: true verbose: false apply: true ``
✅ Fixes & Stability
- 🛡️ Startup Wi‑Fi restart eliminated. The compatibility probe no longer uses write endpoints during initialization. All checks are now read‑only, preventing unintended radio reloads on integration or HA restart.
- 🧼 Sensitive data hygiene. Extra masking in debug/diagnostic logs to avoid leaking PPPoE/Wi‑Fi passwords and MAC addresses.
- 🧰 Robust error handling around client requests and topology refresh to avoid transient failures during the first boot cycle.
- Harmonized access to entity/device registries to match recent HA versions.
- Clearer logs during boot and purge (results & previews).
⚙️ Improvements
- 📡 Read‑only Wi‑Fi capability detection now leverages
wifi_detail_all/wifi_diag_detail_allinstead of anyset_*endpoints. - 🔍 Clearer boot logs to make it evident that no configuration writes occur during startup.
- 📦 Minor UX polish in the update entity for the MiWiFi Panel version reporting.
- 🔄 Global scheduler shared across multiple entries.
Only one task for the entire domain with automatic ownership and handover if one entry is removed.
- 🕒 Safer Options UI.
Time selector for auto-purge (no regex), and values are synchronized across all entries.
- 💾 Clear persistence.
The JSON keeps every_days, at, next_due, last_run, last_params, history, and owner.
- 🧭 Smarter cleanup.
Multi-router awareness (main + mesh), detection and purge of orphans, and entities without age when they become orphaned.
- 🧵 Async safety.
No hass.async_create_task from worker threads; all scheduling uses HA helpers.
- 🗣️ i18n.
Added/updated translation keys for the purge service (including include_entities_without_age) and auto-purge options.
🌍 MiWiFi Translation & Services Restructure
✅ Achievements
- Key unification: Renamed
purge_inactive→purge_inactive_devicesin all languages so Home Assistant properly maps the service with its translations. - Nested structure: All services (
dump_router_data,purge_inactive_devices, etc.) now use nestedfieldsin translation JSONs.
👉 This fixes the issue where raw keys like service_fields.purge_inactive.days_description appeared in the UI.
- Removed duplicates: The duplicated block under
service_fields.purge_inactive(never used by HA) was removed. - Consistency: All supported languages (
es,en,fr,ru,tr,zh-Hans,pt-BR,de) are now aligned and synchronized. - Clarity for verbose field: Replaced technical “Verbose mode” with clearer wording per language:
- 🇪🇸 Modo detallado
- 🇬🇧 Detailed mode
- 🇫🇷 Mode détaillé
- 🇷🇺 Подробный режим
- 🇹🇷 Ayrıntılı mod
- 🇨🇳 详细模式
- 🇧🇷 Modo detalhado
- 🇩🇪 Detaillierter Modus
📂 Changes in services.yaml
Before (❌ incorrect):
``yaml purge_inactive: name: service_fields.purge_inactive.name description: service_fields.purge_inactive.description fields: days: name: service_fields.purge_inactive.days ``
After (✅ correct, same style as dump):
``yaml purge_inactive_devices: name: Purge inactive devices description: Remove device_trackers and orphan devices after X days of inactivity. fields: days: name: Inactivity days description: Number of days without activity before purge. required: true selector: number: min: 1 max: 365 unit_of_measurement: days only_randomized: name: Only randomized MACs description: Purge only devices with randomized (private) MACs. selector: boolean: {} include_orphans: name: Include orphan devices description: Also purge devices without associated entities. selector: boolean: {} include_orphans_without_age: name: Include orphans without timestamp description: Allow purge even if the last activity date is unknown. selector: boolean: {} verbose: name: Detailed mode description: Adds extended log output during execution. selector: boolean: {} apply: name: Apply changes description: If disabled, runs as a dry-run (simulation) without deleting anything. selector: boolean: {} ``
🌐 Translation synchronization
🔑 Unified key
purge_inactive_devices
📖 Translated fields
days→ Days / Días / Jours / Дни / Günler / 天数 / Dias / Tageonly_randomized→ Only randomized MACs / Solo MAC aleatorias / Uni...include_orphans→ Include orphan devices / Incluir huérfanos / ...include_orphans_without_age→ Include orphans without timestamp / Incluir huérfanos sin edad / ...verbose→ Detailed mode / Modo detallado / Mode détaillé / Подробный режим / Ayrıntılı mod / 详细模式 / Modo detalhado / Detaillierter Modusapply→ Apply changes / Aplicar cambios / Appliquer / Применить / Değişiklikleri uygula / 应用更改 / Aplicar mudanças / Änderungen anwenden
📌 Final result
- All languages correctly translate the fields of the service.
- No more raw keys in the UI.
purge_inactive_devicesbehaves identically todump_router_data.- JSON files for each language are complete and aligned.
✅ Compatibility
- No breaking changes. Works with the same set of Xiaomi/Redmi routers already supported by the integration.
- Home Assistant Core: 2024.6+ recommended.
📘 How to Update
- Replace the folder:
config/custom_components/miwifi/with this release’s files. - Restart Home Assistant.
- (Optional) In Developer Tools → Services, call
miwifi.dump_router_datawithhide_sensitive: trueto verify everything looks good without exposing secrets. - If the Wi‑Fi on your router still restarts at HA boot, verify other automations or third‑party logins (Mi Home app, web UI) are not applying changes at the same time.
ℹ️ Additional Information
- On‑demand actions like
set_guest_wifiandset_wifisstill apply changes when you explicitly call those services. The boot process itself remains read‑only. - For troubleshooting, enable debug logs for
custom_components.miwifiand share sanitized excerpts if needed.
💖 Support & Donations
If this project helps you, consider supporting development. Thank you for keeping the XiaoHack ecosystem alive!
Thank you for your support! 🙌
Summary of changes
| Area | Change |
|---|---|
| Startup | Removed write endpoints from compatibility checks; startup is read‑only |
| Security | Improved masking for passwords and MACs in logs |
| Services | set_guest_wifi, get_wifis, dump_router_data available and documented |
| UX | Clearer boot logs and panel update reporting |
Asistente XiaoHack
Xiaohack V 3.3 | © Copyright 2024 | Users Online: 0 | Estado: Offline
