uc-sdk
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
lpc17xx_dac.h File Reference

Contains all macro definitions and function prototypes support for DAC firmware library on LPC17xx. More...

#include "LPC17xx.h"
#include "lpc_types.h"

Go to the source code of this file.

Classes

struct  DAC_CONVERTER_CFG_Type
 Configuration for DAC converter control register. More...
 

Macros

#define DAC_VALUE(n)   ((uint32_t)((n&0x3FF)<<6))
 
#define DAC_BIAS_EN   ((uint32_t)(1<<16))
 
#define DAC_CCNT_VALUE(n)   ((uint32_t)(n&0xffff))
 
#define DAC_DBLBUF_ENA   ((uint32_t)(1<<1))
 
#define DAC_CNT_ENA   ((uint32_t)(1<<2))
 
#define DAC_DMA_ENA   ((uint32_t)(1<<3))
 
#define DAC_DACCTRL_MASK   ((uint32_t)(0x0F))
 
#define PARAM_DACx(n)   (((uint32_t *)n)==((uint32_t *)LPC_DAC))
 
#define PARAM_DAC_CURRENT_OPT(OPTION)
 

Enumerations

enum  DAC_CURRENT_OPT { DAC_MAX_CURRENT_700uA = 0, DAC_MAX_CURRENT_350uA }
 Current option in DAC configuration option. More...
 

Functions

void DAC_Init (LPC_DAC_TypeDef *DACx)
 
void DAC_UpdateValue (LPC_DAC_TypeDef *DACx, uint32_t dac_value)
 
void DAC_SetBias (LPC_DAC_TypeDef *DACx, uint32_t bias)
 
void DAC_ConfigDAConverterControl (LPC_DAC_TypeDef *DACx, DAC_CONVERTER_CFG_Type *DAC_ConverterConfigStruct)
 
void DAC_SetDMATimeOut (LPC_DAC_TypeDef *DACx, uint32_t time_out)
 

Detailed Description

Contains all macro definitions and function prototypes support for DAC firmware library on LPC17xx.

Version
3.0
Date
18. June. 2010
Author
NXP MCU SW Application Team

Software that is described herein is for illustrative purposes only which provides customers with programming information regarding the products. This software is supplied "AS IS" without any warranties. NXP Semiconductors assumes no responsibility or liability for the use of the software, conveys no license or title under any patent, copyright, or mask work right to the product. NXP Semiconductors reserves the right to make changes in the software without notification. NXP Semiconductors also make no representation or warranty that such application will be suitable for the specified use without further testing or modification.

Definition in file lpc17xx_dac.h.