本帖最后由 a6482546 于 2013-12-5 17:56 编辑
STM32 虚拟串口传输数据有误.一次最大传输64BYTE.
while (1)
{
while(scankeyup("A61440_2"));
// rt_thread_delay(MSec(10));
// rt_kprintf("send data\n");
Send_Buffer[0]++;
Send_Buffer[1]++;[attachimg]156712
USB_SIL_Write(EP1_IN, (uint8_t*) Send_Buffer, 63);
//USB_SIL_Write(EP1_IN, (uint8_t*) Send_Buffer, 64);
SetEPTxValid(ENDP1);
// while(scankeydown("A61440_2"));
}
延时加上时数据时正确的.当延时去掉了.数据就不对了
顺便问一下为什么用USB_SIL_Write(EP1_IN, (uint8_t*) Send_Buffer, 64)传送就不成功。
|