Altera_Forum
Honored Contributor
9 years agoprintf broken after restart
Hey,
I built a very simple project with only nios II/f on-chip memory and jtag uart. I created a basic hello world template. My hardware is the MAX 10 development kit. Everything works including printf. The problem is that when I power off the board and then back on everything works but the printf does not print to console. If I pause in debug I can see that it is stuck on the line while ( (sp->tx_out != sp->tx_in) && (sp->host_inactive < sp->timeout) at file altera_avalon_jtag_uart_init.c I have to program the FPGA again for the printf to work again. Same thing happens with UART - after programming everything works, after shutdown and power on again - not working (Though Nios does work). Status register stays 0, trdy bit is therefore 0. can I reset it somehow? I tried to reset through the jtag and also from a button, doesn't solve it. What am I missing? Thanks, Eyar