USART1_Configure();
printf("this is a test of USART communciation\n");
printf("test is successful\n");
/*注释下方代码 USART通信正常*/
I2C_Config();
EEPROM_Write(0x00,36,I2C_Write1);
EEPROM_Write(0x70,20,I2C_Write2);
EEPROM_Read(0x00,36,I2C_ARR);
printf("%s",I2C_ARR);
printf("\n");
EEPROM_Read(0x70,20,I2C_ARR);
printf("%s",I2C_ARR);
printf("\n");
注释了I2C通信代码,串口通信会显示this is a test of USART communciation,test is successful,没注释的话连这些都不显示了
为什么会这样呢,,即使后面的代码有错,串口通信也应该正常啊,我花了五千年没想明白这个问题 |