sensitive input on device

Go To Last Post
7 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I found out, that ATtiny has a real sensitive input without pull-up. It light up led even if I put my hand over the board without touch... it also light up led if I touch the board on empty space!
Is it broke? ...if not, how can I prevent this happen?

I used this code:

sbic pina, 5
sbi porta, 7
sbis pina, 5
cbi porta, 7

Regards
heguli

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Floating input pins with no pull down or pull up are notorious for detecting noise and not being stable. Use a pull down or pull up on the input pin. If you use a pull up then you can enable the internal AVR pull up on the input pin without using any external components. If the environment is really noisy then there are other hardware/design options to consider.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Mike,

You are right, pull down resistor did the trick. I placed 4k7 resistor between input pin and ground... no more unwanted flashing.

thanks mate.

Regards
heguli

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

This is the second time I have seen 4k7 instead or 4.7K I thought the 4k7 was a typo but now I see it is a difference between US and UK.
I have to get out more....

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

also these goes:
1R2 = 1.2R or 1.2ohm 1M5 = 1.5M ...maybe we are just lazy :D

Regards
heguli

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

No the reason that the R, K or M is put in the middle is to show where the decimal point is. On a poor reproduction it would be very easy to mistake a 15kohm resistor for a 1.5kohm resistor.

using 1k5 and 15k the difference is obvious.

Tim

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

metro you really must not get out much =) I've seen 4k7 used many times, it's a very common way of labeling resistors that are big enough to have the real world values printed on them. 4.7k would be the way an engineer or someone who studying electronics would refer to them. People that deal with real world components all the time are more liable to be found using 4k7.

-Curiosity may have killed the cat
-But that's why they have nine lives