Pi GPIO Binary Sesnsor

Hi Guys

I’m having the same issue as everyone above.

Been testing and trying everything I can think off. Tried a few different settings and the problem stays the same.
I have tried WayneT’s bounce time reduction but even then it only works some time but not always.

I have scripted a quick small script in python to test the hardware side and from that script everything are 100%
My initial idea were to run a small script in the back ground of the Pi to do the switching of the relays for time being while this issue persist in HA but even that has now fallen down the drain as HA does not update the status of the GPIO’s correctly.

It seems like HA only update the sensor status every few milliseconds (good normal practice) but if the switching does not happen it the refresh time HA does not update the status for either Inputs or Outputs.

So whats happening at this stage is
you push the button outside HA’s refresh time and HA does not pick up that the switch are on (even after 5 mins HA still don’t read the switch closed)
now if you play with a few other switches you have the same until it picks up one that changed in the refresh period, once it picks one up all of the inputs are suddenly updated and working but then you have the same again switching them off.

The same on the outputs. you can change the output to be on with python and HA doesn’t see that if you fallen in the blind time frame of not refreshing but as soon as one gets picked up all of the output statuses gets updated in HA.

Surely this are a small error in HA coding around the refreshing of the GPIO statuses.

If there’s anyone out there that might know how to fix this problem or even if there are anyone that can point me in the right direction to someone on the development team, that will be fantastic.

I see a lot of ppl struggle with this issue and it would be nice to get it sorted out.