资源描述:
《基于stm32的嵌入式操作系统程序设计及实现—毕业设计》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、摘要随着科学技术不断的进步,工业生产越来越先进复杂,操作系统µC/OS-II是高效、稳定、可靠、节能的系统,广泛应用安防,消费电子中。而基于Cortex-M3架构下的STM32是一款性价比优越新型微处理器,将µC/OS-II移植到STM32上能够发挥其高效的性能,从而投入社会生产,制造出很多有用又实惠的电子产品,为我们的生活带来便利。本文主要的研究内容是µC/OS-II操作系统理论分析、移植方法、应用程序设计及调试仿真实现。首先,对µC/OS-II的理论分析,研究其实际应用及系统结构;其次,分析STM32硬件平台及µC/OS
2、-II的移植需求;最后,在µC/OS-II上开发LCD,LED,按键KEY等应用程序,并对多任务系统调试分析。主要研究结论如下:(1)µC/OS-II操作系统主要分为任务管理、内存管理和时间管理三大部分,其间通信是通过消息队列和消邮箱。(2)µC/OS-II移植主要在OS_CPU.H,OS_CPU_C.C,OS_CPU_A.ASM三个文件中,涉及到数据类型、堆栈、中断定义和任务切换等。(3)应用程序设计优先级分配要合理,硬件平台初始化模块化处理。关键词:嵌入式系统;µC/OS-II;移植-39-AbstractWiththe
3、progressofscienceandtechnologyconstantly,advancedindustrialproductiontomorecomplex,theoperatingsystemµC/OS-IIisefficient,stable,reliable,energysavingsystem,widelyusedinthesecurity,andconsumerelectronics.AndbasedontheSTM32architectureCortex-M3frameworkisasuperiorcos
4、t-effectivenewmicroprocessor,µC/OS-IItransplantationtoSTM32canplayitsefficientperformance,thusinsocialproductionandcreatealotofusefulandaffordableelectronicproduct,bringconveniencetoourlives.ThisarticlemainresearchcontentisµC/OS-IIoperatingsystemtheoryanalysis,meth
5、odoftransplantation,applicationdesignanddebuggingofthesimulationimplementation.Firstofall,thetheoreticalanalysisofµC/OS-II,researchtheactualapplicationandsystemstructure;Second,analysisofSTM32hardwareplatformandthedemandµC/OS-IItransplantation.Finally,ontheµC/OS-II
6、developmentofLCD,LED,buttonKEYapplications,andanalysisofmultitaskingsystemdebugging.Mainresearchconclusionisasfollows:(1)µC/OS-IIoperatingsystemconsistsofthreemajortaskmanagement,memorymanagementandtimemanagement,inwhichcommunicationisthroughthemessagequeueandemail
7、.(2)µC/OS-IItransplantationmainlyinOS_CPU_C.C,OS_CPU_A.ASMfile,OS_CPU.H,threeinvolvesthedatatypedefinitionandtaskswitchingetc,stack,interrupt.(3)Theapplicationdesigntotheallocationofpriorities,initializethemodularprocessinghardwareplatform.Keywords:embeddedsystem;µ
8、C/OS-II;transplant-39-目录1概述11.1研究的目的及意义11.2国内外研究状况综述11.3研究的主要内容22ΜC/OS-II的理论介绍32.1µC/OS-II各模块的基本功能32.2STM32上移植方法73LCD屏程序设计及调试123.1工具概述123.2硬件结构13