//example5:The status of the P1 port is sent to P0,P2 and P3 ports.
//respectively to understand the pin function the I/O port
#include<reg51.h>
void main(void)
{
while(1)
{
P3=0xff;
P2=P3;
}
}
ex5:将P1口状态送入P0,P2和P3
于 2024-03-10 18:56:40 首次发布