New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SNMP sensor and OPAQUE data type #112392
Comments
The proposed changes from initial discussion you linked to weren't made into the HA code base. That's why you hit the same. It's the same issue and my team is investigating to see how to fix it. |
The work done by @ChristianKuehnel in #11239 remains helpful. We have cherry picked them and tested out in https://github.com/lextm/core/tree/better-sensor with updated test cases. We will do more testing before sending a pull request. |
@lextm Thank you for the information on this matter.
|
Sure. That seems to be a good workaround. The linked PR has been accepted, so you won't need this workaround once the next HA release is out. |
The problem
SNMP sensor not processing OPAQUE values.
SNMP sensors based on OID with "opaque" data type does not converted into float.
What version of Home Assistant Core has the issue?
Core 2024.2.5
What was the last working version of Home Assistant Core?
Core 2024.2.5
What type of installation are you running?
Home Assistant OS
Integration causing the issue
No response
Link to integration documentation on our website
No response
Diagnostics information
SNMP sensor not processing OPAQUE values.
I have the same problem as was described in Issue 2767 and apparently was solved 7 years ago.
But nowadays I have the same problem - all values for SNMP sensors based on OID with "opaque" data type does not converted into float.
All other ( 20+) snmp sensors are working excellent.
I'm trying to get snmp data from NAS Synology DS with connected APC UPS.
Snmpwalk:
OID Object Type Value
1.3.6.1.4.1.6574.4.4.1.4.0 upsInputVoltageNominal OPAQUE Ÿx�Cf
Sensor configuration
name: "upsInputVoltageNominal"
host: 192.168.2.6
baseoid: 1.3.6.1.4.1.6574.4.4.1.4.0
version: 2c
community: "xxxxxxx"
accept_errors: true
unique_id: ups_input_voltage_nominal
===================================
Result value ='0x9f780443660000'
If other parameters for sensor will be defined such as device_class, state_class and unit_of_measurement we get a sensor creation error.
name: "upsInputVoltageNominal"
host: 192.168.2.6
baseoid: 1.3.6.1.4.1.6574.4.4.1.4.0
version: 2c
community: "xxxxxxx"
accept_errors: true
unique_id: ups_input_voltage_nominal
device_class: voltage
state_class: measurement
unit_of_measurement: V
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
No response
The text was updated successfully, but these errors were encountered: