-
大小: 1.6MB文件類型: .rar金幣: 2下載: 0 次發布日期: 2023-09-27
- 語言: 其他
- 標簽: STM32F030F4P??輸入捕獲??采集頻率??STM32??
資源簡介
使用STM32F030F4P6定時器14通道1輸入捕獲計算頻率,基于庫函數版本的開發。實測1-1000HZ采集誤差小于1%。

代碼片段和文件信息
/**
??******************************************************************************
??*?@file????stm32f0xx_adc.c
??*?@author??MCD?Application?Team
??*?@version?V1.0.0
??*?@date????23-March-2012
??*?@brief???This?file?provides?firmware?functions?to?manage?the?following?
??*??????????functionalities?of?the?Analog?to?Digital?Convertor?(ADC)?peripheral:
??*???????????+?Initialization?and?Configuration
??*???????????+?Power?saving
??*???????????+?Analog?Watchdog?configuration
??*???????????+?Temperature?Sensor?Vrefint?(Internal?Reference?Voltage)?and?
??*?????????????Vbat?(Voltage?battery)?management?
??*???????????+?ADC?Channels?Configuration
??*???????????+?ADC?Channels?DMA?Configuration
??*???????????+?Interrupts?and?flags?management
??*
??*??@verbatim
================================================================================
??????????????????????#####?How?to?use?this?driver?#####
================================================================================
????[..]
????(#)?Enable?the?ADC?interface?clock?using?
????????RCC_APB2PeriphClockCmd(RCC_APB2Periph_ADC1?ENABLE);?
????(#)?ADC?pins?configuration
???????(++)?Enable?the?clock?for?the?ADC?GPIOs?using?the?following?function:
????????????RCC_AHBPeriphClockCmd(RCC_AHBPeriph_GPIOx?ENABLE);???
???????(++)?Configure?these?ADC?pins?in?analog?mode?using?GPIO_Init();??
????(#)?Configure?the?ADC?conversion?resolution?data?alignment?external
????????trigger?and?edge?scan?direction?and?Enable/Disable?the?continuous?mode
????????using?the?ADC_Init()?function.
????(#)?Activate?the?ADC?peripheral?using?ADC_Cmd()?function.
????***?ADC?channels?group?configuration?***
????============================================
????[..]?
????(+)?To?configure?the?ADC?channels?features?use?ADC_Init()?and?
????????ADC_ChannelConfig()?functions.
????(+)?To?activate?the?continuous?mode?use?the?ADC_ContinuousModeCmd()
????????function.
????(+)?To?activate?the?Discontinuous?mode?use?the?ADC_DiscModeCmd()?functions.?
????(+)?To?activate?the?overrun?mode?use?the?ADC_OverrunModeCmd()?functions.
????(+)?To?activate?the?calibration?mode?use?the?ADC_GetCalibrationFactor()?functions.
????(+)?To?read?the?ADC?converted?values?use?the?ADC_GetConversionValue()
????????function.
????***?DMA?for?ADC?channels?features?configuration?***
????=============================================================
????[..]?
????(+)?To?enable?the?DMA?mode?for?ADC?channels?group?use?the?ADC_DMACmd()?function.
????(+)?To?configure?the?DMA?transfer?request?use?ADC_DMARequestModeConfig()?function.
??*??@endverbatim
??*
??******************************************************************************
??*?@attention
??*
??*?©?COPYRIGHT?2012?STMicroelectronics
??*
??*?Licensed?under?MCD-ST?Liberty?SW?License?Agreement?V2?(the?“License“);
??*?You?may?not?use?this?file?except?in?compliance?with?the?License.
??*?You?may?obtain?a?copy?of?the?License?at
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件?????344064??2018-10-31?14:55??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.IAB
?????文件???????3688??2018-10-31?14:55??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.IAD
?????文件??????90112??2018-10-24?18:25??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.IMB
?????文件???????1208??2018-10-24?18:25??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.IMD
?????文件????????100??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.PFI
?????文件????????776??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.PO
?????文件???????8312??2018-10-24?18:31??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.PR
?????文件??????51112??2018-10-24?18:32??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.PRI
?????文件?????638804??2018-10-31?15:07??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.PS
?????文件????????425??2018-10-31?14:48??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.SearchResults
?????文件??????48722??2018-10-31?16:43??STM32F030F4P6輸入捕獲計算頻率\CAR_CHECK.WK3
?????文件???????1120??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\arm_common_tables.h
?????文件?????240326??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\arm_math.h
?????文件??????31948??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\core_cm0.h
?????文件??????15691??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\core_cmFunc.h
?????文件??????16108??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\core_cmInstr.h
?????文件??????10646??2012-03-23?19:36??STM32F030F4P6輸入捕獲計算頻率\CORE\startup_stm32f0xx.s
?????文件?????218627??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\ant_control.crf
?????文件???????1743??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\ant_control.d
?????文件?????250432??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\ant_control.o
?????文件??????17872??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\common.crf
?????文件????????179??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\common.d
?????文件??????61032??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\common.o
?????文件?????????19??2018-10-31?16:43??STM32F030F4P6輸入捕獲計算頻率\OBJ\ExtDll.iex
?????文件?????260404??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\led.axf
?????文件???????1444??2018-10-31?16:42??STM32F030F4P6輸入捕獲計算頻率\OBJ\led.build_log.htm
?????文件??????11203??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\led.hex
?????文件??????44059??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\led.htm
?????文件????????633??2018-10-31?16:41??STM32F030F4P6輸入捕獲計算頻率\OBJ\led.lnp
?????文件??????23029??2018-10-31?16:42??STM32F030F4P6輸入捕獲計算頻率\OBJ\led_LED.dep
............此處省略108個文件信息
評論
共有 條評論