A Home Assistant integration for monitoring and controlling 8311 Firmware flashed XGS-PON ONU / WAS-110 ONU SFP+ sticks via SSH.
- Real-time Monitoring: Monitor temperature, optical power, voltage, and other critical parameters
- System Information: Get detailed system information including uptime, memory usage, and CPU load
- Remote Control: Reboot the ONU stick remotely
- SSH Key Management: Automatic SSH key generation and management (on the HASS client)
- Configurable Polling: Adjustable data update intervals
- Comprehensive Sensors: 20+ sensors covering all aspects of ONU operation and information (including SoC)
- Make sure you have HACS installed
- Add this repository to HACS:
- Go to HACS → Integrations
- Add this repository to HACS as an integration
- Search for "8311"
- Click "Download"
- Restart Home Assistant
- Go to Settings → Devices & Services
- Click "Add Integration"
- Search for "8311"
- Download the
custom_components/8311_onu_stickfolder - Copy it to your Home Assistant
custom_componentsdirectory - Restart Home Assistant
- Go to Settings → Devices & Services
- Click "Add Integration"
- Search for "8311"
- SSH access to your ONU stick
- SSH username
- ONU stick IP address
- Add Integration: Go to Settings → Devices & Services → Add Integration
- Enter Details: Provide the ONU host IP, SSH username, ONU Manuifacturer (Fibermall, ECNI, etc.)
- SSH Key Setup: The integration will automatically generate a SSH key and show it to you during configuration
- Add Public Key: Copy the generated public key to your ONU stick's SSH key management
- Test Connection: The integration will test the SSH connection
- Complete Setup: Once verified, the integration will start monitoring
The integration automatically generates and manages SSH keys for secure communication.
The public key will be displayed during setup and needs to be added to your ONU stick's SSH key management interface.
There is also a SSH Public Key sensor that has the public key as an attribute.
Location on ONU: System → Administration → SSH-Keys
Reboots the ONU stick device using SSH and reboot
Generates a new client SSH key to connect to the ONU stick (backs up the current key with a timestamp in the filename).
- Reboot: Reboots the ONU stick using the exposed service/action
- Regenerate SSH Key: Generates a new SSH key using the exposed service/action
- Data Update Interval: Configure how often sensor data is fetched (30 seconds to 1 hour)
-
SSH Connection Failed
- Verify the ONU IP address is correct
- Ensure SSH is enabled on the ONU
- Check that the SSH key was properly added
-
Authentication Failed
- Verify the SSH username is correct
- Ensure the public key was added to the ONU's SSH key management
- Try regenerating the SSH key
-
Sensors Not Updating
- Check the data update interval in integration options
- Verify SSH connectivity
- Check Home Assistant logs for errors
Enable debug logging by adding to your configuration.yaml:
logger:
default: info
logs:
custom_components.8311_onu_stick: debugThe SSH command is in the coordinator.py file. It is a single SSH command chained together, with boundarys, in order to parse the output of several commands that the data is pulled from. The reason for a single chained together command is for efficency. If we issue one command, disconnect and re-connect for each command, there is a substantial delay.
You can view the debug logs to see what commands are being executed:
Commands to execute: ['pon psg', 'cat /sys/class/thermal/thermal_zone0/temp', 'cat /sys/class/thermal/thermal_zone1/temp', 'xxd -p /sys/class/pon_mbox/pon_mbox0/device/eeprom50', 'xxd -p /sys/class/pon_mbox/pon_mbox0/device/eeprom51', 'cat /sys/class/net/eth0_0/speed', 'uci get gpon.ponip.pon_mode', '. /lib/8311.sh && get_8311_module_type', '. /lib/8311.sh && active_fwbank', 'uptime', 'free -m', 'cat /proc/cpuinfo', 'cat /etc/8311_version', '. /lib/8311.sh && get_8311_lct_mac', '. /lib/8311.sh && get_8311_gpon_sn']
Please review coordinator.py for your own peace of mind.
For all the data points to make neat cards like this:
The card YAML uses:
- card-mod (HACS)
- layout-card (HACS)
- ring-tile
- vertical-stack-in-card (HACS)
- mushroom-template-card (HACS)
- mini-graph-card (HACS)
I did not dial in the color gradients for the ring-tile or mini-graph cards, so you may want to adjust to your liking.



