Xmega Application Note


awex_driver.c

Go to the documentation of this file.
00001 /* This file has been prepared for Doxygen automatic documentation generation.*/
00059 #include "awex_driver.h"
00060 
00073 void AWEX_EnableDeadTimeInsertion( AWEX_t * awex, uint8_t enableMask )
00074 {
00075         /* Make sure only the DTI enable bits are affected. */
00076         enableMask &= ( AWEX_DTICCAEN_bm |
00077                         AWEX_DTICCBEN_bm |
00078                         AWEX_DTICCCEN_bm |
00079                         AWEX_DTICCDEN_bm );
00080 
00081         /* Enable DTI for the selected channels. */
00082         awex->CTRL |= enableMask;
00083 }
00084 
00085 
00098 void AWEX_DisableDeadTimeInsertion(AWEX_t * awex, uint8_t disableMask)
00099 {
00100         /* Make sure only the DTI enable bits are affected. */
00101         disableMask &= ( AWEX_DTICCAEN_bm |
00102                          AWEX_DTICCBEN_bm |
00103                          AWEX_DTICCCEN_bm |
00104                          AWEX_DTICCDEN_bm );
00105 
00106         /* Disable DTI for the selected channels. */
00107         awex->CTRL &= ~disableMask;
00108 }
00109 
00110 
00117 void AWEX_ConfigureFaultDetection( AWEX_t * awex,
00118                                    AWEX_FDACT_t faultAction,
00119                                    uint8_t eventMask)
00120 {
00121         awex->FDCTRL = ( awex->FDCTRL & ~AWEX_FDACT_gm ) | faultAction;
00122         awex->FDEVMASK = eventMask;
00123 }
@DOC_TITLE@
Generated on Wed Apr 23 08:14:07 2008 for AVR1306 Using the Xmega Timer/Counter Extentions by doxygen 1.5.5