Altera_Forum
Honored Contributor
11 years agosystem console master_read_to_file
Hi guys
I am very new to altera, fpgas, qsys and system console, but i have managed to get a basic spi interface working with my DUT. Works very well. The code was done with qsys and nios ii and software on a modified hello world in eclipse. My next task is to transfer the data that the alt_avalon_spi receives from my DUT back to my host pc. One thing that looked promising was using system console with some tcl scripts. i watched a few tutorials on it, but cant quite get it. i think that master_read_to_file might be what i need: % help master_read_to_file Uploads data from memory accessible from the specified master channel to a binary file on disk Arguments: <service-path> <filename> The file to write to <address> Start address in memory <count> Number of bytes to write to file I am able to connect to the master nios but i cant get my command to work... im assuming that system console has access to my pc c: drive... I believe that i should be using my onchip mem address for address and i just wanted to test it with something small (1000 bytes) so im using this command master_read_to_file $mypath 'c:\mydir\file11.bin' 0x00040000 1000 no errors come back but no file gets created either. Can you guys tell me what im doing wrong? and where/what is a valid file path for the file? Ill worry about linking my c code variables to onchip memory later (any pointers on that would be appreciated too) thanks!