在线时间0 小时
UID406786
注册时间2012-12-12
NXP金币0
该用户从未签到
新手上路
- 积分
- 34
- 最后登录
- 1970-1-1
|
发表于 2012-12-14 11:08:02
|
显示全部楼层
回复:【拉普兰德K60底层库】OSKinetis_V2.0(含驱动、29个例程、函数手册)
LPLD:
库函数中ADC的.c和.h
101 void ADC_Config_Alt(ADC_MemMapPtr adcmap, tADC_ConfigPtr ADC_CfgPtr)
102 {
103 ADC_CFG1_REG(adcmap) = ADC_CfgPtr->CONFIG1;
在配置ADC的feature ,ADC_CfgPtr->CONFIG1为结构体中的uint8_t CONFIG1; 寄存器支持:byte enabled registers。
我的问题
ADC_CFG1_REG这个是宏还是函数?在写寄存器吧?这个函数在哪定义的???以及void ADC_Config_Alt函数里的大部分做相同工作的函数都在哪定义的??.h里我没有找到
技术文档里是这么写,我就不翻译了哈。
34.4.5.3 Aborting conversions
Any conversion in progress is aborted when:
• Writing to SC1A register while it is actively controlling a conversion, aborts the
current conversion. In software trigger mode (ADTRG=0), a write to SC1A register
initiates a new conversion (if the ADCH field in SC1A is equal to a value other than
all 1s). Writing to any of the SC1(B-n) registers while that specific SC1(B-n) register
is actively controlling a conversion aborts the current conversion.The SC1(B-n)
registers are not used for software trigger operation and therefore writes to the
SC1(B-n) registers do not initiate a new conversion.
• A write to any ADC register besides the SC1A:SC1n registers occurs. This indicates
a mode of operation change has occurred and the current conversion is therefore
invalid.
• The MCU is reset or enters Low Power Stop modes.
• The MCU enters Normal Stop mode with ADACK not enabled.
When a conversion is aborted, the contents of the data registers, Rn, are not altered. The
data registers continue to be the values transferred after the completion of the last
successful conversion. If the conversion was aborted by a reset or Low Power Stop
modes, RA and R n return to their reset states.
.
|
|