timed_set_ms is not respected always.
athanassis opened this issue · 0 comments
- I have read the README.md file and visited the Documentation to see if the information there helps.
Describe the bug
I'm using the timed_set_ms in output pins which drive latching relays. The configured value (100ms) is not always followed by mqtt-io. I observe delays in automatically setting the gpio pin back to its initial state of up to 6s. This causes a buzz sound in the relays which is annoying.
The frequency that the delays are observed is ~2.3% (98 occurrences / 4201 total events). This is from a log file of 1 year period, so I hear the buzz in the relays nearly every ~3.5 days on average.
Expected behavior
The timed_set_ms should be respected in all cases.
Error messages and traceback
Here is a sample from a log showing a delay:
2023-02-20 18:19:42 mqtt_io.server [INFO] Digital output 'corridor_lights_relay' set to False (on)
2023-02-20 18:19:48 mqtt_io.server [INFO] Setting digital output 'corridor_lights_relay' back to its previous value after configured 'timed_set_ms' delay of 100ms
2023-02-20 18:19:48 mqtt_io.server [INFO] Digital output 'corridor_lights_relay' set to True (off)```
Here is a sample from an event working as expected:
2023-02-20 18:48:37 mqtt_io.server [INFO] Digital output 'corridor_lights_relay' set to False (on)
2023-02-20 18:48:37 mqtt_io.server [INFO] Setting digital output 'corridor_lights_relay' back to its previous value after configured 'timed_set_ms' delay of 100ms
2023-02-20 18:48:37 mqtt_io.server [INFO] Digital output 'corridor_lights_relay' set to True (off)
Config
- name: corridor_lights_relay
module: kili
pin: 8
initial: 'high'
inverted: True
timed_set_ms: 100```
Hardware
- Platform: Raspberry Pi
- Connected hardware: GPIO is connected to 5V 8 Relay board. The Relays from this board are used to emulate button presses towards latching relays in the electric panel of the house.
System:
- OS: Raspbian
- Python version: 3.7.3
- User you're running as: pi
- Using a virtualenv?: no
Additional context
I run mqtt-io with Deployment using supervisor