Forum Discussion
Altera_Forum
Honored Contributor
21 years agoGreatWhite,
I'm the developer who wrote this. I think I've spotted your problem, and it's obscure, but I need you to try something for me. First a bit of background which may be of use to others reading this post. The pre-amble before the name of your file system is the zip file format see http://www.pkware.com/company/standards/appnote/ (http://www.pkware.com/company/standards/appnote/), PK0304 is the start of a file header The Zip filing system checks that all filesystems are valid before it mounts a filing system. If it's not valid it will not mount and all calls to fopen will fail. Normally this is because the flash file is not programmed correctly (however I don't think that's the problem in your case). The way to debug this would be open your Nios Device Drivers project in the IDE and set a breakpoint in alt_ro_zipfs_check_valid and find where under here the error occurs, it shouldn't be too hard However in your specific case I notice that the file starts 50 4b 03 04 14 00 02 00 The last two bytes here 0x2 are the general purpose bit flag from the specification The set bit, bit one has the description Bit 1: If the compression method used was type 6, Imploding, then this bit, if set, indicates an 8K sliding dictionary was used. If clear, then a 4K sliding dictionary was used. I've never seen this before, so if you could try something for me, if you open up the file altera_ro_zipfs.c and go to line 205 try replacing if (flags) by if (flags & 0xFD), let me know if this works.