Forum Discussion
Altera_Forum
Honored Contributor
20 years agoHow to start application automatically?
Hello.
I use Nios2 dev kit(Stratix2). I want to start application after power on without PC. (The application controls LED & CF.) When I input "nios2-terminal" from SDK shell, then application start. But if nios2-terminal is not executed, the application doesn't start. How should I do to startup my application after power on without PC ? This may be very elementary question, but I'm newbie and I couldn't find answer. So. please help me. Thank you.6 Replies
- Altera_Forum
Honored Contributor
I am having the same problem but with the CycloneII dev. kit.
We have spoken with an Arrow FAE but he had no ideas. We tried an uC/OS-II example and it does NOT have the same problem. So, it is looking to be an eCos issue. ANY ideas are welcome. We don't have redBoot - is this required? Thanks - Altera_Forum
Honored Contributor
--- Quote Start --- originally posted by pxs@Mar 31 2006, 02:28 PM i am having the same problem but with the cycloneii dev. kit.we have spoken with an arrow fae but he had no ideas.
we tried an uc/os-ii example and it does not have the same problem.
so, it is looking to be an ecos issue.
any ideas are welcome.
we don't have redboot - is this required?
thanks
<div align='right'><{post_snapback}> (index.php?act=findpost&pid=13952)
--- quote end ---
--- Quote End --- Do you have any output (printf) that goes to the jtag uart? I had similar problems when the application (including the ecos lib) printed any diagnostic information. Try to suppress all output to the jtag uart (I think the rs232 uart should work) by setting the debug device and the diagnostic console device to none.
- Altera_Forum
Honored Contributor
--- Quote Start --- originally posted by orsino+apr 3 2006, 12:15 pm--><div class='quotetop'>quote (orsino @ apr 3 2006, 12:15 pm)</div>--- quote start ---
<!--quotebegin-pxs@Mar 31 2006, 02:28 PM i am having the same problem but with the cycloneii dev. kit.
we have spoken with an arrow fae but he had no ideas.
we tried an uc/os-ii example and it does not have the same problem.
so, it is looking to be an ecos issue.
any ideas are welcome.
we don't have redboot - is this required?
thanks
<div align='right'><{post_snapback}> (index.php?act=findpost&pid=13952)
--- quote end ---
--- Quote End --- Do you have any output (printf) that goes to the jtag uart? I had similar problems when the application (including the ecos lib) printed any diagnostic information. Try to suppress all output to the jtag uart (I think the rs232 uart should work) by setting the debug device and the diagnostic console device to none. <div align='right'><{post_snapback}> (index.php?act=findpost&pid=13985)</div> [/b] --- Quote End --- You are may be right. Any data sending via jtag_uart (printf) would be filling fifo of jtag_uart. If jtag is not connected and appropriate app is not ran nios would be stoped.
- Altera_Forum
Honored Contributor
Thanks,
That seems be the problem. I have set the stdin, stdout, stderr to null and within ecos set the "debug Device" and "Diagnostic console device" to none. The system boots without the need of nios2-terminal! I am now testing if I can put the stdin value to /dev/uart. I would like the printf out the rs232 port. Thanks for the help. - Altera_Forum
Honored Contributor
We have done some further investigation:
We set the nios library application settings to: stdin : uart1 stdout: uart1 stderr: uart1 We set the following configuration parameters in the configtool for eCos to: NIOS2 Architechture Debug Device /dev/uart1 Diagnostic console device /dev/uart1 HAL SOPC drivers check the "Detected SOPC devices" box Serial device drivers check "Hardware serial device drivers" box - Altera_Forum
Honored Contributor
Thank you, orsino, slava!
I deleted "printf", then my application started automatically. Thank you very much. I'm sorry for my late replay.