Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Valued Contributor III
834 Views

UFM initialization - how to reach sector 2?

Hi everyone, (this is my 1rst post here) 

 

I'm trying to use the UFM macro on a MAX 10 - 04. I've generated a customized IP (see parameters below, as set by QSys ip generator). I've also generated a .dat file (see below) with 18432 32-bits values, for UFM initialization. 

 

In my simulation test bench I read some addresses of it. It does work for lower addresses (up to 0x4000), but for higher addresses (as soon as i try to read 0x5000) I get wrong values, like 0xFFFFFFFF (see attached waveform!)... as if the memory hasn't been initialized with the .dat values. 

This seems to match with the start of "sector 2" as defined in the module parameters by qsys. 

 

How can I initialize these higher addresses, at least in simulation? 

 

Thanks, 

laurent 

 

 

onchip_flash_0 : component altera_onchip_flash generic map ( INIT_FILENAME => "nvm.hex", INIT_FILENAME_SIM => "nvm_simu.dat", DEVICE_FAMILY => "MAX 10", PART_NAME => "10M04SAU169I7G", DEVICE_ID => "04", SECTOR1_START_ADDR => 0, SECTOR1_END_ADDR => 4095, SECTOR2_START_ADDR => 4096, SECTOR2_END_ADDR => 25087, SECTOR3_START_ADDR => 0, SECTOR3_END_ADDR => 0, SECTOR4_START_ADDR => 0, SECTOR4_END_ADDR => 0, SECTOR5_START_ADDR => 0, SECTOR5_END_ADDR => 0, MIN_VALID_ADDR => 0, MAX_VALID_ADDR => 25087, MIN_UFM_VALID_ADDR => 0, MAX_UFM_VALID_ADDR => 25087, SECTOR1_MAP => 2, SECTOR2_MAP => 3, SECTOR3_MAP => 0, SECTOR4_MAP => 0, SECTOR5_MAP => 0, ADDR_RANGE1_END_ADDR => 25087, ADDR_RANGE1_OFFSET => 4608, ADDR_RANGE2_OFFSET => 0, AVMM_DATA_ADDR_WIDTH => 15, AVMM_DATA_DATA_WIDTH => 32, AVMM_DATA_BURSTCOUNT_WIDTH => 4, SECTOR_READ_PROTECTION_MODE => 31, FLASH_SEQ_READ_DATA_COUNT => 2, FLASH_ADDR_ALIGNMENT_BITS => 1, FLASH_READ_CYCLE_MAX_INDEX => 4, FLASH_RESET_CYCLE_MAX_INDEX => 8, FLASH_BUSY_TIMEOUT_CYCLE_MAX_INDEX => 38, FLASH_ERASE_TIMEOUT_CYCLE_MAX_INDEX => 11200000, FLASH_WRITE_TIMEOUT_CYCLE_MAX_INDEX => 9760, PARALLEL_MODE => true, READ_AND_WRITE_MODE => false, WRAPPING_BURST_MODE => false, IS_DUAL_BOOT => "False", IS_ERAM_SKIP => "True", IS_COMPRESSED_IMAGE => "False" )  

 

nvm_simu.dat file: it is a nice 18432-lines ramp 

00000000 00000001 00000002 00000003 ... ... 000047FA 000047FB 000047FC 000047FD 000047FE 000047FF
0 Kudos
0 Replies