Commit Graph

6 Commits

Author SHA1 Message Date
7f00bb8d7b Add single-device comparison to config file
- Modified --diff to accept 1 or 2 device arguments
- With 1 device: compares device config vs expected config from file
- With 2 devices: compares devices to each other (existing behavior)
- Shows which SetOptions and Rules don't match configuration
- Normalizes ON/OFF vs 1/0 for proper comparison
- Helps diagnose why console settings aren't applying correctly
2026-01-07 20:09:26 -06:00
c2800ce646 Change rule differences to columnar format for easier field comparison
- Display rule fields side-by-side in columns like other sections
- Makes it easier to compare State, Once, Length, Free, Rules, etc.
- Consistent formatting with rest of report
2026-01-04 12:52:44 -06:00
3ea2798857 Improve report formatting: compact sections and row format for rules
- Remove extra lines between section headers and content
- Add blank lines only after sections for better readability
- Add _print_rule_differences() method to display rules in row format
- Rules show device names as rows with detailed rule info below each
- More space-efficient report layout
2026-01-04 11:32:00 -06:00
cacdfe7a77 Improve --diff report output with columnar format
Enhanced readability with table-style columnar output

Changes:
- Converted vertical list format to columnar table format
- First column: Parameter name
- Second column: Device 1 value
- Third column: Device 2 value
- Added header row with device names
- Auto-adjusts column widths based on content
- Truncates very long values (>60 chars) with "..."
- Maintains section separation (Firmware, Network, MQTT, etc.)

Before:
  SetOption32:
    KitchenMain = 40
    KitchenBar  = 8

After:
  Parameter        KitchenMain-3040      KitchenBar-7845
  ---------------  --------------------  --------------------
  SetOption32      40                    8

Much easier to scan and compare values side-by-side!

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-04 11:22:43 -06:00
91c471d4b0 Parallelize device queries in --diff feature for faster comparison
Performance Improvement: Query both devices simultaneously

Changes:
- Added ThreadPoolExecutor to device_diff.py compare_devices()
- Both devices are now queried in parallel (max 2 workers)
- Each device queries ~150+ SetOptions independently
- Roughly 2x faster than sequential queries

Before: ~30 seconds (sequential)
After: ~15 seconds (parallel)

The parallel approach significantly improves user experience when comparing
devices, especially when querying all SetOptions (0-150) and Rules.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-04 11:17:57 -06:00
49cf1ec789 Add --diff feature to compare two Tasmota devices
New Feature: Device configuration comparison tool for diagnostics

Usage:
  python TasmotaManager.py --diff DEVICE1 DEVICE2

Features:
- Queries all SetOptions (0-150) from both devices
- Compares firmware versions, network config, MQTT settings
- Shows Rule configurations and status
- Displays all differences in human-readable format
- Helps diagnose configuration issues between working/non-working devices

Files Added:
- device_diff.py: New DeviceComparison class with full status queries

Files Modified:
- TasmotaManager.py: Added --diff argument and comparison mode handler

Example:
  python TasmotaManager.py --diff KitchenMain KitchenBar

This tool revealed that KitchenMain (working) and KitchenBar (problematic)
have significant SetOption differences including SetOption32, SetOption40,
and others that may affect button press behavior.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-04 11:10:24 -06:00