Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
21605 Discussions

how to use printf in NIOS2 DE2

Altera_Forum
Honored Contributor II
1,769 Views

I am a newbie in the FPGA and NIOS world, i came across some labs and scripts available on line where they build a simple SOPC based NIOS 2 processor (with interval timer, JTAG, onchip mem) and then they used Eclipse to make a simple hello world program that would use printf("hello world"); that is suppose to print the message on the console of the eclipse IDE. i cant get it to work as i get an error saying the .elf executable file not found or the SDTOUT is not implemented on the hardware. I would really appreciate any help... thanks in advance.

0 Kudos
4 Replies
Altera_Forum
Honored Contributor II
593 Views

Do you have a space in the path to your project? If yes, move it somewhere else.

0 Kudos
Altera_Forum
Honored Contributor II
593 Views

I really don't get what you mean. Can you please give more details about the path that you want me to move in the project?

0 Kudos
Altera_Forum
Honored Contributor II
593 Views

NIOS has got problems when there are spaces in the filepath. So like "Altera Project" won't work nicely, but "AlteraProject" or "Altera_Project". The newest NIOS-Version normally warns you if there are any spaces in the path, I think. Check in the NIOS BSP-Editor, if the STDOUT is set to the right module and check your design, too.

0 Kudos
Altera_Forum
Honored Contributor II
593 Views

Some people also create their projects in a folder inside "My Documents" which will also create that kind of problems.

0 Kudos
Reply