iLLD_TC27xC
1.0
|
VADC basic functionality. More...
Go to the source code of this file.
Functions | |
IFX_INLINE void | IfxVadc_configureWaitForReadMode (Ifx_VADC_G *group, uint32 resultIdx, boolean waitForRead) |
access function to enable/disable wait for read mode for result registers More... | |
IFX_INLINE void | IfxVadc_configureWaitForReadModeForGlobalResultRegister (Ifx_VADC *vadc, boolean waitForRead) |
access function to enable/disable wait for read mode for global result register More... | |
IFX_INLINE void | IfxVadc_enableBackgroundScanSlotExternalTrigger (Ifx_VADC *vadc) |
Enables the background sacn external trigger. More... | |
IFX_INLINE IfxVadc_GatingMode | IfxVadc_getBackgroundScanGatingMode (Ifx_VADC *vadc) |
Gets the background scan gating mode. More... | |
IFX_INLINE IfxVadc_GatingSource | IfxVadc_getBackgroundScanGatingSource (Ifx_VADC *vadc) |
Gets the gating input selection. More... | |
IFX_INLINE IfxVadc_RequestSlotPriority | IfxVadc_getBackgroundScanSlotPriority (Ifx_VADC_G *vadcG) |
Gets the requested background scan slot priority. More... | |
IFX_INLINE IfxVadc_RequestSlotStartMode | IfxVadc_getBackgroundScanSlotStartMode (Ifx_VADC_G *vadcG) |
Gets the requested background scan slot start mode. More... | |
IFX_INLINE IfxVadc_TriggerSource | IfxVadc_getBackgroundScanTriggerInput (Ifx_VADC *vadc) |
Gets the background scan trigger input. More... | |
IFX_INLINE IfxVadc_TriggerMode | IfxVadc_getBackgroundScanTriggerMode (Ifx_VADC *vadc) |
Gets the background scan external trigger mode. More... | |
IFX_INLINE Ifx_VADC_GLOBRES | IfxVadc_getGlobalResult (Ifx_VADC *vadc) |
return conversion result stored in the Global result Register More... | |
IFX_INLINE void | IfxVadc_getGroupResult (Ifx_VADC_G *group, Ifx_VADC_RES *results, uint32 resultOffset, uint32 numResults) |
Get conversion result for the group. More... | |
IFX_INLINE Ifx_VADC_RES | IfxVadc_getResult (Ifx_VADC_G *group, uint32 resultIdx) |
Get conversion result (Function does not care about the alignment) value = raw * gain + offset. More... | |
IFX_INLINE boolean | IfxVadc_isAutoBackgroundScanEnabled (Ifx_VADC *vadc) |
Returns the auto background scan status. More... | |
IFX_INLINE boolean | IfxVadc_isRequestBackgroundScanSlotEnabled (Ifx_VADC_G *vadcG) |
Returns the background scan slot requested status. More... | |
IFX_INLINE void | IfxVadc_setAutoBackgroundScan (Ifx_VADC *vadc, boolean autoBackgroundScanEnable) |
Sets the auto background scan to enable or disable. More... | |
IFX_INLINE void | IfxVadc_setBackgroundScan (Ifx_VADC *vadc, IfxVadc_GroupId groupId, uint32 channels, uint32 mask) |
configures a background scan; can also stop autoscan if all channels are 0 More... | |
IFX_INLINE void | IfxVadc_setBackgroundScanSlotGatingConfig (Ifx_VADC *vadc, IfxVadc_GatingSource gatingSource, IfxVadc_GatingMode gatingMode) |
Sets the background scan slot gating configurations. More... | |
IFX_INLINE void | IfxVadc_setBackgroundScanSlotTriggerConfig (Ifx_VADC *vadc, IfxVadc_TriggerMode triggerMode, IfxVadc_TriggerSource triggerSource) |
Sets the background scan exteranal trigger operating configurations. More... | |
IFX_INLINE void | IfxVadc_startBackgroundScan (Ifx_VADC *vadc, boolean continuous) |
Starts a background scan in either continuous or single shot conversion mode as per the parameter. More... | |
IFX_EXTERN IfxVadc_Status | IfxVadc_getBackgroundScanStatus (Ifx_VADC *vadc) |
Gives the background scan status for a group. More... | |
IFX_EXTERN Ifx_VADC_RES | IfxVadc_getResultBasedOnRequestSource (Ifx_VADC *vadc, Ifx_VADC_G *group, IfxVadc_ChannelId channel, IfxVadc_RequestSource sourceType) |
Get conversion result (Function does not care about the alignment) value = raw * gain + offset. More... | |
IFX_INLINE void | IfxVadc_disableScanSlotExternalTrigger (Ifx_VADC_G *vadcG) |
Disables the scan slot external trigger. More... | |
IFX_INLINE void | IfxVadc_enableScanSlotExternalTrigger (Ifx_VADC_G *vadcG) |
Enables the scan slot external trigger. More... | |
IFX_INLINE IfxVadc_GatingMode | IfxVadc_getScanSlotGatingMode (Ifx_VADC_G *vadcG) |
Gets the request scan slot gating mode. More... | |
IFX_INLINE IfxVadc_GatingSource | IfxVadc_getScanSlotGatingSource (Ifx_VADC_G *vadcG) |
Gets the request scan slot gating input. More... | |
IFX_INLINE IfxVadc_RequestSlotPriority | IfxVadc_getScanSlotPriority (Ifx_VADC_G *vadcG) |
Gets the request scan slot priority. More... | |
IFX_INLINE IfxVadc_RequestSlotStartMode | IfxVadc_getScanSlotStartMode (Ifx_VADC_G *vadcG) |
Gets the request scan slot start mode. More... | |
IFX_INLINE IfxVadc_TriggerSource | IfxVadc_getScanSlotTriggerInput (Ifx_VADC_G *vadcG) |
Gets the requested scan slot trigger input. More... | |
IFX_INLINE IfxVadc_TriggerMode | IfxVadc_getScanSlotTriggerMode (Ifx_VADC_G *vadcG) |
Gets the requested scan slot trigger mode. More... | |
IFX_INLINE boolean | IfxVadc_isAutoScanEnabled (Ifx_VADC_G *vadcG) |
Gets the auto scan enable status. More... | |
IFX_INLINE boolean | IfxVadc_isRequestScanSlotEnabled (Ifx_VADC_G *vadcG) |
Returns the scan slot requested status. More... | |
IFX_INLINE void | IfxVadc_setAutoScan (Ifx_VADC_G *vadcG, boolean autoscanEnable) |
Sets the autosacn bit enable or disable. More... | |
IFX_INLINE void | IfxVadc_setScanSlotGatingConfig (Ifx_VADC_G *vadcG, IfxVadc_GatingSource gatingSource, IfxVadc_GatingMode gatingMode) |
Sets the scan slot gating configuration. More... | |
IFX_INLINE void | IfxVadc_setScanSlotTriggerConfig (Ifx_VADC_G *vadcG, IfxVadc_TriggerMode triggerMode, IfxVadc_TriggerSource triggerSource) |
Sets the scan slot trigger operating configurations. More... | |
IFX_INLINE void | IfxVadc_startScan (Ifx_VADC_G *group) |
Starts an autoscan on the specified group. More... | |
IFX_EXTERN IfxVadc_Status | IfxVadc_getScanStatus (Ifx_VADC_G *group) |
Gives the scan status for a group. More... | |
IFX_EXTERN void | IfxVadc_setScan (Ifx_VADC_G *group, uint32 channels, uint32 mask, boolean continuous) |
Configures an (auto-)scan. More... | |
IFX_INLINE void | IfxVadc_addToQueue (Ifx_VADC_G *group, IfxVadc_ChannelId channel, uint32 options) |
Add an entry to the queue of a group for the specified channel with the following options set: refill incase of aborted conversion source interrupt enable/disable external trigger control of the aborted conversion. More... | |
IFX_INLINE void | IfxVadc_clearQueue (Ifx_VADC_G *vadcG, boolean flushQueue) |
Clears all the queue entries including backup stage. More... | |
IFX_INLINE void | IfxVadc_disableQueueSlotExternalTrigger (Ifx_VADC_G *vadcG) |
Disables the external trigger. More... | |
IFX_INLINE void | IfxVadc_enableQueueSlotExternalTrigger (Ifx_VADC_G *vadcG) |
Enables the external trigger. More... | |
IFX_INLINE IfxVadc_GatingMode | IfxVadc_getQueueSlotGatingMode (Ifx_VADC_G *vadcG) |
Gets the requested queue slot gating mode. More... | |
IFX_INLINE IfxVadc_GatingSource | IfxVadc_getQueueSlotGatingSource (Ifx_VADC_G *vadcG) |
Gets the requested queue slot gating input. More... | |
IFX_INLINE IfxVadc_RequestSlotPriority | IfxVadc_getQueueSlotPriority (Ifx_VADC_G *vadcG) |
Gets the request queue slot priority. More... | |
IFX_INLINE IfxVadc_RequestSlotStartMode | IfxVadc_getQueueSlotStartMode (Ifx_VADC_G *vadcG) |
Gets the requested queue slot start mode. More... | |
IFX_INLINE IfxVadc_TriggerSource | IfxVadc_getQueueSlotTriggerInput (Ifx_VADC_G *vadcG) |
Gets the requested queue slot trigger input. More... | |
IFX_INLINE IfxVadc_TriggerMode | IfxVadc_getQueueSlotTriggerMode (Ifx_VADC_G *vadcG) |
Gets the requested queue slot trigger mode. More... | |
IFX_INLINE boolean | IfxVadc_isRequestQueueSlotEnabled (Ifx_VADC_G *vadcG) |
Returns the queue slot requested status. More... | |
IFX_INLINE void | IfxVadc_setQueueSlotGatingConfig (Ifx_VADC_G *vadcG, IfxVadc_GatingSource gatingSource, IfxVadc_GatingMode gatingMode) |
Sets the gating configurations. More... | |
IFX_INLINE void | IfxVadc_setQueueSlotTriggerOperatingConfig (Ifx_VADC_G *vadcG, IfxVadc_TriggerMode triggerMode, IfxVadc_TriggerSource triggerSource) |
Sets the trigger operating configurations. More... | |
IFX_INLINE void | IfxVadc_startQueue (Ifx_VADC_G *group) |
Starts a queue of a group by generating a trigger event through software. More... | |
IFX_EXTERN IfxVadc_Status | IfxVadc_getQueueStatus (Ifx_VADC_G *group) |
Gives the status of the Queue of a group by returning non zero value if the Queue is full. More... | |
IFX_INLINE void | IfxVadc_initEmuxPin (const IfxVadc_Emux_Out *emux, IfxPort_OutputMode outputMode, IfxPort_PadDriver padDriver) |
Initializes a EMUX output. More... | |
IFX_INLINE void | IfxVadc_initGxBflPin (const IfxVadc_GxBfl_Out *gxBfl, IfxPort_OutputMode outputMode, IfxPort_PadDriver padDriver) |
Initializes a GxBFL output. More... | |
IFX_INLINE uint32 | IfxVadc_calculateSampleTimeTicks (float32 analogFrequency, float32 sampleTime) |
Calculate the time ticks using analog frequency. More... | |
IFX_EXTERN float32 | IfxVadc_getAdcAnalogFrequency (Ifx_VADC *vadc) |
Returns the configured Fadci VADC analog clock frequency in Hz. More... | |
IFX_EXTERN float32 | IfxVadc_getAdcModuleFrequency (Ifx_VADC *vadc) |
Returns the configured Fadcd VADC digital clock frequency in Hz. More... | |
IFX_INLINE void | IfxVadc_clearAllResultRequests (Ifx_VADC_G *vadcG) |
Clears the all group requests. More... | |
IFX_INLINE IfxVadc_ArbitrationRounds | IfxVadc_getArbiterRoundLength (Ifx_VADC_G *vadcG) |
Gets the ADC group arbitration round length. More... | |
IFX_INLINE Ifx_VADC_G_REVNP0 | IfxVadc_getChannelResultServiceRequestNodePointer0 (Ifx_VADC_G *vadcG) |
Gets the channel esult service request node pointer 0. More... | |
IFX_INLINE Ifx_VADC_G_REVNP1 | IfxVadc_getChannelResultServiceRequestNodePointer1 (Ifx_VADC_G *vadcG) |
Gets the channel esult service request node pointer 1. More... | |
IFX_INLINE Ifx_VADC_G_CEVNP0 | IfxVadc_getChannelServiceRequestNodePointer (Ifx_VADC_G *vadcG) |
Gets the channel service request node pointer. More... | |
IFX_INLINE uint8 | IfxVadc_getMasterIndex (Ifx_VADC_G *vadcG) |
Gets the configured master index. More... | |
IFX_INLINE void | IfxVadc_resetGroup (Ifx_VADC_G *vadcG) |
Resets the ADC group. More... | |
IFX_INLINE void | IfxVadc_setAnalogConvertControl (Ifx_VADC_G *vadcG, IfxVadc_AnalogConverterMode analogConverterMode) |
Sets analog converter group number. More... | |
IFX_INLINE void | IfxVadc_setArbitrationRoundLength (Ifx_VADC_G *vadcG, IfxVadc_ArbitrationRounds arbiterRoundLength) |
Sets the arbiter round length. More... | |
IFX_INLINE void | IfxVadc_setInputClassResolution (Ifx_VADC_G *vadcG, uint8 inputClassNum, IfxVadc_ChannelResolution resolution) |
Sets the ADC input class channel resolution. More... | |
IFX_INLINE void | IfxVadc_setInputClassSampleTimeTicks (Ifx_VADC_G *vadcG, uint8 inputClassNum, float32 analogFrequency, float32 sampleTime) |
Sets the ADC input class sample time ticks. More... | |
IFX_INLINE void | IfxVadc_setMasterIndex (Ifx_VADC_G *vadcG, uint8 masterIndex) |
Sets the master index. More... | |
IFX_EXTERN void | IfxVadc_setArbiterPriority (Ifx_VADC_G *vadcG, boolean slotEnable, IfxVadc_RequestSlotPriority prio, IfxVadc_RequestSlotStartMode mode, IfxVadc_RequestSource slot) |
Sets the Arbiter slot configurations. More... | |
IFX_INLINE void | IfxVadc_enableModule (Ifx_VADC *vadc) |
Enable VADC kernel. More... | |
IFX_INLINE uint8 | IfxVadc_getAdcCalibrationActiveState (Ifx_VADC *vadc, uint8 adcCalGroupNum) |
gets ADC Calibration Flag CAL status. More... | |
IFX_INLINE Ifx_VADC_GLOBCFG | IfxVadc_getGlobalConfigValue (Ifx_VADC *vadc) |
Gets the global control configuration value. More... | |
IFX_INLINE void | IfxVadc_initiateStartupCalibration (Ifx_VADC *vadc) |
initiates the calibration pulse phase. More... | |
IFX_INLINE void | IfxVadc_setChannelResolution (Ifx_VADC *vadc, uint8 groupInputClassNum, IfxVadc_ChannelResolution resolution) |
Sets the channel conversion mode. More... | |
IFX_INLINE void | IfxVadc_setSampleTimeTicks (Ifx_VADC *vadc, uint8 groupInputClassNum, float32 analogFrequency, float32 sampleTime) |
Sets the sample time ticks of ADC group class. More... | |
IFX_EXTERN void | IfxVadc_disableAccess (Ifx_VADC *vadc, IfxVadc_Protection protectionSet) |
Disable write access to the VADC config/control registers. More... | |
IFX_EXTERN void | IfxVadc_disablePostCalibration (Ifx_VADC *vadc, IfxVadc_GroupId group, boolean disable) |
Disables the post calibration. More... | |
IFX_EXTERN void | IfxVadc_enableAccess (Ifx_VADC *vadc, IfxVadc_Protection protectionSet) |
Enable write access to the VADC config/control registers. More... | |
IFX_EXTERN volatile Ifx_SRC_SRCR * | IfxVadc_getSrcAddress (IfxVadc_GroupId group, IfxVadc_SrcNr index) |
Gives the SRC source address. More... | |
IFX_EXTERN void | IfxVadc_initialiseAdcArbiterClock (Ifx_VADC *vadc, uint32 arbiterClockDivider) |
Initialises the ADC Arbiter clock. More... | |
IFX_EXTERN void | IfxVadc_initialiseAdcConverterClock (Ifx_VADC *vadc, uint32 converterClockDivider) |
Initialises ADC converter clock. More... | |
IFX_EXTERN uint32 | IfxVadc_initializeFAdcD (Ifx_VADC *vadc, uint32 fAdcD) |
Configure the FadcD vadc digital clock. More... | |
IFX_EXTERN uint32 | IfxVadc_initializeFAdcI (Ifx_VADC *vadc, uint32 fAdcI) |
Configure the ADC analog clock. More... | |
IFX_EXTERN void | IfxVadc_resetKernel (Ifx_VADC *vadc) |
Resets the kernel. More... | |
IFX_EXTERN void | IfxVadc_startupCalibration (Ifx_VADC *vadc) |
Starts ADC calibration and wait for the end of the calibration process. More... | |
IFX_INLINE void | IfxVadc_clearChannelRequest (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelId) |
Clears the channel request. More... | |
IFX_INLINE void | IfxVadc_enableFifoMode (Ifx_VADC_G *vadcG, IfxVadc_ChannelResult resultRegister) |
Enables the FIFO mode. More... | |
IFX_INLINE Ifx_VADC_G_CHASS | IfxVadc_getAssignedChannels (Ifx_VADC_G *vadcG) |
Gets the group's assigned channels. More... | |
IFX_INLINE Ifx_VADC_CHCTR | IfxVadc_getChannelControlConfig (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex) |
Gets the current ADC channel control configurations. More... | |
IFX_INLINE IfxVadc_ChannelResolution | IfxVadc_getChannelResolution (Ifx_VADC_G *vadcG, uint8 inputClassNum) |
Gets the ADC input class channel resolution. More... | |
IFX_INLINE float32 | IfxVadc_getChannelSampleTime (Ifx_VADC_G *vadcG, uint8 inputClassNum, float32 analogFrequency) |
Gets the ADC input class channel sample time. More... | |
IFX_INLINE void | IfxVadc_setBackgroundPriorityChannel (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex) |
Sets the channels with low priority as background channel. More... | |
IFX_INLINE void | IfxVadc_setBackgroundResultTarget (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, boolean globalResultUsage) |
Sets the target for result background source. More... | |
IFX_INLINE void | IfxVadc_setBoundaryMode (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_BoundaryExtension boundaryMode) |
Selects boundary extension. More... | |
IFX_INLINE void | IfxVadc_setChannelEventSourceLine (Ifx_VADC_G *vadcG, IfxVadc_SrcNr channelSrcNr, IfxVadc_ChannelId channel) |
Sets the channel event service request line. More... | |
IFX_INLINE void | IfxVadc_setChannelLimitCheckMode (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_LimitCheck limitCheck) |
Sets the channel event mode. More... | |
IFX_INLINE void | IfxVadc_setGroupPriorityChannel (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex) |
Sets channel as priority channel with in the group. More... | |
IFX_INLINE void | IfxVadc_setInputClass (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_InputClasses inputClass) |
Sets the channel input class. More... | |
IFX_INLINE void | IfxVadc_setLowerBoundary (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_BoundarySelection lowerBoundary) |
Sets group's lower boundary. More... | |
IFX_INLINE void | IfxVadc_setReferenceInput (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_ChannelReference reference) |
Selects the refernce input. More... | |
IFX_INLINE void | IfxVadc_setResultNodeEventPointer0 (Ifx_VADC_G *vadcG, IfxVadc_SrcNr resultSrcNr, IfxVadc_ChannelResult resultRegister) |
Sets result event node pointer 0. More... | |
IFX_INLINE void | IfxVadc_setResultNodeEventPointer1 (Ifx_VADC_G *vadcG, IfxVadc_SrcNr resultSrcNr, IfxVadc_ChannelResult resultRegister) |
Sets result event node pointer 1. More... | |
IFX_INLINE void | IfxVadc_setResultPosition (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, boolean rightAlignedStorage) |
Sets result store position. More... | |
IFX_INLINE void | IfxVadc_setSyncRequest (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, boolean synchonize) |
Sets channel synchronization request. More... | |
IFX_INLINE void | IfxVadc_setUpperBoundary (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_BoundarySelection upperBoundary) |
Sets group's upper boundary. More... | |
IFX_INLINE void | IfxVadc_storeGroupResult (Ifx_VADC_G *vadcG, IfxVadc_ChannelId channelIndex, IfxVadc_ChannelResult resultRegister) |
Sets the group result register. More... | |
VADC basic functionality.
IMPORTANT NOTICE
Infineon Technologies AG (Infineon) is supplying this file for use exclusively with Infineon's microcontroller products. This file can be freely distributed within development tools that are supporting such microcontroller products.
THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. INFINEON SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
Definition in file IfxVadc.h.