# EMIF4F Functions
[EMIF4F]

## Functions

CSL_IDEF_INLINE void | CSL_EMIF4F_GetModuleInfo (Uint8 *moduleID, Uint8 *rtlInfo, Uint8 *majRev, Uint8 *minRev)
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsBigEndian ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsAsynchronous ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsFastInit ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsReadDQSGateTrainingTimeout ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsReadDataEyeTrainingTimeout ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsWriteLevelingTimeout ()
CSL_IDEF_INLINE Bool | CSL_EMIF4F_IsDDRPhyRead ()
CSL_IDEF_INLINE void | CSL_EMIF4F_GetSDRAMConfig (EMIF4F_SDRAM_CONFIG *ptrConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetSDRAMConfig (EMIF4F_SDRAM_CONFIG *ptrConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_DisableInitRefresh (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_EnableInitRefresh (void)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetSelfRefreshTemp (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetSelfRefreshTemp (Uint8 temperature)
CSL_IDEF_INLINE void | CSL_EMIF4F_EnableAutoRefresh (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_DisableAutoRefresh (void)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetPartialArraySelfRefresh (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPartialArraySelfRefresh (Uint8 pasr)
CSL_IDEF_INLINE Uint16 | CSL_EMIF4F_GetRefreshRate (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetRefreshRate (Uint16 refreshRate)
CSL_IDEF_INLINE Uint16 | CSL_EMIF4F_GetShadowRefreshRate (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowRefreshRate (Uint16 refreshRate)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetTiming1Config (EMIF4F_TIMING1_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetTiming1Config (EMIF4F_TIMING1_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowTiming1Config (EMIF4F_TIMING1_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowTiming1Config (EMIF4F_TIMING1_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetTiming2Config (EMIF4F_TIMING2_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetTiming2Config (EMIF4F_TIMING2_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowTiming2Config (EMIF4F_TIMING2_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowTiming2Config (EMIF4F_TIMING2_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetTiming3Config (EMIF4F_TIMING3_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetTiming3Config (EMIF4F_TIMING3_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowTiming3Config (EMIF4F_TIMING3_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowTiming3Config (EMIF4F_TIMING3_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetLPDDR2NVMTimingConfig (EMIF4F_LPDDR2NVM_TIMING_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLPDDR2NVMTimingConfig (EMIF4F_LPDDR2NVM_TIMING_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowLPDDR2NVMTimingConfig (EMIF4F_LPDDR2NVM_TIMING_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowLPDDR2NVMTimingConfig (EMIF4F_LPDDR2NVM_TIMING_CONFIG *ptrTimingConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPowerMgmtConfig (EMIF4F_PWR_MGMT_CONFIG *ptrPwrMgmtConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPowerMgmtConfig (EMIF4F_PWR_MGMT_CONFIG *ptrPwrMgmtConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowPowerMgmtConfig (EMIF4F_PWR_MGMT_CONFIG *ptrPwrMgmtConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowPowerMgmtConfig (EMIF4F_PWR_MGMT_CONFIG *ptrPwrMgmtConfig)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetLPDDR2Mode (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLPDDR2Mode (Uint8 mode)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetLPDDR2ConfigCS (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLPDDR2ConfigCS (Uint8 chipSelect)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetLPDDR2ConfigRefreshEnable (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLPDDR2ConfigRefreshEnable (Uint8 refreshEnable)
CSL_IDEF_INLINE Uint8 | CSL_EMIF4F_GetLPDDR2ConfigModeRegAddress (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLPDDR2ConfigModeRegAddress (Uint8 modeRegAddr)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetVBUSConfig (Uint8 *cosCount1, Uint8 *cosCount2, Uint8 *prOldCount)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetVBUSConfig (Uint8 cosCount1, Uint8 cosCount2, Uint8 prOldCount)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetVBUSConfigValues (EMIF4F_VBUS_CONFIG_VALUE *ptrVBUSConfigValue)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIODFTControl (EMIF4F_IODFT_CONTROL *ptrIODFTControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetIODFTControl (EMIF4F_IODFT_CONTROL *ptrIODFTControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIODFTControlResults (Uint16 *dqmTLMRResults, Uint16 *ctlTLMRResults)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIODFTAddrResults (Uint32 *addrTLMRResults)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIODFTDataResults (Uint32 *dataTLMRResults1, Uint32 *dataTLMRResults2, Uint32 *dataTLMRResults3, Uint32 *dataTLMRResults4, Uint32 *dataTLMRResults5)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPerfCounters (Uint32 *perfCounter1, Uint32 *perfCounter2)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPerfCounterConfig (Uint8 counter, EMIF4F_PERF_CONFIG *ptrPerfCounterConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPerfCounterConfig (Uint8 counter, EMIF4F_PERF_CONFIG *ptrPerfCounterConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPerfCounterMasterRegion (Uint8 counter, Uint8 *mstID, Uint8 *regionSel)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPerfCounterMasterRegion (Uint8 counter, Uint8 mstID, Uint8 regionSel)
CSL_IDEF_INLINE Uint32 | CSL_EMIF4F_GetPerfCounterTime (void)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIdleControl (Uint8 *idleLen, Uint16 *idleInterval)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetIdleControl (Uint8 idleLen, Uint16 idleInterval)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetIdleControlShadow (Uint8 *idleLen, Uint16 *idleInterval)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetIdleControlShadow (Uint8 idleLen, Uint16 idleInterval)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetInterruptRawStatus (Uint8 *rawStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetInterruptRawStatus (Uint8 rawStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetInterruptStatus (Uint8 *intrStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_ClearInterruptStatus (Uint8 intrStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_EnableInterrupts (Uint8 intrStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_DisableInterrupts (Uint8 intrStatus)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetOutputImpedanceConfig (EMIF4F_OUTPUT_IMP_CONFIG *ptrOutputImpedanceConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetOutputImpedanceConfig (EMIF4F_OUTPUT_IMP_CONFIG *ptrOutputImpedanceConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetTempAlertConfig (EMIF4F_TEMP_ALERT_CONFIG *ptrTempAlertConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetTempAlertConfig (EMIF4F_TEMP_ALERT_CONFIG *ptrTempAlertConfig)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetErrorLog (Uint8 *errCRSel, Uint8 *errAddMode, Uint8 *errCmdType, Uint8 *errMstID)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetLevelingRampWindow (Uint16 *lvlRampWindow)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLevelingRampWindow (Uint16 lvlRampWindow)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetLevelingRampControlInfo (Bool *enable, Uint8 *preScalar, Uint8 *readDataEye, Uint8 *readDQS, Uint8 *writeInt)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLevelingRampControlInfo (Bool enable, Uint8 preScalar, Uint8 readDataEye, Uint8 readDQS, Uint8 writeInt)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetLevelingControlInfo (Uint8 *trigger, Uint8 *preScalar, Uint8 *readDataEye, Uint8 *readDQS, Uint8 *writeInt)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetLevelingControlInfo (Uint8 trigger, Uint8 preScalar, Uint8 readDataEye, Uint8 readDQS, Uint8 writeInt)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPhyControl (Uint32 *ddrPHYControl, Uint8 *ddrPHYReadLatency)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPhyControl (Uint32 ddrPHYControl, Uint8 ddrPHYReadLatency)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetShadowPhyControl (Uint32 *ddrPHYControl, Uint8 *ddrPHYReadLatency)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetShadowPhyControl (Uint32 ddrPHYControl, Uint8 ddrPHYReadLatency)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPhyControl2 (Uint32 *ddrPHYControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPhyControl2 (Uint32 ddrPHYControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetPriorityToCOSMapping (EMIF4_PRI_COS_MAPPING *ptrPriCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetPriorityToCOSMapping (EMIF4_PRI_COS_MAPPING *ptrPriCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetMstIDToCos1Mapping (EMIF4_MSTID_COS_MAPPING *ptrMstIDCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetMstIDToCos1Mapping (EMIF4_MSTID_COS_MAPPING *ptrMstIDCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetMstIDToCos2Mapping (EMIF4_MSTID_COS_MAPPING *ptrMstIDCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetMstIDToCos2Mapping (EMIF4_MSTID_COS_MAPPING *ptrMstIDCosMapper)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetECCControl (EMIF4_ECC_CONTROL *ptrECCControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetECCControl (EMIF4_ECC_CONTROL *ptrECCControl)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetECCAddressRange (Uint8 range, Uint16 *endAddr, Uint16 *startAddr)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetECCAddressRange (Uint8 range, Uint16 endAddr, Uint16 startAddr)
CSL_IDEF_INLINE void | CSL_EMIF4F_GetReadWriteThreshold (Uint8 *wrThreshold, Uint8 *rdThreshold)
CSL_IDEF_INLINE void | CSL_EMIF4F_SetReadWriteThreshold (Uint8 wrThreshold, Uint8 rdThreshold)

## Function Documentation

CSL_IDEF_INLINE void CSL_EMIF4F_ClearInterruptStatus | ( | Uint8 | intrStatus | ) |

============================================================================
CSL_EMIF4F_ClearInterruptStatus

Description
The function is used to clear the interrupt status

Arguments

            intrStatus       Interrupt Status populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_IRQSTATUS_SYS

Example

            Uint8   intrStatus;

            // Get the Interrupt Status
            CSL_EMIF4F_GetInterruptRawStatus (&intrStatus);
            ...
            // Process the interrupts
            ...
            // Clear the Interrupts
            CSL_EMIF4F_ClearInterruptStatus (intrStatus);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_DisableAutoRefresh | ( | void |  | ) |

============================================================================
CSL_EMIF4F_DisableAutoRefresh

Description
The function is used to disable auto self refresh.

Arguments

             None

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_ASR=0

Example

            // Disable Auto Self Refresh
            CSL_EMIF4F_DisableAutoRefresh();

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_DisableInitRefresh | ( | void |  | ) |

============================================================================
CSL_EMIF4F_DisableInitRefresh

Description
The function is used to disable the initialization and refresh.

Arguments

             None

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_INITREF_DIS=1

Example

            // Disable Initialization & Refresh
            CSL_EMIF4F_DisableInitRefresh();

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_DisableInterrupts | ( | Uint8 | intrStatus | ) |

============================================================================
CSL_EMIF4F_DisableInterrupts

Description
The function is used to disable interrupts

Arguments

            intrFlag       Interrupt flag for interrupts to be disabled

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_IRQENABLE_CLR_SYS

Example

            // Disable address error interrupt
            CSL_EMIF4F_DisableInterrupts (0x1);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_EnableAutoRefresh | ( | void |  | ) |

============================================================================
CSL_EMIF4F_EnableAutoRefresh

Description
The function is used to enable auto self refresh.

Arguments

             None

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_ASR=1

Example

            // Enable Auto Self Refresh
            CSL_EMIF4F_EnableAutoRefresh();

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_EnableInitRefresh | ( | void |  | ) |

============================================================================
CSL_EMIF4F_EnableInitRefresh

Description
The function is used to enable the initialization and refresh.

Arguments

             None

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_INITREF_DIS=0

Example

            // Enable Initialization & Refresh
            CSL_EMIF4F_EnableInitRefresh();

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_EnableInterrupts | ( | Uint8 | intrStatus | ) |

============================================================================
CSL_EMIF4F_EnableInterrupts

Description
The function is used to enable interrupts

Arguments

            intrFlag       Interrupt flag for interrupts to be enabled

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_IRQENABLE_SET_SYS

Example

            // Enable address error interrupt
            CSL_EMIF4F_EnableInterrupts (0x1);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetECCAddressRange | ( | Uint8 | range,
|  | Uint16 * | endAddr,
|  | Uint16 * | startAddr |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetECCAddressRange

Description
The function is used to get the ECC Address Range

Arguments

            range           Address Range for which start and end address are required
            endAddr         End Address
            startAddr       Start Address

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_ECC_ADDR_RNG_1_REG_ECC_END_ADDR_1, EMIF4F_ECC_ADDR_RNG_1_REG_ECC_STRT_ADDR_1; EMIF4F_ECC_ADDR_RNG_2_REG_ECC_END_ADDR_2, EMIF4F_ECC_ADDR_RNG_2_REG_ECC_STRT_ADDR_2

Example

            Uint16  endAddr;
            Uint16  startAddr;

            // Get the ECC Address Range1
            CSL_EMIF4F_GetECCAddressRange (1, &endAddr, &startAddr);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetECCControl | ( | EMIF4_ECC_CONTROL * | ptrECCControl | ) |

============================================================================
CSL_EMIF4F_GetECCControl

Description
The function is used to get the ECC Control Information

Arguments

            ptrECCControl       ECC Control Configuration

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_ECC_CTRL_REG_ECC_EN, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_PROT, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_2_EN, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_1_EN

Example

            EMIF4_ECC_CONTROL eccControl;

            // Get the ECC Control Configuration
            CSL_EMIF4F_GetECCControl (&eccControl);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetErrorLog | ( | Uint8 * | errCRSel,
|  | Uint8 * | errAddMode,
|  | Uint8 * | errCmdType,
|  | Uint8 * | errMstID |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetErrorLog

Description
The function is used to get the error log

Arguments

            errCRSel    CRSel for the first errored transaction populated by this API
            errAddMode  Addressing Mode populated by this API
            errCmdType  Command Type of the first errored transaction populated by this API
            errMstID    Master ID of the first errored transaction populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_VBUSM_ERR_LOG_REG_CRSEL,EMIF4F_VBUSM_ERR_LOG_REG_CAMODE, EMIF4F_VBUSM_ERR_LOG_REG_CDIR, EMIF4F_VBUSM_ERR_LOG_REG_CMSTID

Example

            Uint8  errCRSel;
            Uint8  errAddMode;
            Uint8  errCmdType;
            Uint8  errMstID;

            // Get the Error Log
            CSL_EMIF4F_GetErrorLog (&errCRSel, &errAddMode, &errCmdType, &errMstID);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIdleControl | ( | Uint8 * | idleLen,
|  | Uint16 * | idleInterval |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetIdleControl

Description
The function is used to get the idle control information

Arguments

            idleLen         Idle Length populated by this API
            idleInterval    Idle Interval populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_READ_IDLE_CTRL_REG_READ_IDLE_LEN, EMIF4F_READ_IDLE_CTRL_REG_READ_IDLE_INTERVAL

Example

            Uint8   idleLen;
            Uint16  idleInterval;

            // Get the Idle Control Configuration
            CSL_EMIF4F_GetIdleControl (&idleLen, &idleInterval);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIdleControlShadow | ( | Uint8 * | idleLen,
|  | Uint16 * | idleInterval |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetIdleControlShadow

Description
The function is used to get the idle control information from the Shadow register.

Arguments

            idleLen         Idle Length populated by this API
            idleInterval    Idle Interval populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_READ_IDLE_CTRL_SHDW_REG_READ_IDLE_LEN_SHDW, EMIF4F_READ_IDLE_CTRL_SHDW_REG_READ_IDLE_INTERVAL_SHDW

Example

            // Get the Idle Control Configuration from the Shadow  register
            CSL_EMIF4F_GetIdleControlShadow (&idleLen, &idleInterval);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetInterruptRawStatus | ( | Uint8 * | rawStatus | ) |

============================================================================
CSL_EMIF4F_GetInterruptRawStatus

Description
The function is used to get the interrupt RAW status

Arguments

            rawStatus       Raw Interrupt Status populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_IRQSTATUS_RAW_SYS

Example

            Uint8   rawStatus;

            // Get the Interrupt RAW Status
            CSL_EMIF4F_GetInterruptRawStatus (&rawStatus);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetInterruptStatus | ( | Uint8 * | intrStatus | ) |

============================================================================
CSL_EMIF4F_GetInterruptStatus

Description
The function is used to get the interrupt status

Arguments

            intrStatus       Interrupt Status populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_IRQSTATUS_SYS

Example

            Uint8   intrStatus;

            // Get the Interrupt Status
            CSL_EMIF4F_GetInterruptStatus (&intrStatus);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIODFTAddrResults | ( | Uint32 * | addrTLMRResults | ) |

============================================================================
CSL_EMIF4F_GetIODFTAddrResults

Description
The function is used to get the IODFT Address results.

Arguments

            addrTLMRResults      Addr TLMR Results populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_IODFT_ADDR_MISR_RSLT_REG_ADDR_TLMR

Example

            Uint32     addrTLMRResults;

            // Get the IODFT Address results
            CSL_EMIF4F_GetIODFTAddrResults(&addrTLMRResults);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIODFTControl | ( | EMIF4F_IODFT_CONTROL * | ptrIODFTControl | ) |

============================================================================
CSL_EMIF4F_GetIODFTControl

Description
The function is used to get the IODFT Control configuration

Arguments

            ptrIODFTControl      IODFT Control Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_IODFT_TLGC_REG_TLEC, EMIF4F_IODFT_TLGC_REG_MT, EMIF4F_IODFT_TLGC_REG_ACT_CAP_EN,EMIF4F_IODFT_TLGC_REG_OPG_LD, EMIF4F_IODFT_TLGC_REG_MMS, EMIF4F_IODFT_TLGC_REG_MC, EMIF4F_IODFT_TLGC_REG_PC, EMIF4F_IODFT_TLGC_REG_TM

Example

            EMIF4F_IODFT_CONTROL     IODFTcontrol;

            // Get the IODFT Configuration values
            CSL_EMIF4F_GetIODFTControl(&IODFTcontrol);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIODFTControlResults | ( | Uint16 * | dqmTLMRResults,
|  | Uint16 * | ctlTLMRResults |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetIODFTControlResults

Description
The function is used to get the IODFT Control results.

Arguments

            dqmTLMRResults      DQM TLMR Results populated by this API
            ctlTLMRResults      CTL TLMR Results populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_IODFT_CTRL_MISR_RSLT_REG_DQM_TLMR, EMIF4F_IODFT_CTRL_MISR_RSLT_REG_CTL_TLMR

Example

            Uint16     dqmTLMRResults;
            Uint16     ctlTLMRResults;

            // Get the IODFT Control Results
            CSL_EMIF4F_GetIODFTControlResults(&dqmTLMRResults, &ctlTLMRResults);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetIODFTDataResults | ( | Uint32 * | dataTLMRResults1,
|  | Uint32 * | dataTLMRResults2,
|  | Uint32 * | dataTLMRResults3,
|  | Uint32 * | dataTLMRResults4,
|  | Uint32 * | dataTLMRResults5 |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetIODFTDataResults

Description
The function is used to get the IODFT Data results.

Arguments

            dataTLMRResults1      Data TLMR1 Results populated by this API
            dataTLMRResults2      Data TLMR2 Results populated by this API
            dataTLMRResults3      Data TLMR3 Results populated by this API
            dataTLMRResults4      Data TLMR4 Results populated by this API
            dataTLMRResults5      Data TLMR5 Results populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_IODFT_DATA_MISR_RSLT_1,EMIF4F_IODFT_DATA_MISR_RSLT_2, EMIF4F_IODFT_DATA_MISR_RSLT_3,EMIF4F_IODFT_DATA_MISR_RSLT_4, EMIF4F_IODFT_DATA_MISR_RSLT_5

Example

            Uint32     dataTLMRResults1;
            Uint32     dataTLMRResults2;
            Uint32     dataTLMRResults3;
            Uint32     dataTLMRResults4;
            Uint32     dataTLMRResults5;

            // Get the IODFT Data results
            CSL_EMIF4F_GetIODFTDataResults(&dataTLMRResults1, &dataTLMRResults2,
                                          &dataTLMRResults3, &dataTLMRResults4,
                                          &dataTLMRResults5);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetLevelingControlInfo | ( | Uint8 * | trigger,
|  | Uint8 * | preScalar,
|  | Uint8 * | readDataEye,
|  | Uint8 * | readDQS,
|  | Uint8 * | writeInt |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetLevelingControlInfo

Description
The function is used to get the incremental leveling control information

Arguments

            trigger     - Full leveling trigger
            preScalar   - Incremental leveling pre-scalar in number of refresh periods
            readDataEye - Incremental read data eye training interval
            readDQS     - Incremental read DQS gate training interval
            writeInt    - Incremental write leveling interval

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_RDWR_LVL_CTRL_REG_RDWRLVLFULL_START, EMIF4F_RDWR_LVL_CTRL_REG_RDWRLVLINC_PRE, EMIF4F_RDWR_LVL_CTRL_REG_RDLVLINC_INT, EMIF4F_RDWR_LVL_CTRL_REG_RDLVLGATEINC_INT, EMIF4F_RDWR_LVL_CTRL_REG_WRLVLINC_INT

Example

            Uint8  trigger;
            Uint8  preScalar;
            Uint8  readDataEye;
            Uint8  readDQS;
            Uint8  writeInt;

            // Get the Leveling Control Information
            CSL_EMIF4F_GetLevelingControlInfo (&trigger, &preScalar, &readDataEye, &readDQS, &writeInt);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetLevelingRampControlInfo | ( | Bool * | enable,
|  | Uint8 * | preScalar,
|  | Uint8 * | readDataEye,
|  | Uint8 * | readDQS,
|  | Uint8 * | writeInt |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetLevelingRampControlInfo

Description
The function is used to get the incremental leveling ramp control information

Arguments

            preScalar   - Incremental leveling pre-scalar in number of refresh periods
            readDataEye - Incremental read data eye training interval during ramp window
            readDQS     - Incremental read DQS gate training interval during ramp window
            writeInt    - Incremental write leveling interval during ramp window

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDWRLVL_EN, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDWRLVLINC_RMP_PRE, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDLVLINC_RMP_INT, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDLVLGATEINC_RMP_INT, EMIF4F_RDWR_LVL_RMP_CTRL_REG_WRLVLINC_RMP_INT

Example

            Uint8  preScalar;
            Uint8  readDataEye;
            Uint8  readDQS;
            Uint8  writeInt;
            Bool   enable;

            // Get the Leveling Ramp Control Information
            CSL_EMIF4F_GetLevelingRampControlInfo (&enable, &preScalar, &readDataEye, &readDQS, &writeInt);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetLevelingRampWindow | ( | Uint16 * | lvlRampWindow | ) |

============================================================================
CSL_EMIF4F_GetLevelingRampWindow

Description
The function is used to get the incremental leveling ramp window.

Arguments

            lvlRampWindow   - Incremental leveling ramp window in number of
                              refresh periods

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_RDWR_LVL_RMP_WIN_REG_RDWRLVLINC_RMP_WIN

Example

            Uint16  lvlRampWindow;

            // Get the Leveling Ramp Window
            CSL_EMIF4F_GetLevelingRampWindow (&lvlRampWindow);

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetLPDDR2ConfigCS | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetLPDDR2ConfigCS

Description
The function is used to get the LPDDR2 Configuration Chip Select

Arguments

             None

Return Value
LPDDR2 Configuration Chip Select

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_MODE_REG_CFG_REG_CS

Example

            Uint8 cs;

            // Get the LPDDR2 Chip Select
            cs = CSL_EMIF4F_GetLPDDR2ConfigCS();
            ...

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetLPDDR2ConfigModeRegAddress | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetLPDDR2ConfigModeRegAddress

Description
The function is used to get the LPDDR2 Configuration Mode Register Address

Arguments

             None

Return Value
LPDDR2 Configuration Mode Register Address

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_MODE_REG_CFG_REG_ADDRESS

Example

            Uint8 modeRegAddress;

            // Get the LPDDR2 Config Mode Register Address
            modeRegAddress = CSL_EMIF4F_GetLPDDR2ConfigModeRegAddress();
            ...

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetLPDDR2ConfigRefreshEnable | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetLPDDR2ConfigRefreshEnable

Description
The function is used to get the LPDDR2 Configuration Refresh Enable

Arguments

             None

Return Value
LPDDR2 Configuration Refresh Enable

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_MODE_REG_CFG_REG_REFRESH_EN

Example

            Uint8 refreshEnable;

            // Get the LPDDR2 Config Refresh Enable
            refreshEnable = CSL_EMIF4F_GetLPDDR2ConfigRefreshEnable();
            ...

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetLPDDR2Mode | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetLPDDR2Mode

Description
The function is used to get the LPDDR2 Mode

Arguments

             None

Return Value
LPDDR2 Mode

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_MODE_REG_DATA_REG_VALUE_0

Example

            Uint8 mode;

            // Get the LPDDR2 Mode
            mode = CSL_EMIF4F_GetLPDDR2Mode();
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetLPDDR2NVMTimingConfig | ( | EMIF4F_LPDDR2NVM_TIMING_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetLPDDR2NVMTimingConfig

Description
The function is used to get the LPDDR2 NVM Timing Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_XP, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_WTR, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RP, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_WRA, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RRD, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RCDMIN

Example

            EMIF4F_LPDDR2NVM_TIMING_CONFIG timingConfig;

            // Get the current LPDDR2 NVM configuration.
            CSL_EMIF4F_GetLPDDR2NVMTimingConfig(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetModuleInfo | ( | Uint8 * | moduleID,
|  | Uint8 * | rtlInfo,
|  | Uint8 * | majRev,
|  | Uint8 * | minRev |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetModuleInfo

Description
This function reads the peripheral ID register which identifies the module id, RTL version information etc.

Arguments

              moduleID     Module Id Information populated by this API
              rtlInfo      RTL Version Information populated by this API
              majRev       Major Revision Information populated by this API
              minRev       Minor Revision Information populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_EMIF_MOD_ID_REV_REG_MODULE_ID,EMIF4F_EMIF_MOD_ID_REV_REG_RTL_VERSION, EMIF4F_EMIF_MOD_ID_REV_REG_MAJOR_REVISION,EMIF4F_EMIF_MOD_ID_REV_REG_MINOR_REVISION

Example

            Uint8   moduleID;
            Uint8   rtlInfo;
            Uint8   majRev;
            Uint8   minRev;

            // Get the EMIF4F Module Information.
            CSL_EMIF4F_GetModuleInfo (&moduleID, &rtlInfo, &majRev, &minRev);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetMstIDToCos1Mapping | ( | EMIF4_MSTID_COS_MAPPING * | ptrMstIDCosMapper | ) |

============================================================================
CSL_EMIF4F_GetMstIDToCos1Mapping

Description
The function is used to get the master id to Class of Service 1 mapping

Arguments

            ptrMstIDCosMapper       Master ID to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_MSTID_COS_1_MAP_REG_MSTID_COS_1_MAP_EN, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_1_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_1_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_2_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_2_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_3_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_3_COS_1

Example

            EMIF4_MSTID_COS_MAPPING mstIDCosMapper;

            // Get the Master ID to COS1 Mapper information
            CSL_EMIF4F_GetMstIDToCos1Mapping (&mstIDCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetMstIDToCos2Mapping | ( | EMIF4_MSTID_COS_MAPPING * | ptrMstIDCosMapper | ) |

============================================================================
CSL_EMIF4F_GetMstIDToCos2Mapping

Description
The function is used to get the master id to Class of Service 2 mapping

Arguments

            ptrMstIDCosMapper       Master ID to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_MSTID_COS_2_MAP_REG_MSTID_COS_2_MAP_EN, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_1_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_1_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_2_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_2_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_3_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_3_COS_2

Example

            EMIF4_MSTID_COS_MAPPING mstIDCosMapper;

            // Get the Master ID to COS2 Mapper information
            CSL_EMIF4F_GetMstIDToCos2Mapping (&mstIDCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetOutputImpedanceConfig | ( | EMIF4F_OUTPUT_IMP_CONFIG * | ptrOutputImpedanceConfig | ) |

============================================================================
CSL_EMIF4F_GetOutputImpedanceConfig

Description
The function is used to get the Output Impedance Calibrartion configuration

Arguments

            ptrOutputImpedanceConfig    Output Impedance Calibrartion configuration
                                        populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_ZQ_CONFIG_REG_ZQ_CS1EN, EMIF4F_ZQ_CONFIG_REG_ZQ_CS0EN, EMIF4F_ZQ_CONFIG_REG_ZQ_DUALCALEN, EMIF4F_ZQ_CONFIG_REG_ZQ_SFEXITEN, EMIF4F_ZQ_CONFIG_REG_ZQ_ZQINIT_MULT,EMIF4F_ZQ_CONFIG_REG_ZQ_ZQCL_MULT, EMIF4F_ZQ_CONFIG_REG_ZQ_REFINTERVAL

Example

            EMIF4F_OUTPUT_IMP_CONFIG outputImpConfig;

            // Get the output impedance configuration
            CSL_EMIF4F_GetOutputImpedanceConfig (&outputImpConfig);

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetPartialArraySelfRefresh | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetPartialArraySelfRefresh

Description
The function is used to get the partial array self refresh.

Arguments

             None

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_REF_CTRL_REG_PASR

Example

            Uint8 pasr;

            // Get the Partial Array Refresh Rate Configuration
            pasr = CSL_EMIF4F_GetPartialArraySelfRefresh();
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPerfCounterConfig | ( | Uint8 | counter,
|  | EMIF4F_PERF_CONFIG * | ptrPerfCounterConfig |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetPerfCounterConfig

Description
The function is used to get the configuration for performance counters

Arguments

            counter                 Perf Counter for which configuration is required (1 or 2)
            ptrPerfCounterConfig    Performance Counter Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PERF_CNT_CFG_REG_CNTR2_MSTID_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR2_REGION_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR2_CFG; EMIF4F_PERF_CNT_CFG_REG_CNTR1_MSTID_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR1_REGION_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR1_CFG

Example

            EMIF4F_PERF_CONFIG     perfCounterConfig;

            // Get the EMIF4F Performance Counter Configuration for counter 1
            CSL_EMIF4F_GetPerfCounterConfig(1, &perfCounterConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPerfCounterMasterRegion | ( | Uint8 | counter,
|  | Uint8 * | mstID,
|  | Uint8 * | regionSel |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetPerfCounterMasterRegion

Description
The function is used to get the master region selection for the specific performance counters

Arguments

            counter          Perf Counter for which master region selection is configured
            mstID            Master ID selection for the specified performance counter
            regionSel        Region Selection for the specified performance counter

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PERF_CNT_SEL_REG_MCONNID1, EMIF4F_PERF_CNT_SEL_REG_REGION_SEL1; EMIF4F_PERF_CNT_SEL_REG_MCONNID2, EMIF4F_PERF_CNT_SEL_REG_REGION_SEL2

Example

            Uint8   mstID;
            Uint8   regionSel;

            // Get the Master Region Selection for Counter 1
            CSL_EMIF4F_GetPerfCounterMasterRegion (1, &mstID, &regionSel);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPerfCounters | ( | Uint32 * | perfCounter1,
|  | Uint32 * | perfCounter2 |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetPerfCounters

Description
The function is used to get the performance counters

Arguments

            perfCounter1        Performance Counter1 populated by this API
            perfCounter2        Performance Counter2 populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PERF_CNT_1,EMIF4F_PERF_CNT_2

Example

            Uint32     perfCounter1;
            Uint32     perfCounter2;

            // Get the EMIF4F Performance counters
            CSL_EMIF4F_GetPerfCounters(&perfCounter1, &perfCounter2);
            ...

=============================================================================

CSL_IDEF_INLINE Uint32 CSL_EMIF4F_GetPerfCounterTime | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetPerfCounterTime

Description
The function is used to get the performance counter timer register

Arguments

            None

Return Value
Performance counter Time Register

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PERF_CNT_TIM

Example

            Uint32  perfCount;

            // Get the Performance Counter Time Register
            perfCount = CSL_EMIF4F_GetPerfCounterTime ();
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPhyControl | ( | Uint32 * | ddrPHYControl,
|  | Uint8 * | ddrPHYReadLatency |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetPhyControl

Description
The function is used to get the DDR PHY Control

Arguments

            ddrPHYControl       DDR PHY Control specific info populated by this API
            ddrPHYReadLatency   DDR PHY Read Latency populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_DDR_PHY_CTRL_1_REG_DDR_PHY_CTRL_1, EMIF4F_DDR_PHY_CTRL_1_REG_READ_LATENCY

Example

            Uint32 ddrPHYControl;
            Uint8  ddrPHYReadLatency;

            // Get the DDR PHY Control
            CSL_EMIF4F_GetPhyControl (&ddrPHYControl, &ddrPHYReadLatency);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPhyControl2 | ( | Uint32 * | ddrPHYControl | ) |

============================================================================
CSL_EMIF4F_GetPhyControl2

Description
The function is used to read the DDR PHY Control2 register. This is PHY specific

Arguments

            ddrPHYControl       DDR PHY Control configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_DDR_PHY_CTRL_2

Example

            Uint32 ddrPHYControl;

            // Get the DDR PHY Control
            CSL_EMIF4F_GetPhyControl2 (&ddrPHYControl);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPowerMgmtConfig | ( | EMIF4F_PWR_MGMT_CONFIG * | ptrPwrMgmtConfig | ) |

============================================================================
CSL_EMIF4F_GetPowerMgmtConfig

Description
The function is used to get the Power Management Configuration.

Arguments

             ptrPwrMgmtConfig       Power Management Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PWR_MGMT_CTRL_REG_PD_TIM, EMIF4F_PWR_MGMT_CTRL_REG_DPD_EN, EMIF4F_PWR_MGMT_CTRL_REG_LP_MODE, EMIF4F_PWR_MGMT_CTRL_REG_SR_TIM, EMIF4F_PWR_MGMT_CTRL_REG_CS_TIM

Example

            EMIF4F_PWR_MGMT_CONFIG pwrConfig;

            // Get the power management configuration.
            CSL_EMIF4F_GetPowerMgmtConfig(&pwrConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetPriorityToCOSMapping | ( | EMIF4_PRI_COS_MAPPING * | ptrPriCosMapper | ) |

============================================================================
CSL_EMIF4F_GetPriorityToCOSMapping

Description
The function is used to get the priority to class of service mapping.

Arguments

            ptrPriCosMapper       Priority to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_PRI_COS_MAP_REG_PRI_COS_MAP_EN, EMIF4F_PRI_COS_MAP_REG_PRI_7_COS, EMIF4F_PRI_COS_MAP_REG_PRI_5_COS, EMIF4F_PRI_COS_MAP_REG_PRI_4_COS, EMIF4F_PRI_COS_MAP_REG_PRI_3_COS, EMIF4F_PRI_COS_MAP_REG_PRI_2_COS, EMIF4F_PRI_COS_MAP_REG_PRI_1_COS, EMIF4F_PRI_COS_MAP_REG_PRI_0_COS

Example

            EMIF4_PRI_COS_MAPPING priCosMapper;

            // Get the Priority to COS Mapper information
            CSL_EMIF4F_GetPriorityToCOSMapping (&priCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetReadWriteThreshold | ( | Uint8 * | wrThreshold,
|  | Uint8 * | rdThreshold |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetReadWriteThreshold

Description
The function is used to get the Read, Write Execution Thresholds

Arguments

            wrThreshold       Write Threshold
            rdThreshold       Read  Threshold

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_RD_WR_EXEC_THRSH_REG_WR_THRSH, EMIF4F_RD_WR_EXEC_THRSH_REG_RD_THRSH

Example

            Uint8   wrThreshold;
            Uint8   rdThreshold;

            // Get the Read, Write Execution Thresholds.
            CSL_EMIF4F_GetReadWriteThreshold (&wrThreshold, &rdThreshold);
            ...

=============================================================================

CSL_IDEF_INLINE Uint16 CSL_EMIF4F_GetRefreshRate | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetRefreshRate

Description
The function is used to get the refresh rate

Arguments

             None

Return Value
Current Refresh Rate configuration

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_REF_CTRL_REG_REFRESH_RATE

Example

            Uint8   refreshRate;

            // Get the Refresh Rate
            refreshRate = CSL_EMIF4F_GetRefreshRate();
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetSDRAMConfig | ( | EMIF4F_SDRAM_CONFIG * | ptrConfig | ) |

============================================================================
CSL_EMIF4F_GetSDRAMConfig

Description
The function gets the current SDRAM Configuration.

Arguments

             ptrConfig  SDRAM Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_CONFIG_REG_SDRAM_TYPE,EMIF4F_SDRAM_CONFIG_REG_IBANK_POS, EMIF4F_SDRAM_CONFIG_REG_DDR_TERM,EMIF4F_SDRAM_CONFIG_REG_DDR2_DDQS, EMIF4F_SDRAM_CONFIG_REG_DYN_ODT,EMIF4F_SDRAM_CONFIG_REG_DDR_DISABLE_DLL, EMIF4F_SDRAM_CONFIG_REG_SDRAM_DRIVE,EMIF4F_SDRAM_CONFIG_REG_CWL, EMIF4F_SDRAM_CONFIG_REG_NARROW_MODE,EMIF4F_SDRAM_CONFIG_REG_CL, EMIF4F_SDRAM_CONFIG_REG_ROWSIZE,EMIF4F_SDRAM_CONFIG_REG_IBANK, EMIF4F_SDRAM_CONFIG_REG_EBANK,EMIF4F_SDRAM_CONFIG_REG_PAGESIZE,
EMIF4F_SDRAM_CONFIG_2_REG_CS1NVMEN,EMIF4F_SDRAM_CONFIG_2_REG_EBANK_POS, EMIF4F_SDRAM_CONFIG_2_REG_RDBNUM,EMIF4F_SDRAM_CONFIG_2_REG_RDBSIZE

Example

            EMIF4F_SDRAM_CONFIG  sdramConfig;
            ...
            // Get the EMIF4F SDRAM Configuration.
            CSL_EMIF4F_GetSDRAMConfig (&sdramConfig);
            ...

=============================================================================

CSL_IDEF_INLINE Uint8 CSL_EMIF4F_GetSelfRefreshTemp | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetSelfRefreshTemp

Description
The function is used to get the DDR3 Self Refresh Temperature.

Arguments

             None

Return Value
0 - Normal Operating Temperature
1 - Extended Operating Temperature

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_REF_CTRL_REG_SRT

Example

            // Get the current self refresh temperature configuration.
            if (CSL_EMIF4F_GetSelfRefreshTemp() == 0)
            {
                // Normal Operating Temperature
            }
            else
            {
                // Extended Operating Temperature
            }

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowLPDDR2NVMTimingConfig | ( | EMIF4F_LPDDR2NVM_TIMING_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetShadowLPDDR2NVMTimingConfig

Description
The function is used to get the Shadow LPDDR2 NVM Timing Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_XP_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_WTR_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RP_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_WRA_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RRD_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RCDMIN_SHDW

Example

            EMIF4F_LPDDR2NVM_TIMING_CONFIG timingConfig;

            // Get the current Shadow LPDDR2 NVM configuration.
            CSL_EMIF4F_GetShadowLPDDR2NVMTimingConfig(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowPhyControl | ( | Uint32 * | ddrPHYControl,
|  | Uint8 * | ddrPHYReadLatency |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetShadowPhyControl

Description
The function is used to get the Shadow DDR PHY Control

Arguments

            ddrPHYControl       DDR PHY Control specific info populated by this API
            ddrPHYReadLatency   DDR PHY Read Latency populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_DDR_PHY_CTRL_1_SHDW_REG_DDR_PHY_CTRL_1_SHDW, EMIF4F_DDR_PHY_CTRL_1_SHDW_REG_READ_LATENCY_SHDW

Example

            Uint32 ddrPHYControl;
            Uint8  ddrPHYReadLatency;

            // Get the DDR PHY Control
            CSL_EMIF4F_GetShadowPhyControl (&ddrPHYControl, &ddrPHYReadLatency);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowPowerMgmtConfig | ( | EMIF4F_PWR_MGMT_CONFIG * | ptrPwrMgmtConfig | ) |

============================================================================
CSL_EMIF4F_GetShadowPowerMgmtConfig

Description
The function is used to get the Shadow Power Management Configuration.

Arguments

             ptrPwrMgmtConfig       Power Management Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_PWR_MGMT_CTRL_SHDW_REG_PD_TIM_SHDW, EMIF4F_PWR_MGMT_CTRL_SHDW_REG_SR_TIM_SHDW, EMIF4F_PWR_MGMT_CTRL_SHDW_REG_CS_TIM_SHDW

Example

            EMIF4F_PWR_MGMT_CONFIG pwrConfig;

            // Get the shadow power management configuration.
            CSL_EMIF4F_GetShadowPowerMgmtConfig(&pwrConfig);
            ...

=============================================================================

CSL_IDEF_INLINE Uint16 CSL_EMIF4F_GetShadowRefreshRate | ( | void |  | ) |

============================================================================
CSL_EMIF4F_GetShadowRefreshRate

Description
The function is used to get the refresh rate from the shadow register

Arguments

             None

Return Value
Current Shadow register Refresh Rate configuration

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_REF_CTRL_SHDW_REG_REFRESH_RATE_SHDW

Example

            Uint8   refreshRate;

            // Get the Shadow Register Refresh Rate
            refreshRate = CSL_EMIF4F_GetShadowRefreshRate();
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowTiming1Config | ( | EMIF4F_TIMING1_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetShadowTiming1Config

Description
The function is used to get the Shadow SDRAM Timing1 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RP_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RCD_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_WR_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RAS_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RC_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RRD_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_WTR_SHDW

Example

            EMIF4F_TIMING1_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetShadowTiming1Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowTiming2Config | ( | EMIF4F_TIMING2_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetShadowTiming2Config

Description
The function is used to get the Shadow SDRAM Timing2 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XP_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_ODT_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XSNR_SHDW,EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XSRD_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_RTP_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_CKE_SHDW

Example

            EMIF4F_TIMING2_CONFIG timingConfig;

            // Get the current shadow timing configuration.
            CSL_EMIF4F_GetShadowTiming2Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetShadowTiming3Config | ( | EMIF4F_TIMING3_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetShadowTiming3Config

Description
The function is used to get the Shadow SDRAM Timing3 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_3_SHDW_REG_T_PDLL_UL_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_CSTA_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_CKESR_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_ZQ_ZQCS_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_TDQSCKMAX_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_RFC_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_RAS_MAX_SHDW

Example

            EMIF4F_TIMING3_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetShadowTiming3Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetTempAlertConfig | ( | EMIF4F_TEMP_ALERT_CONFIG * | ptrTempAlertConfig | ) |

============================================================================
CSL_EMIF4F_GetTempAlertConfig

Description
The function is used to get the Temperature Alert configuration

Arguments

            ptrTempAlertConfig    Temperature Alert Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads EMIF4F_TEMP_ALERT_CONFIG_REG_TA_CS1EN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_CS0EN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_SFEXITEN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_DEVWDT, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_DEVCNT, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_REFINTERVAL

Example

            EMIF4F_TEMP_ALERT_CONFIG tempAlertConfig;

            // Get the temperature alert configuration.
            CSL_EMIF4F_GetTempAlertConfig (&tempAlertConfig);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetTiming1Config | ( | EMIF4F_TIMING1_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetTiming1Config

Description
The function is used to get the SDRAM Timing1 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_1_REG_T_RP, EMIF4F_SDRAM_TIM_1_REG_T_RCD, EMIF4F_SDRAM_TIM_1_REG_T_WR, EMIF4F_SDRAM_TIM_1_REG_T_RAS, EMIF4F_SDRAM_TIM_1_REG_T_RC, EMIF4F_SDRAM_TIM_1_REG_T_RRD, EMIF4F_SDRAM_TIM_1_REG_T_WTR

Example

            EMIF4F_TIMING1_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming1Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetTiming2Config | ( | EMIF4F_TIMING2_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetTiming2Config

Description
The function is used to get the SDRAM Timing2 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_2_REG_T_XP, EMIF4F_SDRAM_TIM_2_REG_T_ODT, EMIF4F_SDRAM_TIM_2_REG_T_XSNR,EMIF4F_SDRAM_TIM_2_REG_T_XSRD, EMIF4F_SDRAM_TIM_2_REG_T_RTP, EMIF4F_SDRAM_TIM_2_REG_T_CKE

Example

            EMIF4F_TIMING2_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming2Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetTiming3Config | ( | EMIF4F_TIMING3_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_GetTiming3Config

Description
The function is used to get the SDRAM Timing3 Configuration

Arguments

             ptrTimingConfig       Timing Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_SDRAM_TIM_3_REG_T_PDLL_UL, EMIF4F_SDRAM_TIM_3_REG_T_CSTA, EMIF4F_SDRAM_TIM_3_REG_T_CKESR, EMIF4F_SDRAM_TIM_3_REG_ZQ_ZQCS, EMIF4F_SDRAM_TIM_3_REG_T_TDQSCKMAX,EMIF4F_SDRAM_TIM_3_REG_T_RFC, EMIF4F_SDRAM_TIM_3_REG_T_RAS_MAX

Example

            EMIF4F_TIMING3_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming3Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetVBUSConfig | ( | Uint8 * | cosCount1,
|  | Uint8 * | cosCount2,
|  | Uint8 * | prOldCount |
| ) |  |  |

============================================================================
CSL_EMIF4F_GetVBUSConfig

Description
The function is used to get the VBUSM Configuration

Arguments

            cosCount1   Priority Raise Counter for Class of Service 1
            cosCount2   Priority Raise Counter for Class of Service 2
            prOldCount  Priority Raise Old Counter

Return Value
Priority Raise Old Counter

Pre Condition
None

Post Condition
None

Reads
EMIF4F_VBUSM_CONFIG_REG_COS_COUNT_1, EMIF4F_VBUSM_CONFIG_REG_COS_COUNT_2,
EMIF4F_VBUSM_CONFIG_REG_PR_OLD_COUNT

Example

            Uint8 cosCount1;
            Uint8 cosCount2;
            Uint8 prOldCount;

            // Get the VBUS Configuration
            CSL_EMIF4F_GetVBUSConfig(&cosCount1, &cosCount2, &prOldCount);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_GetVBUSConfigValues | ( | EMIF4F_VBUS_CONFIG_VALUE * | ptrVBUSConfigValue | ) |

============================================================================
CSL_EMIF4F_GetVBUSConfigValues

Description
The function is used to get the VBUSM Configuration values

Arguments

            ptrVBUSConfigValue      VBUS Configuration populated by this API

Return Value
None

Pre Condition
None

Post Condition
None

Reads
EMIF4F_VBUSM_CFG_VAL_1_REG_SYS_BUS_WIDTH, EMIF4F_VBUSM_CFG_VAL_1_REG_STAT_FIFO_DEPTH, EMIF4F_VBUSM_CFG_VAL_1_REG_WR_FIFO_DEPTH, EMIF4F_VBUSM_CFG_VAL_1_REG_CMD_FIFO_DEPTH,
EMIF4F_VBUSM_CFG_VAL_2_REG_RREG_FIFO_DEPTH, EMIF4F_VBUSM_CFG_VAL_2_REG_RSD_FIFO_DEPTH, EMIF4F_VBUSM_CFG_VAL_2_REG_RCMD_FIFO_DEPTH

Example

            EMIF4F_VBUS_CONFIG_VALUE     VBUSconfigValue;

            // Get the VBUS Configuration values
            CSL_EMIF4F_GetVBUSConfigValues(&VBUSconfigValue);
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsAsynchronous | ( |  | ) |

============================================================================
CSL_EMIF4F_IsAsynchronous

Description
The function gets the dual clock mode on which the EMIF4F is operating.

Arguments

             None

Return Value
TRUE - Asynchronous (V_CLK and M_CLK can have any freq ratio)
FALSE - Synchronous (V_CLK is the same as M_CLK)

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_DUAL_CLK_MODE

Example

            // Get the EMIF4F Clock
            if (CSL_EMIF4F_IsAsynchronous () == TRUE)
            {
                // Asynchronous Clock
            }
            else
            {
                // Synchronous Clock
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsBigEndian | ( |  | ) |

============================================================================
CSL_EMIF4F_IsBigEndian

Description
The function gets the endianess mode in which the EMIF4F is operating.

Arguments

             None

Return Value
TRUE - Big Endian Mode
FALSE - Little Endian Mode.

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_BE

Example

            // Get the EMIF4F Endianness mode.
            if (CSL_EMIF4F_IsBigEndian () == TRUE)
            {
                // Big Endian Mode.
            }
            else
            {
                // Little Endian Mode.
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsDDRPhyRead | ( |  | ) |

============================================================================
CSL_EMIF4F_IsDDRPhyRead

Description
The function gets the status of the DDR PHY

Arguments

             None

Return Value
TRUE - DDR PHY is ready
FALSE - DDR PHY is not ready

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_PHY_DLL_READY

Example

            // Get the EMIF4F DDR PHY Ready Status
            if (CSL_EMIF4F_IsDDRPhyRead () == TRUE)
            {
                // DDR PHY is ready
            }
            else
            {
                // DDR PHY is not ready
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsFastInit | ( |  | ) |

============================================================================
CSL_EMIF4F_IsFastInit

Description
The function gets the status of the EMIF fast initialization mode

Arguments

             None

Return Value
TRUE - Fast Initialization Mode has been enabled.
FALSE - Fast Initialization Mode has been disabled.

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_FAST_INIT

Example

            // Get the EMIF4F Fast Initialization status
            if (CSL_EMIF4F_IsFastInit () == TRUE)
            {
                // Fast Initialization is disabled
            }
            else
            {
                // Fast Initialization is enabled
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsReadDataEyeTrainingTimeout | ( |  | ) |

============================================================================
CSL_EMIF4F_IsReadDataEyeTrainingTimeout

Description
The function gets the status of the Data eye training timeout.

Arguments

             None

Return Value
TRUE - Data Eye Training Timed out
FALSE - Data Eye Training has not Timed out

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_RDLVLTO

Example

            // Get the EMIF4F Data Eye training timeout status
            if (CSL_EMIF4F_IsReadDataEyeTrainingTimeout () == TRUE)
            {
                // Data Eye training has timed out
            }
            else
            {
                // Data Eye training has not timed out
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsReadDQSGateTrainingTimeout | ( |  | ) |

============================================================================
CSL_EMIF4F_IsReadDQSGateTrainingTimeout

Description
The function gets the status of the DQS Gate Training Time out.

Arguments

             None

Return Value
TRUE - DQS Gate Training Timed out
FALSE - DQS Gate Training has not Timed out

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_RDLVLGATETO

Example

            // Get the EMIF4F DQS gate training timeout status
            if (CSL_EMIF4F_IsReadDQSGateTrainingTimeout () == TRUE)
            {
                // DQS gate training has timed out
            }
            else
            {
                // DQS gate training has not timed out
            }
            ...

=============================================================================

CSL_IDEF_INLINE Bool CSL_EMIF4F_IsWriteLevelingTimeout | ( |  | ) |

============================================================================
CSL_EMIF4F_IsWriteLevelingTimeout

Description
The function gets the status of the Write Leveling Timeout

Arguments

             None

Return Value
TRUE - Write Leveling Timed out
FALSE - Write Leveling has not Timed out

Pre Condition
None

Post Condition
None

Reads
EMIF4F_STATUS_REG_WRLVLTO

Example

            // Get the EMIF4F Write Leveling timeout status
            if (CSL_EMIF4F_IsWriteLevelingTimeout () == TRUE)
            {
                // Write Leveling has timed out
            }
            else
            {
                // Write Leveling has not timed out
            }
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetECCAddressRange | ( | Uint8 | range,
|  | Uint16 | endAddr,
|  | Uint16 | startAddr |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetECCAddressRange

Description
The function is used to set the ECC Address Range

Arguments

            range           Address Range for which start and end address are required
            endAddr         End Address
            startAddr       Start Address

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_ECC_ADDR_RNG_1_REG_ECC_END_ADDR_1, EMIF4F_ECC_ADDR_RNG_1_REG_ECC_STRT_ADDR_1; EMIF4F_ECC_ADDR_RNG_2_REG_ECC_END_ADDR_2, EMIF4F_ECC_ADDR_RNG_2_REG_ECC_STRT_ADDR_2

Example

            Uint16  endAddr;
            Uint16  startAddr;

            // Set the ECC Address Range1
            CSL_EMIF4F_SetECCAddressRange (1, 0x100, 0x0);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetECCControl | ( | EMIF4_ECC_CONTROL * | ptrECCControl | ) |

============================================================================
CSL_EMIF4F_SetECCControl

Description
The function is used to set the ECC Control Information

Arguments

            ptrECCControl       ECC Control Configuration

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_ECC_CTRL_REG_ECC_EN, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_PROT, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_2_EN, EMIF4F_ECC_CTRL_REG_ECC_ADDR_RNG_1_EN

Example

            EMIF4_ECC_CONTROL eccControl;

            // Get the ECC Control Configuration
            CSL_EMIF4F_GetECCControl (&eccControl);
            ..
            // Enable ECC
            eccControl.enable = 1;
            CSL_EMIF4F_SetECCControl (&eccControl);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetIdleControl | ( | Uint8 | idleLen,
|  | Uint16 | idleInterval |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetIdleControl

Description
The function is used to set the idle control information

Arguments

            idleLen         Idle Length to be configured
            idleInterval    Idle Interval to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_READ_IDLE_CTRL_REG_READ_IDLE_LEN, EMIF4F_READ_IDLE_CTRL_REG_READ_IDLE_INTERVAL

Example

            ...
            // Set the Idle Control Configuration
            CSL_EMIF4F_SetIdleControl (5, 10);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetIdleControlShadow | ( | Uint8 | idleLen,
|  | Uint16 | idleInterval |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetIdleControlShadow

Description
The function is used to set the idle control information in the Shadow register

Arguments

            idleLen         Idle Length to be configured
            idleInterval    Idle Interval to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_READ_IDLE_CTRL_SHDW_REG_READ_IDLE_LEN_SHDW, EMIF4F_READ_IDLE_CTRL_SHDW_REG_READ_IDLE_INTERVAL_SHDW

Example

            ...
            // Set the Idle Control Configuration in the Shadow register
            CSL_EMIF4F_SetIdleControlShadow (5, 10);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetInterruptRawStatus | ( | Uint8 | rawStatus | ) |

============================================================================
CSL_EMIF4F_SetInterruptRawStatus

Description
The function is used to set the interrupt RAW status

Arguments

            rawStatus       Raw Interrupt Status to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_IRQSTATUS_RAW_SYS

Example

            // Set the Interrupt RAW Status for LPDDR2 NVM data not valid
            CSL_EMIF4F_SetInterruptRawStatus (0x4);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetIODFTControl | ( | EMIF4F_IODFT_CONTROL * | ptrIODFTControl | ) |

============================================================================
CSL_EMIF4F_SetIODFTControl

Description
The function is used to set the IODFT Control configuration

Arguments

            ptrIODFTControl      IODFT Control Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_IODFT_TLGC_REG_TLEC, EMIF4F_IODFT_TLGC_REG_MT, EMIF4F_IODFT_TLGC_REG_ACT_CAP_EN,EMIF4F_IODFT_TLGC_REG_OPG_LD, EMIF4F_IODFT_TLGC_REG_MMS, EMIF4F_IODFT_TLGC_REG_MC, EMIF4F_IODFT_TLGC_REG_PC, EMIF4F_IODFT_TLGC_REG_TM

Example

            EMIF4F_IODFT_CONTROL     IODFTcontrol;

            // Get the IODFT Configuration values
            CSL_EMIF4F_GetIODFTControl(&IODFTcontrol);

            // Set the new IODFT configuration
            CSL_EMIF4F_SetIODFTControl (&IODFTcontrol);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLevelingControlInfo | ( | Uint8 | trigger,
|  | Uint8 | preScalar,
|  | Uint8 | readDataEye,
|  | Uint8 | readDQS,
|  | Uint8 | writeInt |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetLevelingControlInfo

Description
The function is used to set the incremental leveling control information

Arguments

            trigger     - Full leveling trigger
            preScalar   - Incremental leveling pre-scalar in number of refresh periods
            readDataEye - Incremental read data eye training interval
            readDQS     - Incremental read DQS gate training interval
            writeInt    - Incremental write leveling interval

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_RDWR_LVL_CTRL_REG_RDWRLVLFULL_START, EMIF4F_RDWR_LVL_CTRL_REG_RDWRLVLINC_PRE, EMIF4F_RDWR_LVL_CTRL_REG_RDLVLINC_INT, EMIF4F_RDWR_LVL_CTRL_REG_RDLVLGATEINC_INT, EMIF4F_RDWR_LVL_CTRL_REG_WRLVLINC_INT

Example

            Uint8  trigger;
            Uint8  preScalar;
            Uint8  readDataEye;
            Uint8  readDQS;
            Uint8  writeInt;

            // Get the Leveling Control Information
            CSL_EMIF4F_GetLevelingControlInfo (&trigger, &preScalar, &readDataEye, &readDQS, &writeInt);
            ...
            // Set the Leveling Control Information
            CSL_EMIF4F_SetLevelingControlInfo(1, preScalar, readDataEye, readDQS, writeInt);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLevelingRampControlInfo | ( | Bool | enable,
|  | Uint8 | preScalar,
|  | Uint8 | readDataEye,
|  | Uint8 | readDQS,
|  | Uint8 | writeInt |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetLevelingRampControlInfo

Description
The function is used to set the incremental leveling ramp control information

Arguments

            enable      - Read-write leveling enable.
            preScalar   - Incremental leveling pre-scalar in number of refresh periods
            readDataEye - Incremental read data eye training interval during ramp window
            readDQS     - Incremental read DQS gate training interval during ramp window
            writeInt    - Incremental write leveling interval during ramp window

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDWRLVL_EN, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDWRLVLINC_RMP_PRE, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDLVLINC_RMP_INT, EMIF4F_RDWR_LVL_RMP_CTRL_REG_RDLVLGATEINC_RMP_INT, EMIF4F_RDWR_LVL_RMP_CTRL_REG_WRLVLINC_RMP_INT

Example

            Uint8  preScalar;
            Uint8  readDataEye;
            Uint8  readDQS;
            Uint8  writeInt;
            Bool   enable;

            // Get the Leveling Ramp Control Information
            CSL_EMIF4F_GetLevelingRampControlInfo (&enable, &preScalar, &readDataEye, &readDQS, &writeInt);
            ...
            // Set the Leveling Ramp control information.
            CSL_EMIF4F_SetLevelingRampControlInfo(enable, preScalar, readDataEye, readDQS, 0x1);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLevelingRampWindow | ( | Uint16 | lvlRampWindow | ) |

============================================================================
CSL_EMIF4F_SetLevelingRampWindow

Description
The function is used to set the incremental leveling ramp window.

Arguments

            lvlRampWindow   - Incremental leveling ramp window in number of
                              refresh periods

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_RDWR_LVL_RMP_WIN_REG_RDWRLVLINC_RMP_WIN

Example

            // Set the Leveling Ramp Window
            CSL_EMIF4F_SetLevelingRampWindow (1000);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLPDDR2ConfigCS | ( | Uint8 | chipSelect | ) |

============================================================================
CSL_EMIF4F_SetLPDDR2ConfigCS

Description
The function is used to set the LPDDR2 Configuration Chip Select

Arguments

             chipSelect     LPDDR2 Configuration Chip Select

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_MODE_REG_CFG_REG_CS

Example

            // Set the LPDDR2 Chip Select to use CS0
            CSL_EMIF4F_SetLPDDR2ConfigCS(0);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLPDDR2ConfigModeRegAddress | ( | Uint8 | modeRegAddr | ) |

============================================================================
CSL_EMIF4F_SetLPDDR2ConfigModeRegAddress

Description
The function is used to set the LPDDR2 Configuration Mode Register Address

Arguments

             modeRegAddr    LPDDR2 Configuration Mode Register Address

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_MODE_REG_CFG_REG_ADDRESS

Example

            // Set the LPDDR2 Config Mode Register Address
            CSL_EMIF4F_SetLPDDR2ConfigModeRegAddress(0x10);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLPDDR2ConfigRefreshEnable | ( | Uint8 | refreshEnable | ) |

============================================================================
CSL_EMIF4F_SetLPDDR2ConfigRefreshEnable

Description
The function is used to set the LPDDR2 Configuration Refresh Enable

Arguments

             refreshEnable  LPDDR2 Configuration Refresh Enable State

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_MODE_REG_CFG_REG_REFRESH_EN

Example

            // Enable refresh enable after MRW
            CSL_EMIF4F_SetLPDDR2ConfigRefreshEnable(1);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLPDDR2Mode | ( | Uint8 | mode | ) |

============================================================================
CSL_EMIF4F_SetLPDDR2Mode

Description
The function is used to get the LPDDR2 Mode

Arguments

             mode   LPDDR2 Mode to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_MODE_REG_DATA_REG_VALUE_0

Example

            // Set the LPDDR2 Mode
            CSL_EMIF4F_SetLPDDR2Mode(1);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetLPDDR2NVMTimingConfig | ( | EMIF4F_LPDDR2NVM_TIMING_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetLPDDR2NVMTimingConfig

Description
The function is used to set the LPDDR2 NVM Timing Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_XP, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_WTR, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RP, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_WRA, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RRD, EMIF4F_LPDDR2_NVM_TIM_REG_NVM_T_RCDMIN

Example

            EMIF4F_LPDDR2NVM_TIMING_CONFIG timingConfig;

            // Get the current LPDDR2 NVM configuration.
            CSL_EMIF4F_GetLPDDR2NVMTimingConfig(&timingConfig);

            // Set the Minimum number of m_clk cycles from Power-Down exit to any command
            timingConfig.t_xp = 1;

            // Set the LPDDR2 NVM configuration.
            CSL_EMIF4F_SetLPDDR2NVMTimingConfig(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetMstIDToCos1Mapping | ( | EMIF4_MSTID_COS_MAPPING * | ptrMstIDCosMapper | ) |

============================================================================
CSL_EMIF4F_SetMstIDToCos1Mapping

Description
The function is used to set the master id to Class of Service 1 mapping

Arguments

            ptrMstIDCosMapper       Master ID to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_MSTID_COS_1_MAP_REG_MSTID_COS_1_MAP_EN, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_1_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_1_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_2_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_2_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSTID_3_COS_1, EMIF4F_MSTID_COS_1_MAP_REG_MSK_3_COS_1

Example

            EMIF4_MSTID_COS_MAPPING mstIDCosMapper;

            // Get the Master ID to COS1 Mapper information
            CSL_EMIF4F_GetMstIDToCos1Mapping (&mstIDCosMapper);
            ...
            // Enable the Master ID to COS1 Mapping
            mstIDCosMapper.enable = 1;
            CSL_EMIF4F_SetMstIDToCos1Mapping (&mstIDCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetMstIDToCos2Mapping | ( | EMIF4_MSTID_COS_MAPPING * | ptrMstIDCosMapper | ) |

============================================================================
CSL_EMIF4F_SetMstIDToCos2Mapping

Description
The function is used to set the master id to Class of Service 2 mapping

Arguments

            ptrMstIDCosMapper       Master ID to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_MSTID_COS_2_MAP_REG_MSTID_COS_2_MAP_EN, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_1_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_1_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_2_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_2_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSTID_3_COS_2, EMIF4F_MSTID_COS_2_MAP_REG_MSK_3_COS_2

Example

            EMIF4_MSTID_COS_MAPPING mstIDCosMapper;

            // Get the Master ID to COS2 Mapper information
            CSL_EMIF4F_GetMstIDToCos2Mapping (&mstIDCosMapper);
            ...
            // Enable the Master ID to COS2 Mapping
            mstIDCosMapper.enable = 1;
            CSL_EMIF4F_SetMstIDToCos2Mapping (&mstIDCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetOutputImpedanceConfig | ( | EMIF4F_OUTPUT_IMP_CONFIG * | ptrOutputImpedanceConfig | ) |

============================================================================
CSL_EMIF4F_SetOutputImpedanceConfig

Description
The function is used to set the Output Impedance Calibrartion configuration

Arguments

            ptrOutputImpedanceConfig    Output Impedance Calibrartion configuration to be
                                        configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_ZQ_CONFIG_REG_ZQ_CS1EN, EMIF4F_ZQ_CONFIG_REG_ZQ_CS0EN, EMIF4F_ZQ_CONFIG_REG_ZQ_DUALCALEN, EMIF4F_ZQ_CONFIG_REG_ZQ_SFEXITEN, EMIF4F_ZQ_CONFIG_REG_ZQ_ZQINIT_MULT,EMIF4F_ZQ_CONFIG_REG_ZQ_ZQCL_MULT, EMIF4F_ZQ_CONFIG_REG_ZQ_REFINTERVAL

Example

            EMIF4F_OUTPUT_IMP_CONFIG outputImpConfig;

            // Get the output impedance configuration
            CSL_EMIF4F_GetOutputImpedanceConfig (&outputImpConfig);

            // Enable ZQ Calibration for CS1
            outputImpConfig.zqCS1En = 1;

            // Set the new output impedance configuration.
            CSL_EMIF4F_SetOutputImpedanceConfig(&outputImpConfig);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPartialArraySelfRefresh | ( | Uint8 | pasr | ) |

============================================================================
CSL_EMIF4F_SetPartialArraySelfRefresh

Description
The function is used to set the partial array self refresh.

Arguments

             pasr   Partial Array Self Refresh configuration

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_PASR

Example

            // Set the Partial Array Refresh Rate Configuration to be for full array
            CSL_EMIF4F_SetPartialArraySelfRefresh(0);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPerfCounterConfig | ( | Uint8 | counter,
|  | EMIF4F_PERF_CONFIG * | ptrPerfCounterConfig |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetPerfCounterConfig

Description
The function is used to set the configuration for performance counters

Arguments

            counter                 Perf Counter for which configuration is to be set (1 or 2)
            ptrPerfCounterConfig    Performance Counter Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_PERF_CNT_CFG_REG_CNTR2_MCONNID_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR2_REGION_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR2_CFG; EMIF4F_PERF_CNT_CFG_REG_CNTR1_MCONNID_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR1_REGION_EN, EMIF4F_PERF_CNT_CFG_REG_CNTR1_CFG

Example

            EMIF4F_PERF_CONFIG     perfCounterConfig;

            // Get the EMIF4F Performance Counter Configuration for counter 2
            CSL_EMIF4F_GetPerfCounterConfig(2, &perfCounterConfig);

            // Enable Master ID Filter Enable
            perfCounterConfig.mstIDEn = 1;

            // Set the EMIF4F Performance Counter Configuration.
            CSL_EMIF4F_SetPerfCounterConfig(2, &perfCounterConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPerfCounterMasterRegion | ( | Uint8 | counter,
|  | Uint8 | mstID,
|  | Uint8 | regionSel |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetPerfCounterMasterRegion

Description
The function is used to set the master region selection for the specific performance counters

Arguments

            counter          Perf Counter for which master region selection is configured
            mstID            Master ID selection for the specified performance counter
            regionSel        Region Selection for the specified performance counter

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_PERF_CNT_SEL_REG_MCONNID1, EMIF4F_PERF_CNT_SEL_REG_REGION_SEL1; EMIF4F_PERF_CNT_SEL_REG_MCONNID2, EMIF4F_PERF_CNT_SEL_REG_REGION_SEL2

Example

            Uint8   mstID;
            Uint8   regionSel;

            // Get the Master Region Selection for Counter 1
            CSL_EMIF4F_GetPerfCounterMasterRegion (1, &mstID, &regionSel);

            // Change Master ID to be 5
            CSL_EMIF4F_SetPerfCounterMasterRegion(1, 5, regionSel);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPhyControl | ( | Uint32 | ddrPHYControl,
|  | Uint8 | ddrPHYReadLatency |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetPhyControl

Description
The function is used to set the DDR PHY Control

Arguments

            ddrPHYControl       DDR PHY Control specific to be configured
            ddrPHYReadLatency   DDR PHY Read Latency to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_DDR_PHY_CTRL_1_REG_DDR_PHY_CTRL_1, EMIF4F_DDR_PHY_CTRL_1_REG_READ_LATENCY

Example

            Uint32 ddrPHYControl;
            Uint8  ddrPHYReadLatency;

            // Get the DDR PHY Control
            CSL_EMIF4F_GetPhyControl (&ddrPHYControl, &ddrPHYReadLatency);

            // Set Read Latency as 5 and reconfigure the PHY
            CSL_EMIF4F_SetPhyControl(ddrPHYControl, 5);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPhyControl2 | ( | Uint32 | ddrPHYControl | ) |

============================================================================
CSL_EMIF4F_SetPhyControl2

Description
The function is used to write the DDR PHY Control2 register. This is PHY specific

Arguments

            ddrPHYControl       DDR PHY Control configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_DDR_PHY_CTRL_2

Example

            // Set the DDR PHY Control2 configuration
            CSL_EMIF4F_SetPhyControl2 (0x10);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPowerMgmtConfig | ( | EMIF4F_PWR_MGMT_CONFIG * | ptrPwrMgmtConfig | ) |

============================================================================
CSL_EMIF4F_SetPowerMgmtConfig

Description
The function is used to set the Power Management Configuration.

Arguments

             ptrPwrMgmtConfig       Power Management Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_PWR_MGMT_CTRL_REG_PD_TIM, EMIF4F_PWR_MGMT_CTRL_REG_DPD_EN, EMIF4F_PWR_MGMT_CTRL_REG_LP_MODE, EMIF4F_PWR_MGMT_CTRL_REG_SR_TIM, EMIF4F_PWR_MGMT_CTRL_REG_CS_TIM

Example

            EMIF4F_PWR_MGMT_CONFIG pwrConfig;

            // Get the power management configuration.
            CSL_EMIF4F_GetPowerMgmtConfig(&pwrConfig);

            // Enable Deep Power Down Mode
            pwrConfig.dpdEnable = 1;

            // Set the power management configuration
            CSL_EMIF4F_SetPowerMgmtConfig(&pwrConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetPriorityToCOSMapping | ( | EMIF4_PRI_COS_MAPPING * | ptrPriCosMapper | ) |

============================================================================
CSL_EMIF4F_SetPriorityToCOSMapping

Description
The function is used to set the priority to class of service mapping.

Arguments

            ptrPriCosMapper       Priority to COS Mapping configuration

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_PRI_COS_MAP_REG_PRI_COS_MAP_EN, EMIF4F_PRI_COS_MAP_REG_PRI_7_COS, EMIF4F_PRI_COS_MAP_REG_PRI_5_COS, EMIF4F_PRI_COS_MAP_REG_PRI_4_COS, EMIF4F_PRI_COS_MAP_REG_PRI_3_COS, EMIF4F_PRI_COS_MAP_REG_PRI_2_COS, EMIF4F_PRI_COS_MAP_REG_PRI_1_COS, EMIF4F_PRI_COS_MAP_REG_PRI_0_COS

Example

            EMIF4_PRI_COS_MAPPING priCosMapper;

            // Get the Priority to COS Mapper information
            CSL_EMIF4F_GetPriorityToCOSMapping (&priCosMapper);
            ...
            // Configure the mapper to allow priority to COS mapping
            priCosMapper.enable = 1;
            CSL_EMIF4F_SetPriorityToCOSMapping (&priCosMapper);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetReadWriteThreshold | ( | Uint8 | wrThreshold,
|  | Uint8 | rdThreshold |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetReadWriteThreshold

Description
The function is used to set the Read, Write Execution Thresholds

Arguments

            wrThreshold       Write Threshold
            rdThreshold       Read  Threshold

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_RD_WR_EXEC_THRSH_REG_WR_THRSH, EMIF4F_RD_WR_EXEC_THRSH_REG_RD_THRSH

Example

            // Get the Read, Write Execution Thresholds.
            CSL_EMIF4F_SetReadWriteThreshold (1, 2);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetRefreshRate | ( | Uint16 | refreshRate | ) |

============================================================================
CSL_EMIF4F_SetRefreshRate

Description
The function is used to set the refresh rate

Arguments

             refreshRate   Refresh Rate to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_REFRESH_RATE

Example

            // Enable Initialization & Refresh
            CSL_EMIF4F_EnableInitRefresh();

            // Set the Refresh Rate to be 15.7 us
            CSL_EMIF4F_SetRefreshRate(0x7AA);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetSDRAMConfig | ( | EMIF4F_SDRAM_CONFIG * | ptrConfig | ) |

============================================================================
CSL_EMIF4F_SetSDRAMConfig

Description
The function sets the SDRAM Configuration as specified.

Arguments

             ptrConfig  SDRAM Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_CONFIG_REG_SDRAM_TYPE,EMIF4F_SDRAM_CONFIG_REG_IBANK_POS, EMIF4F_SDRAM_CONFIG_REG_DDR_TERM,EMIF4F_SDRAM_CONFIG_REG_DDR2_DDQS, EMIF4F_SDRAM_CONFIG_REG_DYN_ODT,EMIF4F_SDRAM_CONFIG_REG_DDR_DISABLE_DLL, EMIF4F_SDRAM_CONFIG_REG_SDRAM_DRIVE,EMIF4F_SDRAM_CONFIG_REG_CWL, EMIF4F_SDRAM_CONFIG_REG_NARROW_MODE,EMIF4F_SDRAM_CONFIG_REG_CL, EMIF4F_SDRAM_CONFIG_REG_ROWSIZE,EMIF4F_SDRAM_CONFIG_REG_IBANK, EMIF4F_SDRAM_CONFIG_REG_EBANK,EMIF4F_SDRAM_CONFIG_REG_PAGESIZE
EMIF4F_SDRAM_CONFIG_2_REG_CS1NVMEN,EMIF4F_SDRAM_CONFIG_2_REG_EBANK_POS, EMIF4F_SDRAM_CONFIG_2_REG_RDBNUM,EMIF4F_SDRAM_CONFIG_2_REG_RDBSIZE

Example

            EMIF4F_SDRAM_CONFIG  sdramConfig;
            ...
            // Get the EMIF4F SDRAM Configuration.
            CSL_EMIF4F_GetSDRAMConfig (&sdramConfig);
            ...
            // Set the SDRAM Data Bus Width to be 32 bits
            sdramConfig.narrowMode = 0;

            // Set the EMIF4F SDRAM Configuration.
            CSL_EMIF4F_SetSDRAMConfig (&sdramConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetSelfRefreshTemp | ( | Uint8 | temperature | ) |

============================================================================
CSL_EMIF4F_SetSelfRefreshTemp

Description
The function is used to get the DDR3 Self Refresh Temperature.

Arguments

             temperature    - Operating Temperature to be configured.

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_REG_SRT

Example

            // Set Self Referesh Temperature for normal operation.
            CSL_EMIF4F_SetSelfRefreshTemp(0);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowLPDDR2NVMTimingConfig | ( | EMIF4F_LPDDR2NVM_TIMING_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetShadowLPDDR2NVMTimingConfig

Description
The function is used to set the Shadow LPDDR2 NVM Timing Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_XP_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_WTR_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RP_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_WRA_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RRD_SHDW, EMIF4F_LPDDR2_NVM_TIM_SHDW_REG_NVM_T_RCDMIN_SHDW

Example

            EMIF4F_LPDDR2NVM_TIMING_CONFIG timingConfig;

            // Get the current Shadow LPDDR2 NVM configuration.
            CSL_EMIF4F_GetShadowLPDDR2NVMTimingConfig(&timingConfig);

            // Set the Minimum number of m_clk cycles from Power-Down exit to any command
            timingConfig.t_xp = 1;

            // Set the Shadow LPDDR2 NVM configuration.
            CSL_EMIF4F_SetShadowLPDDR2NVMTimingConfig(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowPhyControl | ( | Uint32 | ddrPHYControl,
|  | Uint8 | ddrPHYReadLatency |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetShadowPhyControl

Description
The function is used to set the Shadow DDR PHY Control

Arguments

            ddrPHYControl       DDR PHY Control specific to be configured
            ddrPHYReadLatency   DDR PHY Read Latency to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_DDR_PHY_CTRL_1_SHDW_REG_DDR_PHY_CTRL_1_SHDW, EMIF4F_DDR_PHY_CTRL_1_SHDW_REG_READ_LATENCY_SHDW

Example

            Uint32 ddrPHYControl;
            Uint8  ddrPHYReadLatency;

            // Get the DDR PHY Control
            CSL_EMIF4F_GetShadowPhyControl (&ddrPHYControl, &ddrPHYReadLatency);

            // Set Read Latency as 5 and reconfigure the PHY
            CSL_EMIF4F_SetShadowPhyControl(ddrPHYControl, 5);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowPowerMgmtConfig | ( | EMIF4F_PWR_MGMT_CONFIG * | ptrPwrMgmtConfig | ) |

============================================================================
CSL_EMIF4F_SetShadowPowerMgmtConfig

Description
The function is used to set the Shadow Power Management Configuration.

Arguments

             ptrPwrMgmtConfig       Power Management Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_PWR_MGMT_CTRL_SHDW_REG_PD_TIM_SHDW, EMIF4F_PWR_MGMT_CTRL_SHDW_REG_SR_TIM_SHDW, EMIF4F_PWR_MGMT_CTRL_SHDW_REG_CS_TIM_SHDW

Example

            EMIF4F_PWR_MGMT_CONFIG pwrConfig;

            // Get the power management configuration.
            CSL_EMIF4F_GetShadowPowerMgmtConfig(&pwrConfig);

            // Set the power management timer for clock stop to immediately enter clock stop
            pwrConfig.csTime = 0;

            // Set the power management configuration
            CSL_EMIF4F_SetShadowPowerMgmtConfig(&pwrConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowRefreshRate | ( | Uint16 | refreshRate | ) |

============================================================================
CSL_EMIF4F_SetShadowRefreshRate

Description
The function is used to set the refresh rate

Arguments

             refreshRate   Refresh Rate to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_REF_CTRL_SHDW_REG_REFRESH_RATE_SHDW

Example

            // Set the Shadow Register Refresh Rate to be 15.7 us
            CSL_EMIF4F_SetShadowRefreshRate(0x7AA);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowTiming1Config | ( | EMIF4F_TIMING1_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetShadowTiming1Config

Description
The function is used to set the Shadow SDRAM Timing1 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RP_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RCD_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_WR_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RAS_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RC_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_RRD_SHDW, EMIF4F_SDRAM_TIM_1_SHDW_REG_T_WTR_SHDW

Example

            EMIF4F_TIMING1_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetShadowTiming1Config(&timingConfig);
            ...
            // Set the min number of m_clk cycles from precharge to activate
            timingConfig.t_rp = 1;

            // Configure the Timing Shadow
            CSL_EMIF4F_SetShadowTiming1Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowTiming2Config | ( | EMIF4F_TIMING2_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetShadowTiming2Config

Description
The function is used to set the Shadow SDRAM Timing2 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XP_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_ODT_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XSNR_SHDW,EMIF4F_SDRAM_TIM_2_SHDW_REG_T_XSRD_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_RTP_SHDW, EMIF4F_SDRAM_TIM_2_SHDW_REG_T_CKE_SHDW

Example

            EMIF4F_TIMING2_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetShadowTiming2Config(&timingConfig);

            // Set the number of m_clk cycles from Power Down to any command
            timingConfig.t_xp = 0x2;

            // Set the new timing configuration.
            CSL_EMIF4F_SetShadowTiming2Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetShadowTiming3Config | ( | EMIF4F_TIMING3_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetShadowTiming3Config

Description
The function is used to set the Shadow SDRAM Timing3 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_3_SHDW_REG_T_PDLL_UL_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_CSTA_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_CKESR_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_ZQ_ZQCS_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_TDQSCKMAX_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_RFC_SHDW, EMIF4F_SDRAM_TIM_3_SHDW_REG_T_RAS_MAX_SHDW

Example

            EMIF4F_TIMING3_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetShadowTiming3Config(&timingConfig);

            // Set the Maximum number of reg_refresh_rate intervals from Activate to Precharge command.
            timingConfig.t_rasMax = 0x3;

            // Set the timing configuration
            CSL_EMIF4F_SetShadowTiming3Config (&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetTempAlertConfig | ( | EMIF4F_TEMP_ALERT_CONFIG * | ptrTempAlertConfig | ) |

============================================================================
CSL_EMIF4F_SetTempAlertConfig

Description
The function is used to set the Temperature Alert configuration

Arguments

            ptrTempAlertConfig    Temperature Alert Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes EMIF4F_TEMP_ALERT_CONFIG_REG_TA_CS1EN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_CS0EN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_SFEXITEN, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_DEVWDT, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_DEVCNT, EMIF4F_TEMP_ALERT_CONFIG_REG_TA_REFINTERVAL

Example

            EMIF4F_TEMP_ALERT_CONFIG tempAlertConfig;

            // Get the temperature alert configuration.
            CSL_EMIF4F_GetTempAlertConfig (&tempAlertConfig);

            // Enable Temperature Alert Polling for CS1
            tempAlertConfig.taCS1En = 1;

            // Set the new temperature alert configuration.
            CSL_EMIF4F_SetTempAlertConfig(&tempAlertConfig);

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetTiming1Config | ( | EMIF4F_TIMING1_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetTiming1Config

Description
The function is used to set the SDRAM Timing1 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_1_REG_T_RP, EMIF4F_SDRAM_TIM_1_REG_T_RCD, EMIF4F_SDRAM_TIM_1_REG_T_WR, EMIF4F_SDRAM_TIM_1_REG_T_RAS, EMIF4F_SDRAM_TIM_1_REG_T_RC, EMIF4F_SDRAM_TIM_1_REG_T_RRD, EMIF4F_SDRAM_TIM_1_REG_T_WTR

Example

            EMIF4F_TIMING1_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming1Config(&timingConfig);

            // Set the min number of m_clk cycles from precharge to activate
            timingConfig.t_rp = 1;

            // Set the timing configuration.
            CSL_EMIF4F_SetTiming1Config (&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetTiming2Config | ( | EMIF4F_TIMING2_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetTiming2Config

Description
The function is used to set the SDRAM Timing2 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_2_REG_T_XP, EMIF4F_SDRAM_TIM_2_REG_T_ODT, EMIF4F_SDRAM_TIM_2_REG_T_XSNR,EMIF4F_SDRAM_TIM_2_REG_T_XSRD, EMIF4F_SDRAM_TIM_2_REG_T_RTP, EMIF4F_SDRAM_TIM_2_REG_T_CKE

Example

            EMIF4F_TIMING2_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming2Config(&timingConfig);

            // Set the number of m_clk cycles from Power Down to any command
            timingConfig.t_xp = 0x2;

            // Set the new timing configuration.
            CSL_EMIF4F_SetTiming2Config(&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetTiming3Config | ( | EMIF4F_TIMING3_CONFIG * | ptrTimingConfig | ) |

============================================================================
CSL_EMIF4F_SetTiming3Config

Description
The function is used to set the SDRAM Timing3 Configuration

Arguments

             ptrTimingConfig       Timing Configuration to be configured

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_SDRAM_TIM_3_REG_T_PDLL_UL, EMIF4F_SDRAM_TIM_3_REG_T_CSTA, EMIF4F_SDRAM_TIM_3_REG_T_CKESR, EMIF4F_SDRAM_TIM_3_REG_ZQ_ZQCS, EMIF4F_SDRAM_TIM_3_REG_T_TDQSCKMAX,EMIF4F_SDRAM_TIM_3_REG_T_RFC, EMIF4F_SDRAM_TIM_3_REG_T_RAS_MAX

Example

            EMIF4F_TIMING3_CONFIG timingConfig;

            // Get the current timing configuration.
            CSL_EMIF4F_GetTiming3Config(&timingConfig);

            // Set the Maximum number of reg_refresh_rate intervals from Activate to Precharge command.
            timingConfig.t_rasMax = 0x3;

            // Set the timing configuration
            CSL_EMIF4F_SetTiming3Config (&timingConfig);
            ...

=============================================================================

CSL_IDEF_INLINE void CSL_EMIF4F_SetVBUSConfig | ( | Uint8 | cosCount1,
|  | Uint8 | cosCount2,
|  | Uint8 | prOldCount |
| ) |  |  |

============================================================================
CSL_EMIF4F_SetVBUSConfig

Description
The function is used to set the VBUSM Configuration

Arguments

            cosCount1   Priority Raise Counter for Class of Service 1
            cosCount2   Priority Raise Counter for Class of Service 2
            prOldCount  Priority Raise Old Counter

Return Value
None

Pre Condition
None

Post Condition
None

Writes
EMIF4F_VBUSM_CONFIG_REG_COS_COUNT_1, EMIF4F_VBUSM_CONFIG_REG_COS_COUNT_2,
EMIF4F_VBUSM_CONFIG_REG_PR_OLD_COUNT

Example

            Uint8 cosCount1;
            Uint8 cosCount2;
            Uint8 prOldCount;

            // Get the VBUS Configuration
            CSL_EMIF4F_GetVBUSConfig(&cosCount1, &cosCount2, &prOldCount);

            // Set the VBUS Configuration
            CSL_EMIF4F_SetVBUSConfig(cosCount1, cosCount2, 0x1);
            ...

=============================================================================

Copyright 2012, Texas Instruments Incorporated