??? 05/04/08 02:29 Read: times |
#154360 - Scary Bible Responding to: ???'s previous message |
The Bible said:
The reason that read-modify-write instructions are directed to thelatch rather than the pin is to avoid a possible misinterpretation of the voltage level at the pin. For example, a port bit might be used to drive the base of a transistor. When a 1 is written to the bit, the transistor is turned on. If the CPU then reads the same port bit at the pin rather than the latch, it will read the base voltage of the transistor and interpret it as a 0. Reading the latch rather than the pin will return the correct value of 1.
My first impression when reading this was that the author had misunderstood something. After about 2 seconds I realized that this is actually entirely correct. You really can omit the base resistor on every other port than P0. That saves helluva lot of PCB area, and Aspirin. However, valium will be needed if one tries to implement this on P0. Avinash - can You tell us why ? |
Topic | Author | Date |
P0 pull up resistors | 01/01/70 00:00 | |
ports structure | 01/01/70 00:00 | |
More Port 0 history | 01/01/70 00:00 | |
Of course, there is a reason for it... | 01/01/70 00:00 | |
Port 0 Pullups WHY??? | 01/01/70 00:00 | |
P0 is multiplexed for input/output; P2 is not | 01/01/70 00:00 | |
This would all be perfectly obvious if only you\'d | 01/01/70 00:00 | |
See this thread | 01/01/70 00:00 | |
Scary Bible | 01/01/70 00:00 | |
Only In Some Cases.... | 01/01/70 00:00 | |
Directly connecting the base will hardly work! | 01/01/70 00:00 | |
Hardly is correct.... | 01/01/70 00:00 | |
what about a darlington? | 01/01/70 00:00 | |
Will also turn off the weak pull-up... | 01/01/70 00:00 | |
The high state is adequate for some things | 01/01/70 00:00 | |
OH![]() | 01/01/70 00:00 |