Continue to Site

how to use Pull up resistors in AVR??

Status
Not open for further replies.

eng_ahmed22

Full Member level 3
Full Member level 3
Joined
Jun 7, 2005
Messages
189
Helped
20
Reputation
40
Reaction score
5
Trophy points
1,298
Activity points
2,945
hi all
I want to ask a question.
the Pull up resistance must be activated wahen i use the port as input or as output in the AVR mc???
I know that this is a stupide question :cry: but really i want to understand it, pls help

salaam All
yours:
Ahmed
 

As soon as you declare a pin as output the pullup is switched OFF..
If you want a pin not to interfere with any other pins connected to the same wire you also switch the pullup of - High-Z ..
In normal situation when a pin is defined as INPUT you will need the pullup to be active as there is nothing to define a "1" on this pin ..

Regards,
IanP
 

If you are using input as a digital one and you are driving input with the open collector(swithing to ground) you can use internal pull up instead of mounting the external one.
Greetings
Dragan
 

it is infact a weak pullup and is enabled only when the pin is configured for input.
 

If u wan to have a more accurate input, use external pull-up resistor.

Or else, u can also set it as "1" in ur program. Then the push button is connected to Gnd. When it detects smaller than 1, then proceed with wat u wan.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top