aashishsharma
Member level 5
Hey I just got confused with IO ports of microcontrollers.
1. Are IO ports in all the micro controllers uses open drain configuration?
2. Correct me If I am wrong when IO port is used as input it is always deliberately pulled up to positive high voltage as if its left open then noise can make it 0 or 1 but if its pulled up then noise can have no effect on it whatsoever but downside is that input must be inverted( as if switch is connected to this port and this port is configured as input then switchpress can be detected if switchpress give 0 volt to the pin otherwise its already pulled up) Thus we can only detect the presence of 0 volt on this input configured port.
3.I used atmega 8/16 microcontroller and IO ports were not that comlicated. I started to study 8051.
Datasheet says writing 1 to port register makes it input( reverse of atmega8/16). Now if you look internally Writing 1 means internally base is given higher voltage. Right? but if base is always at logic one how can transiter act like switch atall? afterall this is how open drain configuration work
1. Are IO ports in all the micro controllers uses open drain configuration?
2. Correct me If I am wrong when IO port is used as input it is always deliberately pulled up to positive high voltage as if its left open then noise can make it 0 or 1 but if its pulled up then noise can have no effect on it whatsoever but downside is that input must be inverted( as if switch is connected to this port and this port is configured as input then switchpress can be detected if switchpress give 0 volt to the pin otherwise its already pulled up) Thus we can only detect the presence of 0 volt on this input configured port.
3.I used atmega 8/16 microcontroller and IO ports were not that comlicated. I started to study 8051.
Datasheet says writing 1 to port register makes it input( reverse of atmega8/16). Now if you look internally Writing 1 means internally base is given higher voltage. Right? but if base is always at logic one how can transiter act like switch atall? afterall this is how open drain configuration work