2019-10-30 05:31 AM
We are using stm32f769 with 8 gb EMMC , from other forums we understood that there is no HAL support for emmc for more than 2 gb , we are hard coding the emmc block count to 0x773594 and emmc block size to 0x200 . These values are calcuated in accordance to 8 gb storage . But the emmc card is full after 12 mb . Does anyone have a solution for emmc greater than 2 gb .
2019-10-30 05:57 AM
Fullness is something the file system would be managing, not sure I recall there being a byte vs block offset issue with the eMMC command interface, definitely have much large devices working on L4/F4/F7/H7 platforms.
2019-10-31 12:36 AM
When we tried reading EXTCSD register ,we are getting response timeout so we hardcoded the contents below.
The hard coded changes made are the following
hmmc1.MmcCard.BlockNbr = 0x773594
hmmc1.MmcCard.BlockSize = 0x200
hmmc1.MmcCard.LogBlockNbr = 0x773594
hmmc1.MmcCard.LogBlockSize = 0x200
capacity is changed to 0xFFFFFFF0U (4GB) from 0x80000000U(2 GB)
All the above parameters are calculated for the files to be stored till a limit of 4 GB , but the EMMC stores 12 MB of files. Beyond 12 MB when fopen call returns FR_DISK_ERROR .
Are we missing any other parameters that needs to be addressed ?
2019-10-31 04:13 AM
Sounds like it is scaling the block address.
Need to change the card type settings so it doesn't multiply.