基于MSP430F149单片机毕业论中英文对照资料外文翻译文献_第1页
基于MSP430F149单片机毕业论中英文对照资料外文翻译文献_第2页
基于MSP430F149单片机毕业论中英文对照资料外文翻译文献_第3页
基于MSP430F149单片机毕业论中英文对照资料外文翻译文献_第4页
基于MSP430F149单片机毕业论中英文对照资料外文翻译文献_第5页
已阅读5页,还剩21页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、毕业设计外文资料翻译基于 MSP430F149 单片机的最小系统设计及其应用摘 要 : 单片机最小系统, 或称为最小应用系统, 是指用最少的元件组成的单片机可以工 作的系统。对于MSP430系列单片机来说,最小系统一般包括:单片机,电源模块,晶振模 块,复位电路模块, JTAG接口电路。本文介绍了MSP430F149单片机的特点及基于 MSP430F149单片机的最小系统设计及其应用,并介绍了各模块的组成及功能。包括数码管 显示模块, LED灯显示模块, LCD液晶显示模块, 8位独立键盘等电路模块及扩展应用。该最 小系统可进行在线下载, 仿真和调试,经实验证明原理正确可靠, 可以广泛应用于教

2、学,科 研和电子设计领域。通过加载相应模块可以制作成实用的产品,具有很大的实用性。关键词 MSP430;最小系统;电路设计;仿真;调试随着现代电子技术和计算机技术的飞速发展,单片机技术已经渗透到人类生活的各个方 面, 在自动化装置、智能化仪器仪表、过程控制和家用电器等许多领域得到日益广泛的应用, 单片机家族也越来越庞大,品种越来越多,且在技术上各有特色, 美国德州仪器公司(TI公 司)新推出的MSP430F149单片机功耗低, 功能强大, 为广大硬件设计师所青睐。单片机芯 片配以必要的外部器件, 一般包括电源供入及电源开关、 复位电路、晶振、输入输出电路等 就能构成最小系统,结构简单。 MSP

3、430F149芯片有60KB+256字节FLASH, 2KBRAM,包 括基本时钟模块、 看门狗定时器、 带3个捕获/比较寄存器和PWM输出的16位定时器、 带7个捕 获/比较寄存器和PWM输出的16位定时器、2个具有中断功能的8位并行端口、4个8位并行端口、 模拟比较器、12位A/D转换器、2个串行通信接口等模块。MSP430F149芯片具有如下特点:(1) 功耗低: 电压2.2V、时钟频率1MHz时, 活动模式芯片电流为200A,关闭模式时电流仅为0.1A; (2)高效16位RISC-CPU,27条指令, 8MHz时钟频率时,指令周期时间为125ns,绝大多数 指令在一个时钟周期完成;(3

4、)低电压供电、宽工作电压范围: 1.83.6V;(4)灵活的 时钟系统:两个外部时钟和一个内部时钟; (5)低时钟频率可实现高速通信; (6)具有串行在线编程能力;(7)强大的中断功能;(8)唤醒时间短,从低功耗模式下唤醒仅需6;s2(9) ESD保护,抗干扰力强;(10)运行环境温度范围为-40+85,适合于工业环境。 MSP430系列单片机的所有外围模块的控制都是通过特殊寄存器来实现的,故其程序的编写 相对简单。编程开发时通过专用的编程器,可以选择汇编或C语言编程, IAR公司为MSP430 系列的单片机开发了专用的C430语言,可以通过WORKBENCH和C-SPY直接编译调试,使 用灵

5、活简单。1 最小系统系统设计最小系统是由保证处理器可靠工作所必须的基本电路组成的, 主要包括电源模 块、晶振模块、复位电路模块、 JTAG接口电路、显示模块等组成1.1 电源模块本系统需要使用+5V和+3.3V的直流稳压电源,其中MSP430Fl49及部分外围器 件需要+3.3V电源,另外部分需要+5V电源。在本系统中,以+5V直流电压为输入 电压, +3.3V由+5V直接线性降压。1.2 晶振模块MSP430系列单片机时钟模块包括数控振荡器(DCO)、高速晶体振荡器和低 速晶体振荡器等3个时钟源。这是为了解决系统的快速处理数据要求和低功耗要 求的矛盾, 通过设计多个时钟源或为时钟设计各种不同

