• Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

input pull-up GPIOs.

Status
Not open for further replies.

alphacat

New Member
Hello fellows.

When the MCU (CC2430) enters debug mode (after burning the code into it), and before I run the code, all GPIOs' outputs are 1 Logic.

Its a problem because I have an external device on the PCB, which 2 GPIOs are connected to it, and it must not receive two 1 Logics at the same time (the device must only receive the pairs (0,0), (0,1) or (1,0)).

I read in datasheet that all GPIOs of MCU are by default set to inputs and connected to pull-up resistors.
My question is, is it the reason why all outputs are 1L?
Meaning, if a pin is defined as input and connected to pull-up resistor, does it necessarily mean that its output would be 1L?

Thanks.
 

alphacat

New Member
Anyone knows pleaes?
My question is basically:
If a pin is defined as input and connected to pull-up resistor, does it necessarily mean that its output would be 1L?
I just want to know if an input pin can infulence on the external devices connected to it, like a base of a transistor for example.
 

3v0

Coop Build Coordinator
Forum Supporter
Anyone knows pleaes?
My question is basically:
If a pin is defined as input and connected to pull-up resistor, does it necessarily mean that its output would be 1L?
I just want to know if an input pin can infulence on the external devices connected to it, like a base of a transistor for example.
An input pin is high impedance (resistance). The circuit it is connected to does not know it is there, no influence.
If you use a pullup resistor on that pin, the resistor will pull the pin to a logical one. Just like it is supposed to.

3v0
 

be80be

Well-Known Member
I you make say GP0 an input and use a pullup resistor to VDD the pin will read as High or 1
And would read as high till you switch it to VSS this shows maybe better
 

Attachments

be80be

Well-Known Member
I just want to know if an input pin can infulence on the external devices connected to it, like a base of a transistor for example.
A input reads the pin a output
is what you'd hook the base of a Transistor. You could see if the base went low or high
 
Last edited:

alphacat

New Member
Thank you guys.

So if a GPIO input pin (which is connected to a pull-up) is connected to a transistor's base, then it could have the BJT conducting current through its C-E junction?
 

be80be

Well-Known Member
Your not going to do any thing useful with a transistor and a input pin. But see if the transistor has switched on
 

Leftyretro

New Member
Thank you guys.

So if a GPIO input pin (which is connected to a pull-up) is connected to a transistor's base, then it could have the BJT conducting current through its C-E junction?
If you mean internal 'soft' pull-ups then yes it will forward bias a attached transistor, however the base current is most likely to be much too low to do anything useful for the emitter/collector path. The internal pull-ups can be quite high in resistance, 20K or greater, but that depends on the specific chip.

Lefty
 

be80be

Well-Known Member
What chip has the
internal pullup is active
set to on I don't no of any
Most all are input till you set them as output. But you have to enable internal pullup.
 

colin mac

New Member
With the 8051, which is what I believe you are using, there's no difference between writing a logic 1 to the port when it's used as output and writing a logic 1 when it's to be made an input. You can only tell by looking at what's physically connected to the port. But it won't be able to turn on a transistor due to the internal pull-up.
 
Last edited:
Status
Not open for further replies.

EE World Online Articles

Loading
Top