Mitigating false positive triggers of a HC-SR501 PIR sensor connected to an ESP8266

Recently I was experimenting with an ESP8266 board (Wemos D1 Mini) running Micropython.

I connected a HC-SR501 PIR sensor to it only to find it it would false trigger.

After googling I found this is due to ESP8266 being quite noisy (partially because of WiFi) and the HC-SR501 needed some noise mitigations.
It seems that most people put decoupling capacitors and shielding with mixed results.

I decided to go a simpler route is simply choke the whole wire (VCC, Data and GND, all together):

HC-SR051 PIR with a common mode choke

In reality it probably does not need that large of a choke, but that is what had handy…

In reality I decided to go against using PIR for my project and will go with a microwave Doppler sensor instead (this way it can be triggered by vehicles and is not affected by the sunlight).

For the curious the sensor is setup with sensitivity set to middle, timer set to minimum and the trigger jumper set to H.