Forum Discussion
Altera_Forum
Honored Contributor
20 years agoProblem with Flash alt_flash_open_dev()
Problems with: alt_flash_open_dev() I am running the memtest.c program that Altera provides with the Nios II IDE. It runs as expected when testing RAM but I have problems when testing Flash....
Altera_Forum
Honored Contributor
20 years agoJim,
The "/dev/..." virtual filesystem is always set in the device initialization code. The fact that it's returning 0 means that initialization is failing, which goes along with the CLI flash programming results you posted. If you were to step through the initialization code, you would see sections where it reads the flash device to determine what type of flash it's accessing. The initialization "function" can be found in <nios2_root>/components/altera_avalon_cfi_flash/HAL/src/altera_avalon_cfi_flash.c. In any case, you do have some sort of connection/hardware issue, as you've already determined. Best of luck, - slacker