- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi
I'm using Quartus II 12.1 to develop software for nios II processor I fallowed this wiki page (http://www.alterawiki.com/wiki/readonlyzipfilesystem) to enable the zipfs on nios II but i can't access the zip files using nios ii and my pointer always return NULL I'm using EPCS as my flash memoy to store the zip file, i double check the base address and the offset and also program the epcs for several times (I was successfull in programming the EPCS) I don't know that may cause this problem below is the sample code that i used to access the zip file --- Quote Start --- FILE* fp = NULL; /* * Open and print contents of ZipFS file 1. */ printf("Reading file 'file1.txt' from ZipFS...\n"); fp = fopen ("/mnt/rozipfs/file1.txt", "r"); if (fp == NULL) { printf ("Cannot open file.\n"); exit (1); } --- Quote End --- Please give me some suggestionLink Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
IIRC the zipfs requires the data to be directly mapped in the CPU's address space, so you can only use it with a parallel flash. I think that if you search on this forum you'll find a thread about someone that tried to port it to use the EPCS controller's read and write functions, but I don't remember whether it worked correctly or not.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you so much, zipfs now work on parallel flash
I have another question, can i access the zipfs in the nios run mode or it's only accessible in debug mode? In the debug mode i can print the content of my text file (which is in the zipfs) on the screen but in the run mode nothing is printed on the screen- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The rozipfs can be used in both debug and run modes. I suggest that you write more debug information from your code to see what is wrong (especially if any error is returned when you are trying to open the file).
There is another filesystem module available on Nios that is called the host filesystem. This modules allows the application running on the Nios to directly read/write files on the host PC. This module only works in debug mode.
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