Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[threadx] FileX Clarification for correct configuration on SPI Flash
  • From: Davide Dal Frà <d.dalfra@xxxxxxxx>
  • Date: Sat, 14 Sep 2024 07:23:06 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vt100.it; dmarc=pass action=none header.from=vt100.it; dkim=pass header.d=vt100.it; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Kye4Tszi81tjS+werAzW0lDTG9C6vBv6zNrijF2rz3Q=; b=yCRZR4k2+HnB2tbinvuOWL2MN0ey4bl0VGfl/UBk2UmmRGxAgDkHbH7tzcIAVSTkj5/0yxkdTJgaJpPBrTuaG9qCEWR9L/KzQFeDIbHKV/3xpb1aSJQAjieLm8cQY9RbJIVcvQqLcjuVL5xzF4Zo1JBBtKK4oEXZmyFopPlPWUS2AHKK8iY7DPhaBQCQ5Bfi8jcI1/Fq2de9AtHMkpU418I+izxaDwu5ma7PKHmu6sUgnFDc5zYgGrRRHqG5LHImOyZ7A9rd6RToKSl9/dn+/z+iB7uPIDM3mqYprce86fyOA8NirHz3HjA7PFzmTFWQtOLVfFS6swFinsy0n+giSg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=YvuI+vPEVWt5yipHotPvKzgJZ5vtiMraMHsHUvn3zME++mZbYicV/HDOehzYi8F2vhHLcBJyQqvJz7Wn2Fgw5Xh/khQO1KLZ6sr0nS2e4KLgQNyE1P7Y6mBeOIS0zABTuwNgyLDWGK1WmO0jUw3wzrHC/L9rwjVTeK0aY/Db6rthmosJx61XgIZpD4YD3Ky3hFhcRZvDIjEp+EP+44+m4jTn77nobgmyLZ3d9m2503OoAun+qoeKe0vsRlZ8cTZDt3vz5c47KCdj0L3dhoC3TgGptNMYkDWc7iOlKXPvRrDuqKfWu/rMsA6FluDF4wkWZpRZD9lB/k5ofmrGunoHZQ==
  • Delivered-to: threadx@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/threadx/>
  • List-help: <mailto:threadx-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/threadx>, <mailto:threadx-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/threadx>, <mailto:threadx-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AdsGdvCNgBvO0W7iTSe587zBJt+B4Q==
  • Thread-topic: FileX Clarification for correct configuration on SPI Flash

Hello Folks

 

I’m integrating FileX on a system that uses MX25L6433F which is a 64Mbit, SPI Flash where the minimum erasable block is 4K while the minimum programming page is 256byte.
The driver I use to write and read from/to the flash is something we’re successfully using since 5years, so the integration with LX driver has been done quite easy.

I would need some clarification on what really needs to be used as init parameters for the fx_media_format. More specifically if any of the following parameters need to respect some ratio or some physical configuration of the external flash (or are they just logical?)


/*    number_of_fats                        Number of FAT tables          */
I assume this should be 1, found in all examples both in ST and Renesas folders.

/*    directory_entries                     Number of directory entries   */

32. I think this is more related to the FAT structure, so nothing care about flash physical characteristics. Right?

 

/*    hidden_sectors                        Number of hidden sectors      */

0, Same as before.

 

/*    total_sectors                         Total number of sectors       */
Shall this be related to the flash physical configuration?
I.e., if my flash is 64 MBIT = 8192KB, shall this respect the number of 4K sector available ? (8192KB/4KB = 2048 )

Or shall be based on the minimum page write size capability (256 byte) ?

 

/*    bytes_per_sector                      Number of bytes per sector    */
Same consideration as before. Is this related to physical characteristic ?( so I assume 4096byte in case we consider the minimum erasable capability of the flash)
Or is something logical that does not care about physical flash feature?

 

/*    sectors_per_cluster                   Number of sectors per cluster */

1, assume this is just logical

 

/*    heads                                 Number of heads               */
1, assume this is just logical

 

/*    sectors_per_track                     Number of sectors per track   */

1, assume this is just logical

 

 

Furthermore (promise, this is the last question): The define LX_NOR_SECTOR_SIZE , shall respect the minimum erasable sector of the flash ? I see examples that takes values starting from 256 to 512 byte.

/* Define the logical sector size for NOR flash. The sector size is in units of 32-bit words.

   This sector size should match the sector size used in file system.  */

/*

#define LX_NOR_SECTOR_SIZE                          (512/sizeof(ULONG))


 

Thanks in advance to ll for the time spent for reading my email,

 

Regards

Davide

 

 

 

 

 


Back to the top