救命!!关于AT89C2051的P1口的用法!!??注:P1口作为输入和输出口,P1.0和P1.1口线作为输出口时,要接上拉电阻,而作为输入口时,要接下拉电阻。但是程序就是不能运行!!
P1口作为键盘扩展口,其中利用到P1.0,P1.1,P1.2以及P1.4,P1.5,P1.6六个口线!
p1.0,p1.1要加上拉,不要下拉。。。。。。。。
P1.0和P1.1我都没有下拉电阻!!
可你刚刚说过有的啊 看看你开始的帖子
不好意思!我写错了!
P1口我也认为
问题以及解决!谢谢各位! 现在把P1口描叙如下:
Port 1
Port 1 is an 8-bit bi-irectional I/O port. Port pins P1.2 to P1.7 provide internal Pullups. P1.0 and P1.1 require exter-nal pullups. P1.0 and P1.1 also serve as the positive input (AIN0) and the negative input (AIN1), respectively, of the on-chip precision analog comparator. The Port 1 output buffers can sink 20 mA and can drive LED displays directly.When 1s are written to Port 1 pins, they can be used as inputs. When pins P1.2 to P1.7 are used as inputs and are externally pulled low, they will source current (I IL ) because of the internal pullups.
Port 1 also receives code data during Flash programming
and verification.
p2和p0口的资料您给我们也看看吧
AT89C2051没有P2和P0口! Port Pin Alternate Functions
P3.0 RXD (serial input port)
P3.1 TXD (serial output port)
P3.2 INT0 (external interrupt 0)
P3.3 INT1 (external interrupt 1)
P3.4 T0 (timer 0 external input)
P3.5 T1 (timer 1 external input)
那P2口和P0
COME,ON!
谢谢!你在那里找到的?
没有用过,你去www.21ic.com看看!