I want to know how can i simulate the HYPERFLASH to a U-disk.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

I want to know how can i simulate the HYPERFLASH to a U-disk.

1,400 Views
vwsncr
Contributor II

Now i can simulate the SDCARD to a U-disk with SDK's example (RT1052). I change the SD driver to the HYPERFLASH driver , but it doesn't work .  

Tags (1)
0 Kudos
Reply
4 Replies

1,376 Views
diego_charles
NXP TechSupport
NXP TechSupport

Hi @vwsncr 

I hope you are doing excellent!

Generally speaking, I think that this can be achieved by creating an adapter file for the Hyperflash memory, like the usb_sdcard_adapter.c / .h  we have on the evkbimxrt1050_dev_msc_disk_bm example.

I do not know if you are also using our  i.MXRT1050 EVK, but please try to verify proper operation of the Hyperflash memory before hand. Please see the evkbimxrt1050_flexspi_hyper_flash_polling_transfer example. 

Also,  I recommend you to you  create a linkerscrypt to run the Hyperflash memory  APIs from SRAM, this in the case you are performing XIP from  this memory. Or  for test purposes link whole application to SRAM.

I do not know what is the source of the error, but if is  related to the Hyperflash adapter : Please try to diagnose which kind of error you are getting. For example, first see if you can initialize properly the memory and read out some commands, then see if erase operation is successful, and then if write is works too.

All the best, 

Diego.

 

 

 

0 Kudos
Reply

1,372 Views
vwsncr
Contributor II

Thanks !

   I 'm also using the board  i.MXRT1050 EVK. The USB and FLASH drivers all copy from example projects you said. I have tryed to write and erase the flash , it works well. 

    I use  a part of flash to save and run the program code , the other part simulate as U-disk .I don't know it is a good way or not .

    And i don't know how to create a linkerscrypt to run the Hyperflash memory APIs from SRAM.

0 Kudos
Reply

1,355 Views
diego_charles
NXP TechSupport
NXP TechSupport

Hi @vwsncr 

Thanks for your reply, 

The hyperflash example I mentioned containts a linker scrypt folder, that you can reuse on your project. 

The use of the linker scrypt folder to link flash APIs to SRAM, is particularly useful when the MCU is doing XIP and the application is writing/reading from the same flash memory. It seems that you are doing this, so I recommend you testing this way too.

Diego

 

 

 

0 Kudos
Reply

1,350 Views
vwsncr
Contributor II

Hi @diego_charles 

Thanks !

    Maybe i will try your advise later, because my group change the way to save pictures(.jpg). Thank you very much for your reply!