Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Honored Contributor I
759 Views

How to communicate with Nios using JTAG UART module.

Hi All, 

I'd like to communicate with a nios system using a JTAG uart module, but I don't know which functions and libraries I have to use in nios C-program.. 

I have designed a system to glow the LED's depending on data sent from console.  

printf() can be used to send data to the console. But i couldn't find any function which is similar to scanf() which reads data from console. 

I have built my system using Qsys, now i'am writing a software application in C to read data from console and give it to the display. 

please help.
0 Kudos
2 Replies
Highlighted
Honored Contributor I
16 Views

It all depends on which OS you are running on the Nios II 

 

If you're running the basic HAL then if I remember right getchar() is the function you should be calling.
0 Kudos
Highlighted
Honored Contributor I
16 Views

I tried using getchar() but it doesn't seem to work.

0 Kudos