- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
how can I start the nios2 command line tools e.g "elf2flash"
from a windows batch file ? I can use for example %QUARTUS_ROOTDIR%\bin\cygwin\bin\bash.exe -c ". myscript" it starts the script "myscript", but the enviroment is not setup, there are missing some directories. if I use the following, the startup script is not called %QUARTUS_ROOTDIR%\bin\cygwin\bin\bash.exe --rcfile %SOPC_KIT_NIOS2%\nios2_sdk_shell_bashrc -c ". myscript"Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am not a scripting expert so I can't tell you why your last try isn't working.. but it occurs to me that you could make your own rcfile, based on the one that is used to setup the environment correctly (nios2_sdk_shell_bashrc) -- then at the end of that file perform the tasks that you need scripted.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can script the Nios2 command line tools from the Nios II SDK Shell. You just create a .sh file and run it using "bash <name>.sh" with all your commands contained within it.
To see the commands available look at your C:\<nios install directory>\bin folder- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
thanks,
starting scripts from the NIOS2 SDK SHELL already works, to start a script from windows, e.g. with doppelclick from explorer, it works if I start my scripts in the following way: FILE: flash_sw_dviboot01.bat --------------------------------------------------------------------- %QUARTUS_ROOTDIR%\bin\cygwin\bin\bash.exe -c ". flash_sw_dviboot01" pause --------------------------------------------------------------------- SHELL SCRIPT: flash_sw_dviboot01 --------------------------------------------------------------------- source $QUARTUS_ROOTDIR/sopc_builder/bin/nios_bash sh flash_sw ../8DIO010_SOFTWARE/dvi_boot01/debug/dvi_boot01.elf --------------------------------------------------------------------- however the nios startupscript "nios_bash" takes a lot of time, perhaps someone has a faster startup script ?- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Now you have lost me, do you want to script Nios II command line tools or just have Cygwin load one second faster???
Scripts are suppose to coordinate command based flow. Chances are if you want to script some sort of flow the amount of time for Cygwin to come up is nothing compared the execution of the script.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page