- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
sorry, my english is poor.
I transmit a wavfile to Nios II within MSCOMM32.OCX baud rate=115200 bps data bit=8 parity bit=none stop bit=1 RECEIVER in Nios II IDE alt_16 buf;
for(i=0;i<160;i++){
fread(&buf, sizeof(alt_16), 1, uart); //read data from file
if(buf==0x4F4B) break; //"OK"
IOWR(USER_RAM_BASE, i, buf); //write data to RAM and play sound
}
My transmitter transmit data to receiver, but receiver get only incomplete data. eg. I transmit 0x2353, 0x6411, 0x4235, receiver get only 0x2353, 0x6435, etc. I guess that transmit speed too fast and transmit buffer too small. But I can't how to solve it. thx Orz
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
if the uart buffer is overloaded then data will get lost.
you should implement some handsahe between reciver and transmitter the buffer i'm using is 64bytes so the transmiter will not send more then 64 bytes until the reciver didn't signal that it can read more bytes
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page