C:/nxpdrv/LPC1700CMSIS/Drivers/source/lpc17xx_qei.c File Reference
: Contains all functions support for QEI firmware library on LPC17xx More...
#include "lpc17xx_qei.h"
#include "lpc17xx_clkpwr.h"
#include "lpc17xx_libcfg_default.h"
Go to the source code of this file.
Data Structures | |
| union | QEI_CFGOPT_Type |
| QEI configuration union type definition. More... | |
Functions | |
| void | QEI_Reset (LPC_QEI_TypeDef *QEIx, uint32_t ulResetType) |
| Resets value for each type of QEI value, such as velocity, counter, position, etc.. | |
| void | QEI_Init (LPC_QEI_TypeDef *QEIx, QEI_CFG_Type *QEI_ConfigStruct) |
| Initializes the QEI peripheral according to the specified parameters in the QEI_ConfigStruct. | |
| void | QEI_DeInit (LPC_QEI_TypeDef *QEIx) |
| De-initializes the QEI peripheral registers to their default reset values. | |
| void | QEI_ConfigStructInit (QEI_CFG_Type *QIE_InitStruct) |
Fills each QIE_InitStruct member with its default value:
| |
| FlagStatus | QEI_GetStatus (LPC_QEI_TypeDef *QEIx, uint32_t ulFlagType) |
| Check whether if specified flag status is set or not. | |
| uint32_t | QEI_GetPosition (LPC_QEI_TypeDef *QEIx) |
| Get current position value in QEI peripheral. | |
| void | QEI_SetMaxPosition (LPC_QEI_TypeDef *QEIx, uint32_t ulMaxPos) |
| Set max position value for QEI peripheral. | |
| void | QEI_SetPositionComp (LPC_QEI_TypeDef *QEIx, uint8_t bPosCompCh, uint32_t ulPosComp) |
| Set position compare value for QEI peripheral. | |
| uint32_t | QEI_GetIndex (LPC_QEI_TypeDef *QEIx) |
| Get current index counter of QEI peripheral. | |
| void | QEI_SetIndexComp (LPC_QEI_TypeDef *QEIx, uint32_t ulIndexComp) |
| Set value for index compare in QEI peripheral. | |
| void | QEI_SetTimerReload (LPC_QEI_TypeDef *QEIx, QEI_RELOADCFG_Type *QEIReloadStruct) |
| Set timer reload value for QEI peripheral. When the velocity timer is over-flow, the value that set for Timer Reload register will be loaded into the velocity timer for next period. The calculated velocity in RPM therefore will be affect by this value. | |
| uint32_t | QEI_GetTimer (LPC_QEI_TypeDef *QEIx) |
| Get current timer counter in QEI peripheral. | |
| uint32_t | QEI_GetVelocity (LPC_QEI_TypeDef *QEIx) |
| Get current velocity pulse counter in current time period. | |
| uint32_t | QEI_GetVelocityCap (LPC_QEI_TypeDef *QEIx) |
| Get the most recently measured velocity of the QEI. When the Velocity timer in QEI is over-flow, the current velocity value will be loaded into Velocity Capture register. | |
| void | QEI_SetVelocityComp (LPC_QEI_TypeDef *QEIx, uint32_t ulVelComp) |
| Set Velocity Compare value for QEI peripheral. | |
| void | QEI_SetDigiFilter (LPC_QEI_TypeDef *QEIx, uint32_t ulSamplingPulse) |
| Set value of sampling count for the digital filter in QEI peripheral. | |
| FlagStatus | QEI_GetIntStatus (LPC_QEI_TypeDef *QEIx, uint32_t ulIntType) |
| Check whether if specified interrupt flag status in QEI peripheral is set or not. | |
| void | QEI_IntCmd (LPC_QEI_TypeDef *QEIx, uint32_t ulIntType, FunctionalState NewState) |
| Enable/Disable specified interrupt in QEI peripheral. | |
| void | QEI_IntSet (LPC_QEI_TypeDef *QEIx, uint32_t ulIntType) |
| Sets (forces) specified interrupt in QEI peripheral. | |
| void | QEI_IntClear (LPC_QEI_TypeDef *QEIx, uint32_t ulIntType) |
| Clear (force) specified interrupt (pending) in QEI peripheral. | |
| uint32_t | QEI_CalculateRPM (LPC_QEI_TypeDef *QEIx, uint32_t ulVelCapValue, uint32_t ulPPR) |
| Calculates the actual velocity in RPM passed via velocity capture value and Pulse Per Round (of the encoder) value parameter input. | |
Detailed Description
: Contains all functions support for QEI firmware library on LPC17xx
- Version:
- : 1.0
- Date:
- : 26. May. 2009
- Author:
- : HieuNguyen
Definition in file lpc17xx_qei.c.
Generated on Mon Feb 8 10:01:42 2010 for LPC1700CMSIS Standard Peripheral Firmware Library by
1.5.9