資源簡(jiǎn)介
c8051f350 24位AD 轉(zhuǎn)換程序 完全調(diào)通的很實(shí)用

代碼片段和文件信息
//-----------------------------------------------------------------------------
//?F35x_ADC0_Buffered.c
//-----------------------------------------------------------------------------
//?Copyright?2004?Silicon?Laboratories?Inc.
//
//?AUTH:?BD?/?PC?/?BW
//?LMOD:?BW?15?JUL?2004
//?DATE:?06?APR?2004
//
//?This?program?demonstrates?taking?measurements?using?the?24-bit?ADC?on?the
//?C8051F350/51?devices.
//
//?Input?pin?configuration?shown?in?ADC0_Init().
//
//?For?a?Noise?measurement?connect?AIN0?and?AIN1?to?AGND?at?the?terminal
//?block.??Set?“USE_FLOAT“?to?‘1‘?“PRINT_STATISTICS“?to?‘1‘
//?“PRINT_SAMPLES“?to?‘0‘?and?“PRINT_VOLTAGES“?to?‘0‘.
//
//?This?software?configures?the?ADC?to?use?an?external?VREF.??Therefore
//?on?the?‘F350?target?board?J13?and?J14?should?have?their?shorting?blocks
//?installed.
//
//?The?standard?deviation?(Sigma)?of?a?sample?set?is?equivalent?to?the
//?effective?RMS?noise?of?the?conversion?system.??“Sigma“?when?converted
//?to?Volts?is?equivalent?to?the?input-referred?noise?floor?of?the
//?sampling?system.
//
//?Typical?values?of?Sigma?from?the?C8051F350?rev?B?target?board?with
//?AIN0?and?AIN1?grounded?at?the?terminal?block?are?around?9?to?11?LSBs
//?in?bipolar?mode.??For?a?DC?measurement?this?is?equivalent?to?a?Signal-
//?to-Noise?ratio?of?about?117dB?or?about?20?bits?of?effective?dynamic
//?range.
//
//?117dB?=?20?log10?(?11?/?2^23)
//?20?bits?=?117dB?/?6dB/bit
//
//?Another?parameter?of?note?for?integrating?converters?is?the?number?of
//?Noise-Free?bits.??For?a?Gaussian-distributed?noise?floor?this?number
//?can?be?obtained?by?multiplying?Sigma?by?6?evaluating?the?number?of
//?bits?required?to?contain?the?result?and?subtracting?this?number?of
//?bits?from?the?24?available?bits?as?follows:
//
//?10?LSBs?*?6?=?60?LSBs?which?can?be?contained?in?6?bits.??Noise-free
//?resolution?is?24bits?-?6?bits?=?18?bits.
//
//?Refer?to?‘F350?datasheet?tables?“ADC0?Electrical?Characteristics“?and
//?“Absolute?Maximum?Ratings“?for?the?MIN/MAX?voltage?range?on?input?pins.
//
//?If?using?the?eval?version?of?the?Keil?compiler?set?“USE_FLOAT“?to?‘0‘
//?and?calculate?the?standard?deviation?by?taking?the?square?root
//?of?“variance“.
//
//?Target:?C8051F35x
//
//?Tool?chain:?KEIL?C51
//
//?v1.0?PC?26?MAY?2004
//?Initial?Revision?(Adapted?from?‘F350?Temp?Sensor?Demo)
//
//?set?USE_FLOAT?to?‘0‘?to?use?EVAL?version?of?Keil?compiler
#define?USE_FLOAT?1
#define?PRINT_STATISTICS?1
#define?PRINT_SAMPLES?0
#define?PRINT_VOLTAGES?0
//-----------------------------------------------------------------------------
//?Includes
//-----------------------------------------------------------------------------
#include?????????????????????//?SFR?declarations
#include?????????????????????????//?Standard?I/O?Library
#include?
//-----------------------------------------------------------------------------
//?16-bit?SFR?Definitions?for?‘F35x
/
?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????文件??????18304??2008-07-22?09:55??ADC\F35x_ADC0_Buffered.c
?????文件??????12595??2008-07-22?09:55??ADC\F35x_ADC0_ExternalInput.c
?????目錄??????????0??2009-06-17?14:12??ADC
-----------?---------??----------?-----??----
????????????????30899????????????????????3
評(píng)論
共有 條評(píng)論