- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I want to read the flash thru the EPCS device. The HAL alt_flash_open_dev() always returns 0. When I debug/trace the this function call, it seems that the HAL system can not find such device. Does any one know how I can fix this problem? BTW: The system.h does contain a defintion of the flash:# define EXT_FLASH_NAME "/dev/ext_flash"# define EXT_FLASH_TYPE "altera_avalon_cfi_flash"# define EXT_FLASH_BASE 0x00000000# define EXT_FLASH_SETUP_VALUE 40# define EXT_FLASH_WAIT_VALUE 160# define EXT_FLASH_HOLD_VALUE 40# define EXT_FLASH_TIMING_UNITS "ns"# define EXT_FLASH_UNIT_MULTIPLIER 1# define EXT_FLASH_SIZE 8388608# define EXT_FLASH_CONTENTS_INFO "" Regards, Kwok WongLink Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello kwokwong,
What kind of flash, board, Nios version are you using? There has been some trouble with 16 bit flashs in 8 bit mode. Please try to use the search function of the forum to get some hints. Let us know if you have solved the problem. Bye, niosIIuser- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
kwokwong,
I'm afraid your diagnosis is incorrect, The system.h snippet shows that you have a CFI flash in your system, NOT an EPCS. That would require a snippet like # define EPCS_CONTROLLER_NAME "/dev/epcs_controller"# define EPCS_CONTROLLER_TYPE "altera_avalon_epcs_flash_controller"# define EPCS_CONTROLLER_BASE 0x02100000# define EPCS_CONTROLLER_IRQ 5# define EPCS_CONTROLLER_DATABITS 8# define EPCS_CONTROLLER_TARGETCLOCK 20# define EPCS_CONTROLLER_CLOCKUNITS "MHz" Do you have one of these in your system?- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--- Quote Start --- originally posted by rugbybloke@Dec 8 2004, 05:10 AM kwokwong,
i'm afraid your diagnosis is incorrect,
the system.h snippet shows that you have a cfi flash in your system, not an epcs. that would require a snippet like
# define epcs_controller_name "/dev/epcs_controller"# define epcs_controller_type "altera_avalon_epcs_flash_controller"# define epcs_controller_base 0x02100000# define epcs_controller_irq 5# define epcs_controller_databits 8# define epcs_controller_targetclock 20# define epcs_controller_clockunits "mhz"
do you have one of these in your system? --- Quote End --- Thanks rugbybloke. I did confuse the external flash with the flash connected to the EPCS controller. I can now 'open' the /dev/epcs_controller device to read the flash! Regards, Kwok Wong
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