Does anyone have experience with a KY-037?
I didn’t get it to work for now…
I tried with this yaml code:
sensor:
- platform: adc
pin: GPIO32
name: "Rookmelder tuinhuis"
update_interval: 250ms
binary_sensor:
- platform: gpio
pin: GPIO33
name: "Sound level"
filters:
- delayed_off: 1s
The analog output is constant, there’s no change in voltage, whether I make noise or not. The digital output works:
[18:05:20][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:20][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:20][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:20][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:20][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:21][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:21][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:21][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:21][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:22][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:22][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:22][D][binary_sensor:036]: 'Sound level': Sending state ON
[18:05:22][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:22][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:23][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:23][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:23][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:24][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:24][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:24][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:24][D][binary_sensor:036]: 'Sound level': Sending state OFF
[18:05:24][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:24][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:25][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:25][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:25][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:25][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:26][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:26][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
[18:05:26][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 4095.00000 V with 2 decimals of accuracy
Does anyone have any idea what the issue is? This guy (https://www.youtube.com/watch?v=ySSpbg1OWGU) got it to work… I don’t have any Arduino knowledge, but he must get some raw data, which I should be getting as well?
Earlier, I noticed some unexpected changes, but I later realized they probably were the result of turning the screw of the potentiometer:
There’s no change in voltage, whether I make noise or not. Weirdly, I first saw this:
[14:06:25][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10600 V with 2 decimals of accuracy
[14:06:26][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10700 V with 2 decimals of accuracy
[14:06:27][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10700 V with 2 decimals of accuracy
[14:06:28][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10700 V with 2 decimals of accuracy
[14:06:29][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10800 V with 2 decimals of accuracy
[14:06:30][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10700 V with 2 decimals of accuracy
[14:06:31][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10800 V with 2 decimals of accuracy
[14:06:32][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10600 V with 2 decimals of accuracy
[14:06:33][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.10700 V with 2 decimals of accuracy
At one moment, I accidentally stepped on the device.
No idea whether it was related, but I later noticed this output:
[14:49:48][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.82800 V with 2 decimals of accuracy
[14:49:49][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 1.04500 V with 2 decimals of accuracy
[14:49:50][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 1.04500 V with 2 decimals of accuracy
[14:49:51][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 1.04500 V with 2 decimals of accuracy
[14:49:52][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 1.04500 V with 2 decimals of accuracy
I plugged in another KY-037 unit (I bought a pack of 5), and now this is the output:
[17:43:06][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:11][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14400 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14600 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14500 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.14700 V with 2 decimals of accuracy
[17:43:13][D][sensor:094]: 'Rookmelder tuinhuis': Sending state 0.15000 V with 2 decimals of accuracy
In all three cases, I had silent moments, and moments of continuing noise…