kinetis gpio irq step by step 201203a

kinetis gpio irq step by step 201203a

ID:5317378

大小:3.89 MB

页数:35页

时间:2017-11-23

kinetis gpio irq step by step 201203a_第1页
kinetis gpio irq step by step 201203a_第2页
kinetis gpio irq step by step 201203a_第3页
kinetis gpio irq step by step 201203a_第4页
kinetis gpio irq step by step 201203a_第5页
资源描述:

《kinetis gpio irq step by step 201203a》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库

1、FreescaleKinetisK10GPIOIRQ StepbyStep清华Freescale应用开发研究中心薛涛2012年3月Page2KinetisK10TrainingPage3KinetisK10TrainingWhatweused?Reference:DDI0403D_arm_architecture_v7m_reference_manual_errata_markup_1_0.pdfDDI0439B_cortex_m4_r0p0_trm.pdfK10P100M100SF2RM.pdfKQRUG.pdfK10P100M100SF2.pdfAN4445.pd

2、fRevision:Page4KinetisK10TrainingK10boardPage5KinetisK10TrainingK10board电源直流5V100mA调试用串口UART0备用串口UART2Page6KinetisK10TrainingK10boardDebug&ResetbuttonJTAG复位按钮Page7KinetisK10TrainingK10boardLedsLEDsPage8KinetisK10TrainingK10boardPower&ResetPage9KinetisK10TrainingK10boardRS232&JTAGPage10K

3、inetisK10TrainingK10boardCLOCK32768Page11KinetisK10TrainingK10boardCLOCK4MHzPage12KinetisK10TrainingK10boardPowerSupplyPage13KinetisK10TrainingK10LEDsPage14KinetisK10TrainingK10GPIOIRQstepbystepStep1:SIMenablecorrespondGPIOportclockStep2:PCRenablecorrespondGPIOportALT1functionasGPIOIRQf

4、unction,enableIRQStep3:WritetheISRStep4:SendakeytogenerateIRQthroughRS232portPage15KinetisK10TrainingK10ClockpreviousMCG/SIM/OSC20MHzPage16KinetisK10TrainingK10SIMPage17KinetisK10TrainingK10SIMCCode/*Turnonallportclocks*/SIM_SCGC5

5、=SIM_SCGC5_PORTD_MASK;Page18KinetisK10TrainingK10SIMPage

6、19KinetisK10TrainingK10SIMPage20KinetisK10TrainingK10GPIOConfigureControlMode:PORTx_PCRnPinControlRegisterPORTx_GPCLRGlobalPinControlLowRegisterPORTx_GPCHRGlobalPinControlHighRegisterPORTx_ISFRInterruptStatusFlagRegisterPORTx_DFERDigitalFilterEnableRegisterPORTx_DFCRDigitalFilterClockRe

7、gisterPORTx_DFWRDigitalFilterWidthRegisterPage21KinetisK10TrainingK10GPIOPCRInterruptStatusFlagInterruptConfiguration0000Interrupt/DMARequestdisabled.0001DMARequestonrisingedge.0010DMARequestonfallingedge.0011DMARequestoneitheredge.0100Reserved.1000Interruptwhenlogiczero.1001Interrupton

8、risingedge.1010Interruptonfallingedge.1011Interruptoneitheredge.1100Interruptwhenlogicone.DriveStrengthEnableOpenDrainEnablePassiveFilterEnableSlowRateEnablePullEnablePullSelectPullUpPullDownDetailinPage239ofK10P100M100SF2RM.pdf100Page22KinetisK10TrainingK10GPIOPCRPinMuxControl

当前文档最多预览五页,下载文档查看全文

此文档下载收益归作者所有

当前文档最多预览五页,下载文档查看全文
温馨提示:
1. 部分包含数学公式或PPT动画的文件,查看预览时可能会显示错乱或异常,文件下载后无此问题,请放心下载。
2. 本文档由用户上传,版权归属用户,天天文库负责整理代发布。如果您对本文档版权有争议请及时联系客服。
3. 下载前请仔细阅读文档内容,确认文档内容符合您的需求后进行下载,若出现内容与标题不符可向本站投诉处理。
4. 下载文档时可能由于网络波动等原因无法下载或下载错误,付费完成后未能成功下载的用户请联系客服处理。