6、工作模式, 才能解决某些 外围部件实时应用的时钟要求,如低频通信、 LCD显示、定时器、计数器等。数 字控制振荡器DCO已经集成在MSP430内部,在系统中只需设计高速晶体振荡器 和低速晶体振荡器两部分电路。低速晶体振荡器( L F X T l ) 满足了低功耗及使用32.768kHz晶振的要求。 LFXTl振荡器默认工作在低频模式,即32.768kHz,也可以通过外接450kHz 8MHz的高速晶体振荡器或陶瓷谐振器工作在高频模式,在本系统中使用低频模 式,晶振外接2个33pF的电容经过XIN和XOUT连接到MCU。高速晶振也称为第二振荡器XT2,它为MSP430F149工作在高频模式时提供

7、时钟, XT2最高可达8MHz。在系统中XT2采用4MHz的晶体, XT2外接2个33pF的电容经过 XT2IN和XT2OUT连接到MCU。31.3 复位电路模块手动复位是最小系统常用的功能, 本系统采用按键开关和RC组合电路实现手动 复位,电路结构简单。1.4 JTAG 接口电路JTAG技术是一种嵌入式调试技术, 芯片内部封装了专门的测试电路TAP(测试 访问口),通过专用的JTAG测试工具对内部节点进行测试和控制,目前大多数 ARM器件支持JTAG协议,标准JTAG接口是4线; TMS (测试模式选择)、 TCK(测 试时钟)、 TDI (测试数据串行输入)、 TDO (测试数据串行输出)

8、。 JTAG接 口的连接有两种标准,即14针JTAG接口与MC9328MX1连接电路。这里使用的是 由74HC244D三态输出的八路缓冲器组成的14针JTAG接口电路。2 基于最小系统应用电路设计2.1 数码管显示模块位数码管显示需要74HC164驱动, 74HC164是串行输入,并行输出的。它的并 行输出其实是有延时的, 只是延时时间小, 可以认为是并行输出。 这里用的是串 口的方式0,方式0是和移位寄存器通讯的。此时TXD、RXD不是像别的方式那 样一个发送,一个接收,而是RXD既可输出也可输入, TXD作移位脉冲。收发数据 必须是8位,比特率固定是晶振的1/12。当设置方式0后,它就自动

9、把TXD作移位 脉冲了。在TXD高电平时检测RXD,若是高电平, 74HC164就读进1,若是低电平, 就读进0。接收的过程:先给REN置1,然后TXD置1,读RXD状态,高电平就接收1,低电平 接收0;然后拉低TXD,略微延时后TXD再置高,读RXD,高电平就接收1,低 电平接收0,以此类推。直到读完8个位。然后RI变高。发送过程:给SBUF写进一 个数,就自动发送。发送1时RXD先变高, TXD再变高;然后TXD变低,发送0时RXD 先变低, TXD再变高;然后TXD变低,以此类推。上述过程都是自动完成的,不用 专门编程。数码管从正面看,小数点在右下脚,上面的引脚从左向右分别是F、G公共端

10、A、B 下面的引脚从左向右分别是E、D公共端 C、Dp(小数点)。42.2 LED 显示模块从I/O口接几个LED,通过编程一个简单的程序,可实现LED灯闪烁,从而达到检验电路及芯片是否正常。2.3 D/A 转换模块MSP430F149单片机自带12位A/D转换器,但没有D/A转换,需要外接D/A转换电 路。 因此选用DAC0832数模转换芯片, 及UA741高增益运算通用放大器组成的数模 转换电路。 UA741芯片引脚如图所示。DAC0832是8分辨率的D/A转换集成芯片。与微处理器完全兼容。这个DA芯片 以其价格低廉、 接口简单、 转换控制容易等优点, 在单片机应用系统中得到广泛 的应用。

11、 D/A转换器由8位输入锁存器、 8位DAC寄存器、 8位D/A转换电路及转换 控制电路构成。DAC0832是采样频率为八位的D/A转换芯片,集成电路内有两级输入寄存器, 使DAC0832芯片具备双缓冲、单缓冲和直通三种输入方式,以便适于各种电路 的需要(如要求多路D/A异步输入、同步转换等)。这8位D/A转换器有8个输入端(其 中每个输入端是8位二进制数的一位),有一个模拟输出端。输入可有28=256个 不同的二进制组态,输出为256个电压之一,即输出电压不是整个电压范围内任 意值,而只能是256个可能值。2.4 LCD 显示模块A/D转换输出数据, 需要用LCD显示。 控制器内部带有80&

