| LPCOpen Platform v1.03 LPCOpen Platform for NXP LPC Microcontrollers

- Main Page
- Modules
- Data Structures
- Files
- Related Pages

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
CHIP: LPC18xx/43xx EMC Driver
LPC18xx/43xx chip specific drivers

## Detailed Description

The EMC interface clocks must be enabled outside this driver prior to calling any function of this driver with the Chip_Clock_EnableOpts(CLK_MX_EMC_DIV) and Chip_Clock_Enable(CLK_MX_EMC) functions.

## Macros
#define | EMC_ADDRESS_DYCS0 (0x28000000)
#define | EMC_ADDRESS_DYCS1 (0x30000000)
#define | EMC_ADDRESS_DYCS2 (0x60000000)
#define | EMC_ADDRESS_DYCS3 (0x70000000)
#define | EMC_ADDRESS_CS0 (0x1C000000)
#define | EMC_ADDRESS_CS1 (0x1D000000)
#define | EMC_ADDRESS_CS2 (0x1E000000)
#define | EMC_ADDRESS_CS3 (0x1F000000)

## Functions
void | Chip_EMC_Dynamic_Init (IP_EMC_DYN_CONFIG_T *Dynamic_Config)
| Dyanmic memory setup.
void | Chip_EMC_Static_Init (IP_EMC_STATIC_CONFIG_T *Static_Config)
| Static memory setup.
STATIC INLINE void | Chip_EMC_Dynamic_Enable (uint8_t Enable)
| Enable Dynamic Memory Controller.
STATIC INLINE void | Chip_EMC_Mirror (uint8_t Enable)
| Mirror CS1 to CS0 and DYCS0.
STATIC INLINE void | Chip_EMC_Enable (uint8_t Enable)
| Enable EMC.
STATIC INLINE void | Chip_EMC_LowPowerMode (uint8_t Enable)
| Set EMC LowPower Mode.
STATIC INLINE void | Chip_EMC_Init (uint32_t Enable, uint32_t EndianMode)
| Initialize EMC.
STATIC INLINE void | Chip_EMC_SetStaticExtendedWait (uint32_t Wait16Clks)
| Set Static Memory Extended Wait in Clock.

## Macro Definition Documentation

#define EMC_ADDRESS_CS0 (0x1C000000)

Static Chip Select Address

Definition at line 59 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_CS1 (0x1D000000)

Definition at line 60 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_CS2 (0x1E000000)

Definition at line 61 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_CS3 (0x1F000000)

Definition at line 62 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_DYCS0 (0x28000000)

Dynamic Chip Select Address

Definition at line 51 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_DYCS1 (0x30000000)

Definition at line 52 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_DYCS2 (0x60000000)

Definition at line 53 of file emc_18xx_43xx.h.

#define EMC_ADDRESS_DYCS3 (0x70000000)

Definition at line 54 of file emc_18xx_43xx.h.

## Function Documentation

STATIC INLINE void Chip_EMC_Dynamic_Enable | ( | uint8_t | Enable | ) |

Enable Dynamic Memory Controller.

Parameters

  Enable | : 1 = Enable Dynamic Memory Controller, 0 = Disable

Returns
  None

Definition at line 83 of file emc_18xx_43xx.h.

void Chip_EMC_Dynamic_Init | ( | IP_EMC_DYN_CONFIG_T * | Dynamic_Config | ) |

Dyanmic memory setup.

Parameters

  Dynamic_Config | : Pointer to dynamic memory setup data

Returns
  None

Definition at line 53 of file emc_17xx_40xx.c.

STATIC INLINE void Chip_EMC_Enable | ( | uint8_t | Enable | ) |

Enable EMC.

Parameters

  Enable | : 1 = Enable, 0 = Disable

Returns
  None

Definition at line 103 of file emc_18xx_43xx.h.

STATIC INLINE void Chip_EMC_Init | ( | uint32_t | Enable,
|  | uint32_t | EndianMode
| ) |  |

Initialize EMC.

Parameters

  Enable | : 1 = Enable, 0 = Disable
  EndianMode | : Endian Mode, 0 = Little, 1 = Big

Returns
  None

Definition at line 126 of file emc_18xx_43xx.h.

STATIC INLINE void Chip_EMC_LowPowerMode | ( | uint8_t | Enable | ) |

Set EMC LowPower Mode.

Parameters

  Enable | : 1 = Enable, 0 = Disable

Returns
  None

Note
  This function should only be called when the memory controller is not busy (bit 0 of the status register is not set).

Definition at line 115 of file emc_18xx_43xx.h.

STATIC INLINE void Chip_EMC_Mirror | ( | uint8_t | Enable | ) |

Mirror CS1 to CS0 and DYCS0.

Parameters

  Enable | : 1 = Mirror, 0 = Normal Memory Map

Returns
  None

Definition at line 93 of file emc_18xx_43xx.h.

STATIC INLINE void Chip_EMC_SetStaticExtendedWait | ( | uint32_t | Wait16Clks | ) |

Set Static Memory Extended Wait in Clock.

Parameters

  Wait16Clks | : Number of '16 clock' delay cycles

Returns
  None

Definition at line 136 of file emc_18xx_43xx.h.

void Chip_EMC_Static_Init | ( | IP_EMC_STATIC_CONFIG_T * | Static_Config | ) |

Static memory setup.

Parameters

  Static_Config | : Pointer to static memory setup data

Returns
  None

Definition at line 64 of file emc_17xx_40xx.c.