Texas Instruments MSP430 Series Manual
Texas Instruments MSP430 Series Manual

Texas Instruments MSP430 Series Manual

Starter kit & evalution kit
Hide thumbs Also See for MSP430 Series:
Table of Contents

Advertisement

Quick Links

MSP430 Family
Starter Kit
Evaluation Kit Manual
1999
Mixed-Signal Products
SLAS191A

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the MSP430 Series and is the answer not in the manual?

Questions and answers

Summary of Contents for Texas Instruments MSP430 Series

  • Page 1 MSP430 Family Starter Kit Evaluation Kit Manual 1999 Mixed-Signal Products SLAS191A...
  • Page 2 IMPORTANT NOTICE Texas Instruments and its subsidiaries (TI) reserve the right to make changes to their products or to discontinue any product or service without notice, and advise customers to obtain the latest version of relevant information to verify, before placing orders, that information being relied on is current and complete. All products are sold subject to the terms and conditions of sale supplied at the time of order acknowledgement, including those pertaining to warranty, patent infringement, and limitation of liability.
  • Page 3: Table Of Contents

    Contents Section Title Page Getting Started ............1–1 1.1 Installing the Software .
  • Page 4 Memory Configurations for MSP430 Devices ....... . 7–1 Difference Between STK and EVK .
  • Page 5 2–14 Transfer Data Command ..........2–14 2–15 EPROM Erase Check Command .
  • Page 7: Getting Started

    1 Getting Started This chapter provides installation and programming instructions for the starter Kit MSP-STK430x320, and the evaluation Kits MSP-EVK430x320 and MSP-EVK430x320. NOTE: This manual covers both the MSP-STK430x320 and MSP-EVK430x320 kits. The actual icons and/or windows on the computer screen may differ from those shown in the book due to software version upgrades.
  • Page 8: Hardware Installation

    Figure 1–1. MSP-STK430 Program Group Figure 1–2. MSP/EVK430 Program Group NOTE: EVK/STK430 Terminal icon Before clicking the EVK/STK430 Terminal icon, ensure the standard Windows Applications Terminal and Notepad are installed in the Windows directory. The Windows terminal emulator is configured to use serial port COM2 by default. Hardware Installation The STK/EVK kit hardware includes the STK/EVK-PCB and one 9-pin cable for connection to the PCs serial communication port.
  • Page 9: How To Install The Hardware

    1.2.2 How to Install the Hardware This section targets three main parts: the setup of the serial interface, the programming adapter, and the power supply. LCD and UVEPROM The EVK is supplied with the LCD and a UVEPROM, separate from the EVK PCB. Install the EPROM and LCD into the EVK PCB before proceeding.
  • Page 10: Terminal Screen

    MSP–STK430A320 >_ Figure 1–3. Terminal Screen A help message is displayed on the screen automatically if the Monitor message MSP-STK430x320 is not received by the STK/EVK control software, where x is the current revision letter. Reset Button NOTE: Pins for the STK Demo Program Some pins of the MSP430 device will be used for the sensor demo program (only available on the STK): •...
  • Page 11: Programming The Monitor Software Into An Erased Eprom (Evk Only)

    Changing the RS232 interface to another COM port (other than COM2) of a personal computer, requires a change to the COM port assignment in the current version of the terminal emulator. 1.2.3 Programming the Monitor Software Into an Erased EPROM (EVK Only) The following steps are recommended to program the Monitor into an EPROM after it has been erased: Connect the EVK-PCB to the programming adapter.
  • Page 12: Msp-Stk/Evk430X320 Target Connectors

    1.2.4 MSP-STK/EVK430x320 Target Connectors External Supply 3–5V dc Digital Signals: Only Required If Stand Pin 1 Pin 9 Pin 17 PO.0 Alone Operation Pin 2 XOUT Pin 10 Pin 18 PO.1 Pin 3 XBUF Pin 11 TP.0 Pin 19 PO.2 Pin 4 RST/NMI Pin 12...
  • Page 13: Msp-Evk430X330 Target Connectors

    1.2.5 MSP-EVK430x330 Target Connectors Pin z = Power g = Ground Figure 1–6. MSP-EVK430x330 Target Connectors 1–7...
  • Page 14: The Lcd

    1.2.6 The LCD Figure 1–7 shows the segment type LCD supplied with the STK/EVK. ± 40.00 0.25 ± ± ± 1.80x 19 = 34.20 0.10 2.90 0.15 2.90 0.15 ± 0.90 0.05 0.90 Digit Figure 1–7. Supplied LCD Mechanical Data 1–8...
  • Page 15: Lcd Segment Digits

    The LCD is connected to the STK/EVK as shown in Table 1–1. Table 1–1. LCD Connector PIN NO. COM1 COM2 COM3 COM4 – – COM3 – – – – COM4 – COM2 – – COM1 – – – – – –...
  • Page 16: Schematic For The Msp-Stk/Evk430X320

    1.2.7 Schematic for the MSP-STK/EVK430x320 1–10...
  • Page 17: Schematic For The Msp-Evk430X330

    1.2.8 Schematic for the MSP-EVK430x330 1–11...
  • Page 18: Starting The Stk Demo Program

    1.2.9 Starting the STK Demo Program In the HyperTerminal program, type a d to start the demo program. If the HyperTerminal program has been closed, double click on the Sensor Demo icon to start the demo program. LUXMETER Demo Program: The STK Monitor includes a demo program that shows a metering application.
  • Page 19: Properties

    How to use the command line parameters of the assembler: The default command line parameters of the assembler (asm430.exe) are -z and -I. These parameters are set in the Properties of the Assembler icon after installation. For further information on command line parameters see the Assembly Language Tools User’s Guide. To change the parameters, select the ASM430 Assembler icon with one left mouse click.
  • Page 20: Getting Started Demo Program

    ;**************************************************************************** ;Getting Started 1 Demo Program (C) TEXAS INSTRUMENTS on 2/96 ;**************************************************************************** .set ; 1 = Simulator ; 0 = STK/EVK RAM_orig .set 00240h ; Free Memory startadress SP_orig .set 003DEh ; stackpointer ;––– Control register definitions .equ .equ IFG1 .equ...
  • Page 21: Asm430 Assembler Window

    Use the assembler icon in the ADT430 Program Folder to assemble the gs_stk1.asm file, which is located in the C:\ADT430\STK\EXAMPLES directory, and is shown in Figure 1–11. Ensure that the Start in: property of the assemble icon is set to the source directory (C:\ADT430\STK\EXAMPLES). Click on the ASM430 Assembler icon.
  • Page 22: Gs_Stk1.Asm Window Display

    Enter the source name gs_stk1 and press ENTER. This will cause the assembler to assemble gs_stk1.asm into gs_stk1.txt. The following display will appear: File Source Figure 1–13. gs_stk1.asm Window Display The assembler output file is named gs_stk1.txt. This file is created only if the assembler is invoked with the option -z.
  • Page 23: Gs_Stk1.Asm

    MSP430 Macro Assembler Version 1.08 [09/96] Tue Jun 30 07:20:38 1998 Copyright (C) 1995, 1996 Texas Instruments Incorporated c:\adt430\stk\examples\gs_stk1.asm Page 1 1;*************************************************************************** 2;Getting Started 1 Demo Program (C) TEXAS INSTRUMENTS on 2/96 3;*************************************************************************** 5;*** Set this variable to ’1’ for the use on the Simulator*** .set...
  • Page 24: Terminal Window

    Next, the object file gs_stk1.txt will be downloaded to RAM of the MSP430-STK/EVK. The PC downloads the object file gs_stk1.txt to RAM of the MSP430_STK/EVK. The PC uses the HyperTerminal to communicate with the Monitor Program in the EVK/STK EPROM or ROM. Windows95 (NT) provides a terminal emulator icon under Start/Programs/Accessories.
  • Page 25: Terminal Transfer

    Open the pulldown menu Transfer in the HyperTerminal to load the program using the RS232 into the STK/EVK, as shown in Figure 1–16. Select the Send Text File menu item. NOTE: Transfer Send Text File Receive text file... MSP–STK430A320 View Text File... Send Binary File...
  • Page 26: Hyperterminal Display

    Select the assembler output file gs_stk1.txt in the examples directory from the Send Text File . . dialog box. Figure 1–17 shows the HyperTerminal screen displaying the following data after loading gs_stk1.txt into the STK/EVK. Init MSP–STK430A320 >@0240 31 40 DE 03 B2 40 80 5A 20 01 F2 42 00 00 C2 43 01 00 C2 43 02 00 C2 43 03 00 FF 3F >downloaded _PC_ _SP_ _SR_...
  • Page 27: Terminal | Execute Gs_Stk1.Txt

    In the HyperTerminal , type r0 <ENTER> to modify the program counter of the user program. The program displays the current content of r0. Next type 0240 <ENTER> to set the start address as defined in gs_stk1.asm. Exit the modify register mode by pressing the <ESC> key. Each time the SPACE bar is pressed, the program executes one single step and the program displays the registers contents.
  • Page 28: How To Use Breakpoints

    1.2.11 How to Use Breakpoints Continue the Getting Started exercise by assembling and downloading the file gs_stk2.asm in the examples directory as described previously. This program includes a section for the reset vector, so the program counter is initialized after the download and each time a user performs a reset.
  • Page 29: Accessing The Port On The Msp430X320 Stk/Evk

    Enter The g-command to start the program Press <ESC> to Interrupt the program Enter the u-command to execute a user reset Enter the s-command to set a breakpoint Enter the address of the breakpoint >downloaded _PC_ _SP_ _SR_ reg 000: 0240 03de 0008 0000 f48c 0010 0000 15de reg 0008 0e62 404d 0000 ffd0 2153 0e14 28ad feff...
  • Page 30: How To Use An Interrupt Routine

    $ML1 BIT.B #01h,P0IN ; Test P0.0 $ML1 ; Do nothing if P0.0 low 1.2.13 How to Use an Interrupt Routine Assemble and download the file gs_stk4.asm in the examples directory, as described previously. When an interrupt occurs, the program sends the contents of the program counter and status register to the stack.
  • Page 31: Loading A Program Into The Eprom Via The Terminal

    Set a breakpoint at address 025Eh, and single step through the program. A longer reaction time can be expected for any step beyond address 025Eh. At this time, the CPU is off and waiting for the Basic Timer interrupt. Only two breakpoints may be set at any one time. NOTE: >step >executed _PC_ _SP_ _SR_...
  • Page 32: Programming Voltage And Jumper Location

    V PP -Input Apply If programming via serial port V PP fuse F250 mA Connects to programming Jumper for programming the EPROM adapter MSP-PRG430x of an EVK with the Monitor (EVK only) Figure 1–22. Programming Voltage and Jumper Location To load a program into the MSP430 EPROM/ROM using the HyperTerminal, the following points must be considered: •...
  • Page 33: Eprom Lcd And Interrupt Routine

    ;**************************************************************************** ; Section in EPROM ;**************************************************************************** .sect “PrepLCD”, EPROM_orig ;––– Prepare LCD and Basic timer PrepLCD MOV.B #–1h,LCDM ;LCD : Analog generator on Low impedance 4 Mux active all outputs are Seg MOV.B #057h,BTCTL ; Basic Timer : SSEL=0 DIV=0 Reset=1 ;...
  • Page 34: Hyperterminal Window

    MSP–STK430A320 >_ Figure 1–24. HyperTerminal Window To load a program into the MSP430 using the HyperTerminal, activate the Transfers/Send Text File. . . command as shown in Figure 1–25. Transfer Send Text File Receive text file... MSP–STK430A320 View Text File... Send Binary File...
  • Page 35: Send Text File Dialog Box

    Choose your Text File Press Open to Send TXT File Figure 1–26. Send Text File Dialog Box Figure 1–27 represents a burn fail screen. If an error occurs during the programming of the EPROM, the screen shows the message burn failed at XXXX. Where XXXX is the address where the programming cycle failed the first time.
  • Page 36: Burn Failed Message

    >@C000 F2 43 30 00 F2 40 57 00 40 00 F2 D0 80 00 05 00 F2 C0 40 00 40 00 F2 D0 80 00 01 00 F0 40 80 00 01 42 B0 12 50 C0 32 D2 @C050 35 40 0F 00 C5 43 30 00 15 83 FC 23 30 41 @C100...
  • Page 37: Monitor Commands

    2 Monitor Commands This chapter describes the syntax conventions and the available commands of the Monitor Program. Syntax Conventions • The numbers in brackets [ ] are optional. • x is a hexadecimal address. • n is the hexadecimal number of bytes to show. •...
  • Page 38: Commands

    Commands The h command displays the Help Command screen shown in Figure 2–2 with the available commands. Enter h at the command prompt >Monitor Commands help byte, word mode monitor, user reset r[x] inspect registers mx[n] inspect memory ex n eprom erase check @x ..
  • Page 39: Byte, Word Commands

    b,w The b and w commands shown in Figure 2–3 switch to byte or word indication mode. The two indication modes are only important for the memory inspect command m. The Monitor completes the entered command (byte or word). Enter b at the command prompt Enter w at the command prompt >MSP–STK430A320 >byte...
  • Page 40: Initializing The Terminal Program Command

    The i command, shown in Figure 2–4, initializes the entire monitor program. This command performs a software reset of the STK/EVK, but is only possible if the monitor is still running. If the contents of memory location 3DEh are AA55h, the i command will start the user application. Turn off the hardware supply voltage to return control to the monitor.
  • Page 41: User Reset Command

    The u command, shown in Figure 2–5, sets the user PC to the start vector of the loaded user program. This performs a user reset of the application. In this example, the start vector of the user application, located at address 03FEh, is 0300h. Enter u at the command prompt >user reset _PC_...
  • Page 42: Register Command

    r[i] The r <ENTER> command, shown in Figure 2–6, without a specific register number, shows all 16 CPU registers R0 to R15. With this syntax, a modification of the register contents is not possible. Enter r then <ENTER> at the command prompt >init MSP–STK430A320 >r...
  • Page 43: Register Specified Command

    Entering the command with the hexadecimal register number r[i] <ENTER> as shown in Figure 2–7, results in displaying only the contents of the dedicated register i. Type r5 <ENTER> at the command prompt >r5 reg 0005 : 0010 _ Figure 2–7. Register Specified Command NOTE: Modification of the Registers R1, R3, and R4 The Monitor Program does not allow the modification of registers R1, R3, and R4.
  • Page 44: Modify One Register

    Figure 2–8 shows the procedure for changing data in a register. Write new data into register r[i] by pressing <ENTER> and the program displays the next register. Type r5 <ENTER> at the command prompt Type the new desired register contents and press <ENTER> >init MSP–STK430A320 >r5...
  • Page 45: Modify Additional Registers

    Figure 2–9 shows the procedure to modify an additional register. Press <ENTER>, and the program displays the next register. Enter r <ENTER> to show the modified register contents Press <ESC> here Modified registers r5, r6 >init MSP–STK430A320 >r5 reg 0005 : 0010 aaaa reg 0006 0069 bbbb reg 0007...
  • Page 46: Revise Memory Modification

    Figure 2–10 shows the proper way to change incorrect entries. Using the Arrow, Delete or Insert keys as inputs causes unpredictable behavior. After entering an incorrect register content, the entire input should be entered again. Another method is to press <ESC> and to enter the r[i] command again. NOTE: The ENTER key must never be pressed after entering an incorrect input.
  • Page 47: Memory Byte, Word Command

    mx[n] The m command allows the user to inspect (read/modify/write) memory locations. Use the m command in conjunction with the b or w commands. The b or w command displays the memory as shown in Figure 2–11. Enter b at the command prompt Enter w at the command prompt Enter m220 20 at the command prompt >init...
  • Page 48: Memory Modification

    Figure 2–12 shows how to modify memory contents. Modify the memory by typing in new data and pressing <ENTER>. The program displays the next memory location. If no modification is necessary press <ENTER>. To exit the memory command (mx) press the <ESC> key. Pressing <ENTER> toggles through memory locations, displaying each new location after <ENTER>.
  • Page 49: Revised Memory Modification

    To revise an incorrect terminal input, perform the following functions as shown in Figure 2–13. Using the Arrow, Delete or Insert keys as inputs causes unpredictable behavior. After entering an incorrect register contents, the entire input should be entered again. Another method is to press <ESC> and enter the m command again.
  • Page 50: Transfer Data Command

    The @x command loads program/data section(s), byte by byte, into the RAM/EPROM. A program algorithm detects the correct download section (in the RAM or EPROM) and runs automatically. The transfer can be made by using a keyboard or by file transfer (pull-down menu Transfers/Send Text File in Hyperterminal program).
  • Page 51: Eprom Erase Check Command

    ex n The EPROM erase check (ex n) command verifies that the EPROM is empty. The EPROM is empty if the contents of all EPROM-memory locations are FFh. The x represents the starting address to verify that the EPROM has been erased. The n portion of this command will show the number of bytes that have been erased.
  • Page 52: Location Of A Breakpoint Command

    The s command allows a breakpoint to be set. The program supports the capability of having two breakpoints. Breakpoints may be set only if the program is in RAM. Typing an s shows the breakpoints that are currently set. Figure 2–16 shows how to enter the location of the breakpoint. Set a breakpoint by Typing ‘s’...
  • Page 53: Set A Breakpoint Command

    The address of the two breakpoints should not be identical. Only two breakpoints are supported, a third breakpoint cannot be set. In order to set another breakpoint, one breakpoint has to be cleared first with the c command. Figure 2–17 shows the breakpoint after entry. To set a breakpoint type s Enter the location of the breakpoint: 24e <ENTER>...
  • Page 54: Clearing A Breakpoint Command

    The c command is used to clear a breakpoint. Typing c shows the set breakpoints, as shown in Figure 2–18. Clear a breakpoint by typing a ‘c’ >Clr Bkpt 024e 0000 Figure 2–18. Clearing a Breakpoint Command To clear one of the breakpoints (other than zero), it is necessary to enter the associated address. Typing the <ENTER>...
  • Page 55: Starting The Application Command

    The g command starts/restarts the user application that is loaded into RAM. The system retrieves the start vector of a user’s application from memory location (3FEh on the 320 STK/EVK, 5FEh on the 330 EVK) if a new program is loaded, or after executing a PUC command or a user reset. Otherwise, the program execution continues with the actual PC (R0).
  • Page 56 2–20...
  • Page 57: Monitor Restrictions

    3 Monitor Restrictions Register R4 The Monitor Program uses the R4 register internally to return data from the user application to the Hyperterminal. Modifications to the value stored in R4 will result in unexpected behavior of the Monitor Program. The Monitor command r, to change the register contents, is not supported for R4. The register R4 can be modified by the user application code.
  • Page 58: Peripheral Hardware/Registers

    Peripheral Hardware/Registers Do not modify the following peripheral registers and bits because UART operation uses these register and bits. Table 3–1. Peripheral Registers and Bits REGISTER ADDRESS BITS TCDAT TCPLD TCCTL IFG1 P0IES 1, 2 P0DIR 1, 2 P0IFG P0IE RAM Locations for the Monitor The Monitor Program uses eighteen bytes of RAM, from address 200h to 212h, within the RAM area of the MPS430x32x (which ranges from 200h to 3FFh for the MSPx32x family, and 200h to 5FFh for the MSPx33x...
  • Page 59: Ram Area 272H To 3Feh

    In most cases, it is efficient to initialize the user stack which is allowed to grow (downwards) until it reaches the address 270h (26Fh–32h=23Eh). Thus, the resulting size of the maximum user stack is 16Dh (3DCh–272h=16Ah) on the MSP430x325 family and 360h (5DCh–272h = 36Ah) on the MSP430x33x family. 3FEh 5FEh Interrupt...
  • Page 60: Ram Area 200H To 3Ffh For The Msp430X32X Family

    The user application data is located within the RAM area from 272h to 3FEh (5FEh for 33x). The locations used statically (200h to 214h) and dynamically (stack) by the Monitor Program limit the size of the available RAM. Due to limited size, two memory configurations are recommended as shown in Figure 3–3. User application inactive, Monitor Program active User application active...
  • Page 61: Writing Data Into The Eprom

    Writing Data Into the EPROM When data is written into the EPROM address range, software code is written into RAM locations 214h to 23Dh. All addresses 1000h or higher are assumed to be EPROM. After the write operation is completed, the code in the RAM is no longer needed.
  • Page 62 3–6...
  • Page 63: Treatment Of Interrupts

    4 Treatment of Interrupts This chapter describes the special treatment of interrupts in the Monitor environment. Use of Interrupts in the Monitor Environment The interrupt structure of the MSP430 is fully supported by the terminal program with one exception, the NMI interrupt has the same interrupt vector as the RESET interrupt.
  • Page 64: P0.0 Interrupt Example

    Figure 4–2 shows the handling of a P0.0 interrupt for the MSP430X32x family. For the MSP430X33x, replace address 03FAh with 05FAh. P0.0 Interrupt XXXX FFFAh XXXX BR & 03FAh YYYY 03FAh YYYY YYYY Is The Start Address Of The Interrupt Service Routine Figure 4–2.
  • Page 65: Interrupt Vectors For The Msp430X32X Family

    Table 4–2. Interrupt Vectors for the MSP430x32x Family INTERRUPT SYSTEM WORD INTERRUPT SOURCE PRIORITY FLAG INTERRUPT ADDRESS RSTI †, WDI † Power-up external reset watchdog Reset 3FEh 15, highest NMIIFG † Nonmaskable 3FCh OFIFG † Oscillator fault Nonmaskable Dedicated I/O P0.0IFG Maskable 3FAh...
  • Page 66 4–4...
  • Page 67: Half Duplex Monitor Software Uart

    5 Half Duplex Monitor Software UART The Monitor Program provides several functions for handling serial data communications using the RS-232 interface. The user can call these functions by using the associated vectors in the terminal program. Use the absolute address mode to call these functions. For example, a possible syntax for preparing the half duplex software UART to receive characters is: CALL &0FFD6h...
  • Page 68: Identification Of Bit Pattern Aa55H For The Msp430X32X Family

    The flow chart in Figure 5–1 I illustrates the entry point of the INT_RXTX interrupt service routine: INT_P0.1 Identification ? Contents Of Memory Location 3DEh = AA55h P0.1 Interrupt Continues Program Execution Upon The User Interrupt Vector Stored In Memory Location 3F8h User Interrupt Service Routine Branches To INT_RXTX Service Routine From ROM-Monitor ?
  • Page 69 NOTE: Init Command Do not use the Monitor init command out of the terminal emulator while the bit pattern AA55h is stored in memory location 3DEh on the MSP430X32x, or 5DEh on the MSP430X33x family. Otherwise, the user application with the reset vector stored at 3FEh (5FEh for the MSP430X33x family) will be started.
  • Page 70: Special Treatment Of In The Software Uart

    Special Treatment of <ESC> in the Software UART The software UART treats a received ESC character in two different ways: • The software UART receives the ESC character and stores it at address 210h. The condition, therefore, is that bit 0 in memory location 200h is reset. •...
  • Page 71: Transmitting One Character

    Transmitting One Character To transmit one character, copy AA55h to memory location 3DEh, or memory location 5DEh for the MSP430X33x family. Store the character to transmit in RAM-location 020Eh. #0AA55h,&03DEh ; &05DEh for MSP430X33x MOV.B #‘a’,&TX_Data ; put char to TX_Data Call the function TX_Char to transmit the character stored at location 20Eh.
  • Page 72: Transmitting The S Character

    The following code in Figure 5–3 is an example of transmission of the single character s. WDTCTL .equ 0120h WDTHold .equ 80h WDT_wrkey .equ 05a00h TXCHAR .equ 0FFD2h TXTABLE .equ 0FFD4h PREPRX .equ 0FFD6h PREPTX .equ 0FFD8h INT_RXTX .equ 0FFDAh TXDATA .equ 020Eh RXBUF...
  • Page 73: Transmitting A String

    In Figure 5–3, the endless loop at the end of the program can be interrupted by pressing <ESC> in the HyperTerminal. If no special treatment of <ESC> is required in the software UART, bit 0 in RAM location 200h must be cleared. This bit is the ESC-active-flag and allows itself to return back to the Hyperterminal when pressing the ESC key.
  • Page 74: Receiving A Character

    ; receive to get back to monitor ; with ESC #00h,&03DEh ; prepare software UART only for ; use in the ROM-Monitor (&05DEh on the MSP430X33 ENDL ENDL UART &INT_RXTX .sect “Int_Vect”,03E0h ; 05E0h on the MSP430X33x .word RESET ; Reset .word RESET ;...
  • Page 75 ; receive to get back to monitor ; with ESC WAIT TST.B &RXBUF ; char. in rxbuf ? WAIT ; no, then wait MOV.B &RXBUF,&TXDATA ; put char to TXDATA CLR.B &RXBUF #01h,&200h ; use only if no special ; treatment of ESC is wanted CALL &TXCHAR ;...
  • Page 76 EINT ; enable interrupt CALL &PREPRX #0AA55h,&03DEh ; &05DEh on the MSP430X33x #STRING,R7 ; load string address WAIT: MOV.B #RXBUF,R6 ; char. in rxbuf ? CMP.B #0h,r6 WAIT ; no, then wait CLR.B &RXBUF CMP.B #cr,R6 ; end of line ’...
  • Page 77: Using Interrupt Vectors In The Eprom

    6 Using Interrupt Vectors in the EPROM This chapter describes how to use interrupt vectors stored in the EPROM. The interrupt vectors are stored in EPROM so they are not lost when power is removed. The Identification Bit Pattern After a Reset The reset start-up sequence checks the contents of memory location E9DEh to see if its contents are equal to AA55h.
  • Page 78: Identifying Aa55H After Reset

    Reset Set Location of Identification Address Pointer to E9DEh Decrement Identification Address Pointer By 22h Identification ? Contents of Identification Address = 0000h Identification ? Contents of Identification Address = AA55h Copy EPROM Interrupt Vectors And Identification AA55h To RAM Interrupt Vectors Jump To New Reset Vector Start Monitor Address In RAM...
  • Page 79 The following example demonstrates how to implement and test the emergency come-back to the monitor routine: Set the variable DVLP to 0 after the routine has been successfully tested in RAM. The variable TRIAL indicates the number of interrupt tables that have been burned. The last necessary input is the start address BEGIN.
  • Page 80 .word start ;––– additionally define reset vector in EPROM if final version .if DVLP = 0 .sect “EPRM_RES”, 0E9FEh–((TRIAL–1)*22h) .word start write identification to EPROM if final version. This MUSt be the LAST section ! .sect “IDENT”, 0E9DEh–((TRIAL–1)*22h) .word 0AA55h .endif NOTE: Identification Pattern AA55h Program the identification pattern as the last word of the download.
  • Page 81: Memory Map Of The Stk/Evk

    7 Memory Configurations for MSP430 Devices The MSP430 is well suited for the development cycle. The Monitor Program provides the commands s and c to set and clear breakpoints, and SPACE to perform a single step execution in the RAM area for these devices.
  • Page 82: Memory Map Of The Stk/Evk430X32X

    Address Address EPROM FFFEh RESET 3FEh User Interrupt Vectors MONITOR User 3E0h Ident. (AA55h) 3DEh 3DCh EA00h E9FEh RESET User User Interrupt Program, Data Vectors and Stack E9E0h Ident. (AA55h) 23Eh E9DEh 23Dh E9DCh Temporary EPROM Programming Routine † User 214h Program (–...
  • Page 83: Memory Map Of The Stk/Evk430X33X

    Address Address EPROM FFFEh RESET 5FEh User Interrupt Vectors MONITOR User 5E0h Ident. (AA55h) 5DEh 5DCh EA00h E9FEh RESET User User Interrupt Program, Data Vectors and Stack E9E0h Ident. (AA55h) 23Eh E9DEh 23Dh E9DCh Temporary EPROM Programming Routine † User 214h Program (–...
  • Page 84 7–4...
  • Page 85 Appendix A Difference Between STK and EVK Initialization banner MSP-STK430x320 MSP-EVK430x320/MSP-EVK430x330 Device One mounted OTP device Two windowed unbearable devices PMS430E325FZ or MSP430P325IPM PMS430E337HFD Monitor Programmed Programmed in only one device. After erasing the device, the monitor program (mon_140.txt for the MSP–EVK430x320, and mon_160.txt for the MSP–EVK430x330) in the STK directory must be programmed again.
  • Page 86 A–2...
  • Page 87 Mouser Electronics Authorized Distributor Click to View Pricing, Inventory, Delivery & Lifecycle Information: Texas Instruments MSP-EVK430S320 MSP-EVK430S330...

This manual is also suitable for:

Msp-stk430x320Msp-evk430x320

Table of Contents