中级会员
- 积分
- 213
- 威望
- 219
- 贡献
- 84
- 兑换币
- 0
- 注册时间
- 2012-3-22
- 在线时间
- 28 小时
- 毕业学校
- 东华大学
|
程序如下:
void main(void)
{
/* Write your local variable definition here */
/*** Processor Expert internal initialization. DON'T REMOVE THIS CODE!!! ***/
PE_low_level_init();
/*** End of Processor Expert internal initialization. ***/
for(;;)
{
AS1_SendChar('H');
AS1_SendChar('E');
AS1_SendChar('L');
AS1_SendChar('L');
AS1_SendChar('O');
}
/* Write your code here */
/* For example: for(;;) { } */
/*** Don't write any code pass this line, or it will be deleted during code generation. ***/
/*** Processor Expert end of main routine. DON'T MODIFY THIS CODE!!! ***/
for(;;){}
/*** Processor Expert end of main routine. DON'T WRITE CODE BELOW!!! ***/
} /*** End of main routine. DO NOT MODIFY THIS TEXT!!! ***/
串口AS1是由PE自动生成的,但是发送出来的数据就是乱码如下:
00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 E0 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0 00 00 E0
波特率什么的都是正确的,有没有相同问题的,急用呀,搞了几天了,做不下去了!
|
|