Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
16606 Discussions

How to communicate with Nios using JTAG UART module.

Altera_Forum
Honored Contributor II
1,233 Views

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
Altera_Forum
Honored Contributor II
490 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
Altera_Forum
Honored Contributor II
490 Views

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

0 Kudos
Reply