12、#215;8位(80字节) 的RAM 缓冲区。52.5 八位独立式键盘模块键盘在单片机应用系统中, 实现输入数据、 传送命令的功能, 是人工干预的主 要手段。键盘有编码键盘和非编码键盘,独立式按键结构,矩阵式按键结构。几 种方式各有千秋,这里我们使用的是8位独立式键盘。编码键盘的键输入程序完 成三个基本任务:首先,监测有无键按下,键的闭合与否,反映在电压上就是呈 现出高电平或低电平, 所以通过电平的高低状态的检测, 便可确认按键按下与否。 其次,判断是哪个键按下。最后,完成键处理任务。其中软件编程使用的是中断 扫描方式。键盘电路中使用的74HC2是一个高速Si-gate CMOS1集成芯片,其

13、引脚低功耗 兼容。属于肖特基TTL (输入通道)。该74HC21提供4-input与功能。2.6 软件设计使用IAR Embedded Workbench Evaluation for MSP4305.10.1软件编程,基本思 想:把LED灯,数码管作为主程序, 7号键作为中断, LCD用来进入中断和A/D 转化后输出显示输出。2.7 扩展应用通过扩展口可以方便单片机与外围模块相连, 充分利用芯片引脚资源, 真正发 挥MSP430单片机强大的功能。在扩展口上加载其他模块,通过调试、测试,可 以生产出相应产品投放市场,实用性强,市场前景广阔。譬如,在最小系统上加 载一个压力传感器,再通过编程、下

14、载就可以做成电子秤,由于系统的功耗低, 可以做成便携式, 给人们的生活带来很大的方便; 在最小系统的基础上加载一个 高精度的超声波测距模块,同样,通过编程、下载就可以做成电子尺,从而取代 传统的卷尺,可以弥补卷尺的一些缺点;如果加上扬声器,编程下载,把整个系 统封装成模块, 可以应用到汽车上, 当车在行驶过程中车距小于某一距离时, 通 过发声提醒驾驶员请保持车距等其他相关应用。3 结束语最小系统可以直接作为核心部件应用于工程和科研中, 具有良好的通用性和可 扩展性。 在最小系统的基础上, 可以很方便地进行二次开发和功能扩展, 能够缩 短开发周期, 降低开发成本。 本文实现了最小系统的基本功能,

15、 介绍了各模块的硬件电路。并在此基础上搭建了简单的应用平台。该最小系统可以作为学习、 实 6践教学实验板用。也可经过适当修、计算机教学与科研、工业控制等领域,还可 以通过加载相应模块,改装成实用的产品,投入市场。Based on MSP430F149 SCM smallest system designand applicationAbstract:Single chip microcomputer minimum system, or the minimum application system, refers to the element with the least amount of

16、single-chip microcomputer system can work. For the single chip MSP430 series Machine, the smallest system generally includes: single chip microcomputer, the power supply module, crystal vibration module, reset circuit module, JTAG interface circuit. This paper introduces the MSP430F149 single the ch

17、aracteristics of the machine and the minimum system based on MSP430F149 MCU design and its application, and introduces thecomposition and function of each module. Include digital tube display module, TheLED display module, LCD liquid crystal display module, eight independent keyboard and other circu

18、it module and extended application. The minimum system can download, online simulation and debugging, Proved by the experiment principle of correct and reliable, and can be widely used in teaching, scientific research and electronic design field. By loading the corresponding modules can be made into

19、 useful products, has the very great practicality.7Keywords: MSP430; smallest system; circuit design; simulation; testBased on MSP430F149 SCM smallest system designand applicationIntroductionWith the rapid development of modern electronic technology and computertechnology, microcontroller technology

20、 has penetrated into every aspect of human life, in automation, intelligent instrumentation, process control and increasing use of household appliances and many other fields, microcontroller family is becoming moreand more big, more and more varieties, and in technology have distinguishing feature e

