Forum Discussion
Altera_Forum
Honored Contributor
20 years agoand another uart problem.
hello guys, i'm having a problem with my FIFOED UART, The only thing im trying to do i send a big file over the uart and show on the Nios 2 Console that the data actually is being received...
Altera_Forum
Honored Contributor
20 years agoI agree too. You should have a while loop and read data until there is no more. I usually use a timeout to determine when there is no more. When you don't receive any data for at least 1 byte... or you can you 2 bytes (10 bits @ 9600 bits per second) then you can exit the loop. I use the timestamp functions in the HAL to determine the time to use the timeout.
Also... I have used printf's inside the interrupts with no problems however I only use them for debugging to make sure the interrupt is firing... then I comment them out.