Floating Pins, Pull-Up Resistors

Hi,
I use 3 pins of Arduino as INPUT to trigger GSM module. When the pins receive 5V then they started to tigger.
As you see the diagram: Pins must be GROUND position without triggering it.

I watched some videos to make ground floating pins. I connected pins with 20K resistor to ground and connected same pins to 5V with switch as in attached diagram.

When I run the Arduino in the office it works good. But when I run the Arduino in the Glasshouse sometimes it start to triggered by itself?!
What can I do to prevent self triggered the pins? Should I increase or decrease the resistor value.

By the way there are some frequence drivers in the Glasshouse system room.

Regards,
Mucip:)

hey,

If I were you I would do exactly what you described. For example, the other day I used a 200 ohm resistor and it worked perfectly. Otherwise you are welcome to send us your sketch, maybe we can help you there...

Kind regards
finn

Suggest you use the S3 configuration.

S2 can also be used where R1 can be adjusted for a stronger pull-up if needed.


Sample you switches so de-bounce isn’t a problem too.

Hi,
Thanks a lot for your kind interest. Please check attached code.
By the way you may see my design photo.

SeraOtomasyonSadeceGSM.ino (6.0 KB)

Is Arduino effected from harmonic or frequence converters?..

Regards,
Mucip:)

Hey mucip,

i cant find anything in the code by now... As said before i would change the resistor values.
If you have enough time you can try to minitor when this sus activity happens.

kind regards
finn

Hi,
What about harmonic or frequence converters effect to Arduino in the same room?!
How can I prevent this? Because it works good in the office.
Strange?!...

Regards,
Mucip:)

Hi,
Do you suggest to use 20-50K resistor?
I think I use already S3?... :thinking:

Regards,
Mucip:)

hey,

ive no clue, but do you know exactly where they come from?

kind regards
finn

Hi,
I can not say sharp! But it works in my office but doesn't work in the system room which has automations, PLC's, Frequence converters???

The only difference between my office and system room is this.

Regards,
Mucip:)

hi,
i found that here may it helps "Adding a line reactor or transformer in series** will significantly reduce harmonics, as well as provide transient protection benefits. Transformer connections can be employed to reduce harmonic currents in three-phase systems" on https://electrical-engineering-portal.com/principles-for-controlling-harmonics#:~:text=Adding%20a%20line%20reactor%20or,currents%20in%20three-phase%20systems.

kind regards
finn

Hi,
Thanks...
I will try to use phone charge power bank to feed arduino voltage tomorrow or later.

Regards,
Mucip:)

1 Like

Use switch change in state detection.

R1 as low as 1k can be used in the S2 circuit if the noise is significant.

You can debounce the input by seeing if a change is verified for a period of time, example, 50 to 100ms.

If you are using the S3 setup, you would be enabling the internal pullup resistor for that input.

If you still get false triggers, consider adding stronger (external) pullups. Try 10K to start with and go lower if need be. Don't go lower than about 1K, though.

Also, adding a 0.1uF ceramic cap across the switch can act to dump (decouple) noise off to ground.

That is no mystery, that is only to be expected.

What is causing the problem is EMI Electro Magnetic Interference. Due to your poor choice of resistors you have made your circuit more susceptible to EMI.

The fact that it will work in one place but not the other is due to the two environments of the rooms. One has little or no EMI and so even though your circuit has poor susceptibility, there is no problem.

The other room has a much higher level of EMI and so it is getting through and making your circuit not work.

The first thing you can do is to decrease the value of your pull up or pull down resistors. Try 1K to begin with, but go lower if you still have problems. If you get to 100R without improvement then you will have to make modifications to the source of the EMI to reduce it. But try using more sensible values of resistors to start with.

Hi,
Thanks a lot for valuable information.
Well, I will try 1 K resistor first as you suggested.
What can I do to reduce EMI in the system room? If I use batery pack to feed Arduino then it make sense?

Regards,
Mucip:)

A battery pack will make little or no difference, the EMI is a radio signal and doesn't effect the unwanted reception.

Add inductors in the form of ferrite beads or toroids to the power leads, is one simple way, but you might have to dismantle these things for a fix. There are limits to how much EMI things can emit , if these are commercial things, check they have been correctly certified to the standards you work to in your country.

Hi,
Really very valuable information. Thanks... :slight_smile:
Well, If I wrap up the Arduino box by aluminium thin sheet (Faraday Cage), Is this make sense?

Regards,
Mucip:)

No, it is a lot harder to make a leak proof cage than you think. Most times it only makes things worse.

Hi,
I used 220 ohm resistors as you suggested. It works like charm for more than one week.
Thanks a lot . :slight_smile:
Regards,
Mucip:)

Hi again,
I used this externel pull-up resistor with 140 ohm. But in some how and rarely it start without contact.
What else can I do to stop it?

Regards,
Mucip:)