Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: Space_Invaders_Demo neopixels gpio_test_stm32f3_discovery gpio_test_systimer ... more
NAND Controller functions
[FMC_Private_Functions]
NAND Controller functions. More...
Functions | |
| void | FMC_NANDDeInit (uint32_t FMC_Bank) |
| De-initializes the FMC NAND Banks registers to their default reset values. | |
| void | FMC_NANDInit (FMC_NANDInitTypeDef *FMC_NANDInitStruct) |
| Initializes the FMC NAND Banks according to the specified parameters in the FMC_NANDInitStruct. | |
| void | FMC_NANDStructInit (FMC_NANDInitTypeDef *FMC_NANDInitStruct) |
| Fills each FMC_NANDInitStruct member with its default value. | |
| void | FMC_NANDCmd (uint32_t FMC_Bank, FunctionalState NewState) |
| Enables or disables the specified NAND Memory Bank. | |
| void | FMC_NANDECCCmd (uint32_t FMC_Bank, FunctionalState NewState) |
| Enables or disables the FMC NAND ECC feature. | |
| uint32_t | FMC_GetECC (uint32_t FMC_Bank) |
| Returns the error correction code register value. | |
Detailed Description
NAND Controller functions.
===============================================================================
##### NAND Controller functions #####
===============================================================================
[..] The following sequence should be followed to configure the FMC to interface
with 8-bit or 16-bit NAND memory connected to the NAND Bank:
(#) Enable the clock for the FMC and associated GPIOs using the following functions:
(++) RCC_AHB3PeriphClockCmd(RCC_AHB3Periph_FMC, ENABLE);
(++) RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOx, ENABLE);
(#) FMC pins configuration
(++) Connect the involved FMC pins to AF12 using the following function
GPIO_PinAFConfig(GPIOx, GPIO_PinSourcex, GPIO_AF_FMC);
(++) Configure these FMC pins in alternate function mode by calling the function
GPIO_Init();
(#) Declare a FMC_NANDInitTypeDef structure, for example:
FMC_NANDInitTypeDef FMC_NANDInitStructure;
and fill the FMC_NANDInitStructure variable with the allowed values of
the structure member.
(#) Initialize the NAND Controller by calling the function
FMC_NANDInit(&FMC_NANDInitStructure);
(#) Then enable the NAND Bank, for example:
FMC_NANDCmd(FMC_Bank3_NAND, ENABLE);
(#) At this stage you can read/write from/to the memory connected to the NAND Bank.
[..]
(@) To enable the Error Correction Code (ECC), you have to use the function
FMC_NANDECCCmd(FMC_Bank3_NAND, ENABLE);
[..]
(@) and to get the current ECC value you have to use the function
ECCval = FMC_GetECC(FMC_Bank3_NAND);
Function Documentation
| uint32_t FMC_GetECC | ( | uint32_t | FMC_Bank ) |
Returns the error correction code register value.
- Parameters:
-
FMC_Bank,: specifies the FMC Bank to be used This parameter can be one of the following values: - FMC_Bank2_NAND: FMC Bank2 NAND
- FMC_Bank3_NAND: FMC Bank3 NAND
- Return values:
-
The Error Correction Code (ECC) value.
Definition at line 555 of file stm32f30x_fmc.c.
| void FMC_NANDCmd | ( | uint32_t | FMC_Bank, |
| FunctionalState | NewState | ||
| ) |
Enables or disables the specified NAND Memory Bank.
- Parameters:
-
FMC_Bank,: specifies the FMC Bank to be used This parameter can be one of the following values: - FMC_Bank2_NAND: FMC Bank2 NAND
- FMC_Bank3_NAND: FMC Bank3 NAND
NewState,: new state of the FMC_Bank. This parameter can be: ENABLE or DISABLE.
- Return values:
-
None
Definition at line 476 of file stm32f30x_fmc.c.
| void FMC_NANDDeInit | ( | uint32_t | FMC_Bank ) |
De-initializes the FMC NAND Banks registers to their default reset values.
- Parameters:
-
FMC_Bank,: specifies the FMC Bank to be used This parameter can be one of the following values: - FMC_Bank2_NAND: FMC Bank2 NAND
- FMC_Bank3_NAND: FMC Bank3 NAND
- Return values:
-
None
Definition at line 351 of file stm32f30x_fmc.c.
| void FMC_NANDECCCmd | ( | uint32_t | FMC_Bank, |
| FunctionalState | NewState | ||
| ) |
Enables or disables the FMC NAND ECC feature.
- Parameters:
-
FMC_Bank,: specifies the FMC Bank to be used This parameter can be one of the following values: - FMC_Bank2_NAND: FMC Bank2 NAND
- FMC_Bank3_NAND: FMC Bank3 NAND
NewState,: new state of the FMC NAND ECC feature. This parameter can be: ENABLE or DISABLE.
- Return values:
-
None
Definition at line 516 of file stm32f30x_fmc.c.
| void FMC_NANDInit | ( | FMC_NANDInitTypeDef * | FMC_NANDInitStruct ) |
Initializes the FMC NAND Banks according to the specified parameters in the FMC_NANDInitStruct.
- Parameters:
-
FMC_NANDInitStruct : pointer to a FMC_NANDInitTypeDef structure that contains the configuration information for the FMC NAND specified Banks.
- Return values:
-
None
Definition at line 382 of file stm32f30x_fmc.c.
| void FMC_NANDStructInit | ( | FMC_NANDInitTypeDef * | FMC_NANDInitStruct ) |
Fills each FMC_NANDInitStruct member with its default value.
- Parameters:
-
FMC_NANDInitStruct,: pointer to a FMC_NANDInitTypeDef structure which will be initialized.
- Return values:
-
None
Definition at line 447 of file stm32f30x_fmc.c.
Generated on Tue Jul 12 2022 17:34:45 by
1.7.2