21、ach, Texas instruments (TI) new MSP430F149 Single-chip low power consumption, powerful, for the majority of hardware designers.8Single-chip microcomputer with necessary external device, generally including power supply into the power switch, reset circuit, crystals, input and output circuit can cons

22、titute a minimum system, such as simple structureMSP430F149 chip has 60 KB FLASH + 256 bytes, 2 karma, including the basicclock module, the watchdog timer, with three capture/compare registers and PWM output 16-bit timers, with seven capture/compare registers and PWM output, two 16 bit timer interru

23、pt function of 8 bits parallel port, four 8-bit parallel port, analog comparator, 12 bit A/D converter, and the two serial communication interface module, etc. MSP430F149 chip has the following characteristics:(1) Low power consumption, voltage of 2.2 V, 1 MHZ clock frequency, the current activity p

24、attern chip is 200 mu A, closed mode current is only 0.1 A;(2) Efficient 16-bit RISC CPU, 27 instruction, 8 MHZ clock frequency, the instruction cycle time Of 125 ns, the vast majority of instructions completed in one clock cycle;(3) Low voltage power supply, wide working voltage range: 1.8 3.6 V;(4

25、) Flexible clock system: two external clock and an internal clock; (5)Low clock frequency can realize high-speed communication; (6) With serial online programming ability ;(7) interrupt functions; (8) wake up time is short, wake upjust from the low power mode6 mu s; (9) ESD protection, strong anti-i

26、nterference; (10) fan running environment temperature - 40 + 85 , suitable for the industrial environment.Of all peripheral modules MSP430 series MCU control is achieved through special registers, so it is relatively easy to write. When programming development through the special programmer, you can

27、 choose to assembly or C language programming, IAR for MSP430 series MCU development the company dedicated C430 languages, can directly by the WORKBENCH and C - SPY compiler debugging, using flexible and simple.1 The minimum system design9Minimum system is a necessary to ensure reliable processors w

28、ork of basic circuit,including power supply module, the module of crystal vibration and reset circuitmodule, JTAG interface circuit, display module, etc1.1 The power supply moduleThis system need to use the + 5 V and + 3.3 V dc regulated power supply;including MSP430Fl49 and some peripheral devices

29、need to + 3.3 V power supply,the other part need to + 5 V power supply. In this system, in order to + 5 V dc voltagefor the input voltage, 3.3 V + linear step-down directly by the + 5 V.1.2 Crystal vibration moduleMSP430 series MCU clock module includes numerical control oscillator (DCO),high-Speed

30、of crystal oscillator and crystal oscillator at low speed clock source. Thisis to understand System of rapid processing data and low power requirements ofcontradiction, through the design multiple clock source or for clock design all sorts ofdifferent working mode, can solve some Peripheral parts cl

31、ock requirements ofreal-time applications, such as low frequency communication, LCD display, timingDevice, counter, etc. Digital control oscillator DCO is integrated within the MSP430,in the system need to design high speed crystal oscillator and the low speed crystalLow-speed crystal oscillator (L

32、X F T L) can meet the requirements of low powerconsumption and the use of 32.768 kHz crystal vibration. Default LFXTL oscillatorwork in low frequency mode, the 32.768 kHz, but can be by external 450 kHz 8MHZ crystal vibration at a high speed Oscillation device or ceramic resonatorworking in high fre

33、quency mode, in this system using low frequency mode Type,crystals external 2 33 PF capacitor after XIN and XOUT connected to the MCU.High-speed chip, also known as the second oscillator XT2, it in working for theMSP430F149High frequency mode provides a clock, XT2 up to 8 MHZ. XT2adopted in the syst

34、em4 MHZ crystal, XT2 external 2 33 PF capacitor after XT2IN andXT2OUT connection To the MCU.101.3 Reset circuit moduleManual reset is minimal systems commonly used functions, this system adopts themanual reset button switches and RC circuit implementation, the circuit structure issimple.1.4 The JTAG

35、 interface circuitJTAG technology is a kind of embedded debugging technology, chip internalencapsulates the special electrical test TAP (test access port), through special JTAGtest tools to test and control of internal nodes, At present most of the ARM devicesupport JTAG protocol, standard JTAG inte

