Closed TomasCorral closed 4 months ago
It tries to find it in the list you added it to and if not then it matches it against the generic type to at least set it as a PIR (motion) in pmZoneSensorMaxGeneric_t, this is what I believe has happened. 0x93 would match to this entry: 0x3 : AlSensorType.MOTION
Oh ok. Did I added the sensor in the right place?
I noticed some difference between Next MCW, K9 MCW and Next K9-85. Aren't they the same? I have choosen Next MCW since it is the print my sensor has in the PCB.
Would it be beneficial if the integration prints an error message in the console even with log debug off about the unknown sensor model. Somthing like:
[Visonic Integration] Could not decode ZXY sensor type. Please open an issue in github with the model of your sensor and code: 0xXY
Oh ok. Did I added the sensor in the right place?
Yes, that list is the PowerMax proper list.
I have choosen Next MCW since it is the print my sensor has in the PCB.
I pretty much go with whatever device name people send me when they send me the hex code that goes with it, I either google it or they send me a link to the sensor on the visonic website or a reseller.
Would it be beneficial if the integration prints an error message
It already does
log.debug("[Process Settings] Found unknown sensor type " + str(sensor_type))
It then leaves these variables at their default for the HA Frontend
sensorType = AlSensorType.UNKNOWN
sensorModel = "Model Unknown"
I think that this is enough as people can easily override it in the Frontend and set it to whatever they want.
One of my sensors was not identified, VisonicSensorRef is 0x93. I tested in my panel and it is now displaying correctly.
The sensor is this one:
Also the code for printing the sensor types is commented, even with the debug enabled it won't show. The log message "[Process Settings] Found unknown sensor type ..." did not show to me when I had an unknown sensor, I think the code is not reaching that part.