Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++

help : Toshiba flash

Altera_Forum
Honored Contributor II
936 Views

Hi: 

now I found the flash using in UP3 is TC58FVB160AFT ,which offered by Toshiba , meanwhile I found a file of the " tc58xx" in the directory "\cgywin\altera\components\ecos\ecos-current\packages\devs\flash\toshiba" , and in the subdirectory of the "current/ inc" of the "tc58xx" , there are two files: " flash_tc58xxx.inl" and " flash_tc58xxx_parts.inl " , I think if I can use the same drivers of the "flash_tc58xxx.inl" to driver the flash TC58FVB160AFT . is it right or not ? 

thks advance
0 Kudos
4 Replies
Altera_Forum
Honored Contributor II
245 Views

FYI: Some of the UP 3s also come with an ExcelSemi flash instead of the Toshiba flash device. The ExcelSemi flash chips seem to work with the default Altera CFI flash drivers. The manufacturer is printed on the flash chip, U8, right below the FPGA.

0 Kudos
Altera_Forum
Honored Contributor II
245 Views

Hi: 

Yeah ,some up3 kits come with ExcelSemi flash ,and some come with Toshiba flash . and all of the two types flash can work with default altera CFI drivers ,but now I want to make flash work on the ecos , I think the drivers of flash on ecos are different from the drivers offered by altera. so I should write the flash drivers on ecos system. meanwhile ,there are some drivers about Toshiba flash in the files of "flash_tc58xxxx.inl" and "flash_tc58xxxx_parts.inl" , but the chips included in the files are some different from UP3 flash, therefore , I want to know if I can use the default altera CFI drivers to driver the flash on ecos , if not ,how to write the ecos drivers of the flash ? 

thanks!
0 Kudos
Altera_Forum
Honored Contributor II
245 Views

On my UP 3 boards, with Toshiba flash chips the default Altera CFI Flash drivers do not seem to work. I had heard that SLS corp (makers of UP 3 boards) are working on a new Flash driver for the Toshiba (but not for eCos as far as I know).

0 Kudos
Altera_Forum
Honored Contributor II
245 Views

Unfortunately you cannot use the Altera CFI flash driver with eCos since eCos is based on the eCos HAL, rather than the Altera HAL - so you will need to provide an eCos specific driver for your flash part. 

 

My guess would be that flash_tc58xxx.inl is a good starting point, although I haven't personally used these flash parts/your board - so I can't be certain. 

 

As far as I'm aware, there's no documentation on how to write flash drivers for eCos. The best way at this is to follow the existing examples, and read the comments in the apropriate source code. In your case moab_nand_flash.c may serve as a useful example. 

 

An explanation of the macros you will need to define (such as CYGNUM_FLASH_INTERLEAVE) can be found in flash_tx58xxx_parts.inl. 

 

In addition, the flash driver provided for the flash on the Nios II development board may help explain how to access Nios II specific information (such as the base address of the flash part). 

 

Good luck!
0 Kudos
Reply