36、rface is 4 line; TMS (test mode selection),TCK (the clock) and TDI (test data serial input), TDO serial output (test data). JTAGinterface connection there are two standards that 14 needle JTAG interfaceMC9328MX1 connection circuit. Is used here consists of three state output 74 hc244deight-way buffe

37、r of 14 needle JTAG interface circuit.2 Application circuit design based on minimum system2.1 digital tube display moduleA digital tube display need 74 hc164 drive, 74 hc164 serial input and paralleloutput. Its parallel output actually there is a delay, just delay time is small, can beconsidered as

38、parallel output. Here is the way a serial port 0, 0 is and communicationof the shift register. TXD, RXD at this time is not like other ways a send, a receiver,but RXD can also input, output TXD shift pulse. Sending and receiving data must be8, bit rate fixed is 1/12 of the crystals. When set mode 0,

39、 it is automatically put theTXD make shift pulse. In detecting RXD TXD high levels, if high level 74 hc164study into 1, if it is a low level, enter 0.Receiving process: REN first to buy 1, then 1 TXD, read RXD condition, high levelwill receive 1, receive low level 0; Then pull down the TXD, after a

40、slight delay TXD11again high, read RXD, high level will receive 1, low level 0, and so on. Read until 8bits. Send SBUF process: is sent automatically. Send 1 RXD high first, TXD againget higher; And TXD become low, send 0 RXD lower first, TXD again get higher;Then the TXD become low, and so on. This

41、 process is done automatically, need notspecial programming. Digital tube look from the front, the decimal point in the lowerright foot, the pin above from left to right are respectively under the public side of Aand B, F, G of pins from left to right, respectively, E, C, common (decimal).2.2 The LE

42、D display modulePick up a few LED through the I/O port, through the programming a simpleprogram, which can realize the LED flashing, so as to achieve the test circuit and chipis normal.2.3 D/A conversion moduleMSP430F149 MCU with 12 bit A/D converter, but no D/A conversion, needexternal D/A conversi

43、on circuit. So choose DAC0832 d/a conversion chip, andUA741 high-gain general amplifier composed of d/a conversion circuit operation.UA741 chip pins as shown in figure 1.DAC0832 is 8 of D/A conversion chip. Complete compatible with microprocessor.The DA chip with its low cost, simple interface, conv

44、ert the advantages of easy control,widely used in the MCU application system. D/A converter by eight input latch, 8-bitDAC registers, 8 D/A conversion circuit and control circuit. DAC0832 is sampling12frequency for 8 D/A conversion chip, Integrated circuit has two levels of input register,DAC0832 ch

45、ip with double buffer, single buffer and through three kinds of inputmethods, in order to fit for the needs of the various circuit (such as requirementasynchronous input, synchronous multi-channel D/A conversion, etc.). The 8 bit D/Aconverter has eight input end (where each input is one of 8 bit bin

46、ary number), has ananalog output. Input can have 28 = 256 different binary configuration, output is one of256 voltage, the output voltage is not arbitrary value throughout the whole voltagerange, and can only be 256 possible values.2.4 LCD display moduleA/D conversion output data, need to use the LC

47、D display.2.5 Eight independent type keyboard moduleThe keyboard in the microcomputer application system, realize the function of theinput data, transmit command, and is a major means of human intervention. Keyboardwith coding and non coding keyboard, independent type button structure, matrixstructu

48、re key. First, monitoring any key press, the key of closed or not, reflect on thevoltage is present a high level or low level, so through the detection level of high andlow status, can confirm button pressed or not. Second, determine which key is pressed.Finally, the complete key processing tasks. I

49、ncluding software programming usinginterrupt scanning way. Keyboard circuit used in hc2 74 is a high-speed Si - gateCMOS1 integration chip, the pin compatible with low power consumption. Belong tothe Scotty TTL (input channel). The 74 hc21 provides 4 - input and function.2.6 The software designUsing

50、 the IAR Embedded Workbench Evaluation for MSP4305.10.1 softwareprogramming, the basic idea: the LED lights, digital tube as the main program, the 7key as interrupt, LCD is used to enter the interrupt and A/D conversion output displayoutput.2.7 extensionsBy extending the mouth can facilitate the single-chip microcomputer and peripheral13module, resources, make full use of the chip pin real MSP430 single chipmicrocomputer powerful function into full play. Loading other modules in theextension mouth, through debugging

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论