山东科技大学毕业设计山东科技大学本科毕业设计论文题目基于ARM的GPRS无线数据终端设计学院名称山东科技大学专业班级气工程及其自动化10-4班学生姓名学号201003201414时间:2012年6月5日山东科技大学毕业设计1摘要随着嵌入式系统和GPRS无线网络的发展,GPRS无线数据终端为工业生产中的远距离数据传输带来了更佳的传输途径,摆脱了有线数据传输的局限性,极大地节省了后期维护费用,降低了成本,满足了日益增长的工业需求。GPRS无线数据终端的研究具有广泛的意义和良好的商业前景。本文主要设计并实现基于ARM的GPRS无线数据终端。该系统以ARM7系列微处理器为核心,通过AT指令控制自带有完整TCP/IP协议栈的无线数据模块。结合GPRS通信网络的特点分析无线数据传输嵌入式系统的设计过程,给出系统的具体实现方案,提出硬件、软件系统的设计流程、开发要点和实现过程。本系统经过几个月的设计制作,较好的完成了无线数据终端的各项功能。关键词:GPRS;嵌入式;ARM;AT指令;TCP/IP协议山东科技大学毕业设计2ABSTRACTWiththedevelopmentofembeddedsystemsandGPRSwirelessnetwork,GPRSwirelessdataterminalshasbroughtabetterwayoftransmissionforlong-rangedatatransmissioninindustrialproduction,gettingridofthelimitationsofwireddatatransmission,savingsignificantlyinthelatermaintenancecosts,reducingcostsandmeetingthegrowingindustrialdemand.TheresearchoftheGPRSwirelessdataterminalhasbroadmeaningsandgoodbusinessprospects.ThepapermainlydesignsandimplementstheGPRSwirelessdataterminalbasedonARM.ThesystemdependingonARM7familymicroprocessorcancontrolwirelessdatamodulewithacompleteTCP/IPprotocolstackthroughATcommands.Makeananalysisofthedesignprocessoftheembeddedsystemforwirelessdatatransmission,combinedwithGPRScommunicationnetworkcharacteristicsandgiveaspecificsystemimplementationincluding:thehardwareandsoftwaredesignprocess,developmentpointsandtheimplementationprocess.Thedesigniscompletedforseveralmonths,implementingvariousfunctionsofthewirelessdataterminal.Keywords:GPRS;Embedded;ARM;ATcommand;TCP/IPprotocol山东科技大学毕业设计3目录1绪论................................................................................................11.1研究背景...............................................................................................11.2通讯方式的现状...................................................................................21.3研究具体任务和目的...........................................................................32系统总体方案设计........................................................................52.1系统功能要求.......................................................................................52.2系统组成...............................................................................................52.3系统主要器件选型...............................................................................62.2.1主控器件的选择........................................................................62.2.2无线模块的选择........................................................................82.3软硬件开发工具选择...........................................................................82.4系统语言与模块化结构.......................................................................92.4.1AT指令集...................................................................................92.4.2C语言程序模块化设计...........................................................103硬件电路设计...............................................................................113.1电源电路设计......................................................................................113.1.1电源芯片选择...........................................................................113.1.2电源电路具体设计...................................................................113.2主控外围电路.....................................................................................133.3串口通信电路.....................................................................................143.4电平转换电路和部分指示电路.........................................................163.5无线模块外围电路设计.....................................................................173.5.1无线模块插板电路..................................................................173.5.2SIM卡电路...............................................................................183.6存储模块电路设计.............................................................................194软件程序设计..............................................................................21山东科技大学毕业设计44.1软件总体设计主流程.........................................................................214.2系统初始化.........................................................................................224.2.1系统中断初始化......................................................................224.2.2主频配置..................................................................................234.2.3UART初始化...........................................................................254.2.4定时器初始化..........................................................................264.2.5I2C初始化与铁电存储............................................................274.2.6参数配置初始化设计..............................................................304.3TCP网络连接......................................................................................304.3.1TCP/IP简述..............................................................................304.3.2TCP连接的建立、维护与拆除...............................................304.3.3系统TCP网络连接过程.........................................................324.4数据解析.............................................................................................334.5数据的接收缓存处理.................................................