Texas Instruments MSP430x1xx Manual do Utilizador

Consulte online ou descarregue Manual do Utilizador para Geradores de energia Texas Instruments MSP430x1xx. Texas Instruments MSP430x1xx User's Manual Manual do Utilizador

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 432
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes

Resumo do Conteúdo

Página 1 - User’s Guide

  2005 Mixed Signal ProductsUser’s GuideSLAU049E

Página 2

Contentsx10 Watchdog Timer 10-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Página 3 - 

Instruction Set3-64 RISC 16−Bit CPU* SETN Set negative bitSyntax SETNOperation 1 −> NEmulation BIS #4,SRDescription The negative bit (N) is set.St

Página 4 - Glossary

Instruction Set3-65 RISC 16−Bit CPU* SETZ Set zero bitSyntax SETZOperation 1 −> ZEmulation BIS #2,SRDescription The zero bit (Z) is set.Status Bit

Página 5 - Register Bit Conventions

Instruction Set3-66 RISC 16−Bit CPUSUB[.W] Subtract source from destinationSUB.B Subtract source from destinationSyntax SUB src,dst or SUB.W src,dstS

Página 6

Instruction Set3-67 RISC 16−Bit CPUSUBC[.W]SBB[.W] Subtract source and borrow/.NOT. carry from destinationSUBC.B,SBB.B Subtract source and borrow/

Página 7 - 

Instruction Set3-68 RISC 16−Bit CPUSWPB Swap bytesSyntax SWPB dstOperation Bits 15 to 8 <−> bits 7 to 0Description The destination operand high

Página 8

Instruction Set3-69 RISC 16−Bit CPUSXT Extend SignSyntax SXT dstOperation Bit 7 −> Bit 8 ... Bit 15Description The sign of the low byte is e

Página 9 - Contents

Instruction Set3-70 RISC 16−Bit CPU* TST[.W] Test destination* TST.B Test destinationSyntax TST dst or TST.W dstTST.B dstOperation dst + 0FFFFh + 1dst

Página 10 - Contents

Instruction Set3-71 RISC 16−Bit CPUXOR[.W] Exclusive OR of source with destinationXOR.B Exclusive OR of source with destinationSyntax XOR src,dst or

Página 11

Instruction Set3-72 RISC 16−Bit CPU3.4.4 Instruction Cycles and LengthsThe number of CPU clock cycles required for an instruction depends on theinstru

Página 12

Instruction Set3-73 RISC 16−Bit CPUFormat-I (Double Operand) Instruction Cycles and LengthsTable 3−16 lists the length and CPU cycles for all address

Página 13 - 

Contentsxi 14 USART Peripheral Interface, SPI Mode 14-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14.1 USA

Página 14 - 1.2 Flexible Clock System

Instruction Set3-74 RISC 16−Bit CPU3.4.5 Instruction Set DescriptionThe instruction map is shown in Figure 3−20 and the complete instruction setis sum

Página 15 - 1.3 Embedded Emulation

Instruction Set3-75 RISC 16−Bit CPUTable 3−17.MSP430 Instruction SetMnemonic Description V N Z CADC(.B)†dst Add C to destination dst + C → dst * * *

Página 17 - 1.4.5 Memory Organization

4-1Basic Clock Module  "# "The basic clock module provides the clocks for MSP430x1xx devices. Thischapter describes the opera

Página 18 - Introduction

Basic Clock Module Introduction4-2Basic Clock Module4.1 Basic Clock Module IntroductionThe basic clock module supports low system cost and ultralow-po

Página 19 - 

Basic Clock Module Introduction4-3Basic Clock ModuleFigure 4−1. Basic Clock Block DiagramDivider/1/2/4/8DIVAxMCLKCPUOFFDCOCLKXINXOUTDCORP2.5/RoscLFXT1

Página 20

Basic Clock Module Operation4-4Basic Clock Module4.2 Basic Clock Module OperationAfter a PUC, MCLK and SMCLK are sourced from DCOCLK at ~800 kHz (seed

Página 21 - Figure 2−2. POR Timing

Basic Clock Module Operation4-5Basic Clock Module4.2.2 LFXT1 OscillatorThe LFXT1 oscillator supports ultralow-current consumption using a32,768-Hz wat

Página 22 - Figure 2−3. Brownout Timing

Basic Clock Module Operation4-6Basic Clock Module4.2.3 XT2 OscillatorSome devices have a second crystal oscillator, XT2. XT2 sources XT2CLKand its cha

Página 23 - Software Initialization

Basic Clock Module Operation4-7Basic Clock ModuleAdjusting the DCO frequencyAfter a PUC, the internal resistor is selected for the DC generator, RSELx

Página 24 - 2.2 Interrupts

Contentsxii18 ADC10 18-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Página 25 - Reset/NMI Pin

Basic Clock Module Operation4-8Basic Clock ModuleUsing an External Resistor (ROSC) for the DCOThe DCO temperature coefficient can be reduced by using

Página 26

Basic Clock Module Operation4-9Basic Clock Module4.2.5 DCO ModulatorThe modulator mixes two DCO frequencies, fDCO and fDCO+1 to produce anintermediate

Página 27 - Oscillator Fault

Basic Clock Module Operation4-10Basic Clock Module4.2.6 Basic Clock Module Fail-Safe OperationThe basic clock module incorporates an oscillator-fault

Página 28 - 2.2.2 Maskable Interrupts

Basic Clock Module Operation4-11Basic Clock ModuleOscillator Fault DetectionSignal XT_OscFault triggers the OFIFG flag as shown in Figure 4−10. TheLFX

Página 29 - Interrupt Acceptance

Basic Clock Module Operation4-12Basic Clock ModuleSourcing MCLK from a CrystalAfter a PUC, the basic clock module uses DCOCLK for MCLK. If required,MC

Página 30 - Interrupt Nesting

Basic Clock Module Operation4-13Basic Clock Module4.2.7 Synchronization of Clock SignalsWhen switching MCLK or SMCLK from one clock source to the anot

Página 31 - 2.2.4 Interrupt Vectors

Basic Clock Module Registers 4-14Basic Clock Module4.3 Basic Clock Module Registers The basic clock module registers are listed in Table 4−1:Table 4−1

Página 32 - 2.3 Operating Modes

Basic Clock Module Registers 4-15Basic Clock ModuleDCOCTL, DCO Control Register76543210DCOx MODxrw−0 rw−1 rw−1 rw−0 rw−0 rw−0 rw−0 rw−0DCOxBits7-5DCO

Página 33

Basic Clock Module Registers 4-16Basic Clock ModuleBCSCTL2, Basic Clock System Control Register 276543210SELMx DIVMx SELS DIVSx DCORrw−(0) rw−(0) rw−(

Página 34

Basic Clock Module Registers 4-17Basic Clock ModuleIE1, Interrupt Enable Register 176543210OFIErw−0Bits7-2These bits may be used by other modules. See

Página 35 - 2.5 Connection of Unused Pins

1-1Introduction This chapter describes the architecture of the MSP430.Topic Page1.1 Architecture 1-2. . . . . . . . . . . . . . . . . . .

Página 36

4-18Basic Clock Module

Página 37 -   !

5-1 Flash Memory Controller "  ""This chapter describes the operation of the MSP430 flash memory controller.Topic

Página 38 - 3.1 CPU Introduction

Flash Memory Introduction5-2 Flash Memory Controller5.1 Flash Memory IntroductionThe MSP430 flash memory is bit-, byte-, and word-addressable andprogr

Página 39 - Figure 3−1. CPU Block Diagram

Flash Memory Segmentation5-3 Flash Memory Controller5.2 Flash Memory SegmentationMSP430 flash memory is partitioned into segments. Single bits, bytes,

Página 40 - 3.2 CPU Registers

Flash Memory Operation5-4 Flash Memory Controller5.3 Flash Memory OperationThe default mode of the flash memory is read mode. In read mode, the flashm

Página 41 - Figure 3−4. Stack Usage

Flash Memory Operation5-5 Flash Memory Controller5.3.2 Erasing Flash MemoryThe erased level of a flash memory bit is 1. Each bit can be programmed fro

Página 42 - 3.2.3 Status Register (SR)

Flash Memory Operation5-6 Flash Memory ControllerInitiating an Erase from Within Flash MemoryAny erase cycle can be initiated from within flash memory

Página 43

Flash Memory Operation5-7 Flash Memory ControllerInitiating an Erase from RAMAny erase cycle may be initiated from RAM. In this case, the CPU is not h

Página 44

Flash Memory Operation5-8 Flash Memory Controller5.3.3 Writing Flash MemoryThe write modes, selected by the WRT and BLKWRT bits, are listed inTable 5−

Página 45 - 3.3 Addressing Modes

Flash Memory Operation5-9 Flash Memory ControllerIn byte/word mode, the internally-generated programming voltage is appliedto the complete 64-byte blo

Página 46 - 3.3.1 Register Mode

Architecture1-2Introduction1.1 ArchitectureThe MSP430 incorporates a 16-bit RISC CPU, peripherals, and a flexible clocksystem that interconnect using

Página 47 - 3.3.2 Indexed Mode

Flash Memory Operation5-10 Flash Memory ControllerInitiating a Byte/Word Write from RAMThe flow to initiate a byte/word write from RAM is shown in Fig

Página 48 - 3.3.3 Symbolic Mode

Flash Memory Operation5-11 Flash Memory ControllerBlock WriteThe block write can be used to accelerate the flash write process when manysequential byt

Página 49 - 3.3.4 Absolute Mode

Flash Memory Operation5-12 Flash Memory ControllerBlock Write Flow and ExampleA block write flow is shown in Figure 5−8 and the following example.Figu

Página 50 - 3.3.5 Indirect Register Mode

Flash Memory Operation5-13 Flash Memory Controller; Write one block starting at 0F000h.; Must be executed from RAM, Assumes Flash is already erased.;

Página 51

Flash Memory Operation5-14 Flash Memory Controller5.3.4 Flash Memory Access During Write or EraseWhen any write or any erase operation is initiated fr

Página 52 - 3.3.7 Immediate Mode

Flash Memory Operation5-15 Flash Memory Controller5.3.5 Stopping a Write or Erase CycleAny write or erase operation can be stopped before its normal c

Página 53 - 3.4 Instruction Set

Flash Memory Operation5-16 Flash Memory ControllerProgramming Flash Memory via JTAGMSP430 devices can be programmed via the JTAG port. The JTAG interf

Página 54

Flash Memory Registers5-17 Flash Memory Controller5.4 Flash Memory RegistersThe flash memory registers are listed in Table 5−4.Table 5−4.Flash Memory

Página 55 - B/W D/S-Reg

Flash Memory Registers5-18 Flash Memory ControllerFCTL1, Flash Memory Control Register15 14 13 12 11 10 9 8FRKEY, Read as 096hFWKEY, Must be written a

Página 56 - Table 3−13.Jump Instructions

Flash Memory Registers5-19 Flash Memory ControllerFCTL2, Flash Memory Control Register15 14 13 12 11 10 9 8FWKEYx, Read as 096hMust be written as 0A5h

Página 57

Embedded Emulation1-3IntroductionFigure 1−1. MSP430 ArchitectureACLKBusConv.PeripheralMAB 16-BitMDB 16-BitMCLKSMCLKClockSystemPeripheral PeripheralPer

Página 58

Flash Memory Registers5-20 Flash Memory ControllerFCTL3, Flash Memory Control Register FCTL315 14 13 12 11 10 9 8FWKEYx, Read as 096hMust be written a

Página 59

Flash Memory Registers5-21 Flash Memory ControllerIE1, Interrupt Enable Register 176543210ACCVIErw−0Bits7-6,4-0These bits may be used by other modules

Página 60

5-22 Flash Memory Controller

Página 61

6-1Supply Voltage Supervisor " $" %This chapter describes the operation of the SVS. The SVS is implemented inMSP430x15x

Página 62

SVS Introduction6-2Supply Voltage Supervisor6.1 SVS IntroductionThe supply voltage supervisor (SVS) is used to monitor the AVCC supplyvoltage or an ex

Página 63

SVS Introduction6-3Supply Voltage SupervisorFigure 6−1. SVS Block Diagram+− 1.25VBrownoutResetVCCSet SVSFGtReset ~ 50usResetSVSCTL Bits000100100011111

Página 64

SVS Operation6-4Supply Voltage Supervisor6.2 SVS OperationThe SVS detects if the AVCC voltage drops below a selectable level. It can beconfigured to p

Página 65

SVS Operation6-5Supply Voltage Supervisor6.2.3 Changing the VLDx BitsWhen the VLDx bits are changed, two settling delays are implemented toallows the

Página 66

SVS Operation6-6Supply Voltage Supervisor6.2.4 SVS Operating RangeEach SVS level has hysteresis to reduce sensitivity to small supply voltagechanges w

Página 67 - Clear carry bit

SVS Registers6-7Supply Voltage Supervisor6.3 SVS RegistersThe SVS registers are listed in Table 6−1.Table 6−1.SVS RegistersRegister Short Form Registe

Página 68 - Clear negative bit

Address Space1-4Introduction1.4 Address SpaceThe MSP430 von-Neumann architecture has one address space shared withspecial function registers (SFRs), p

Página 69

6-8Supply Voltage Supervisor

Página 70

7-1Hardware Multiplier &'""This chapter describes the hardware multiplier. The hardware multiplier isimplemented in

Página 71

Hardware Multiplier Introduction7-2Hardware Multiplier7.1 Hardware Multiplier IntroductionThe hardware multiplier is a peripheral and is not part of t

Página 72

Hardware Multiplier Operation7-3Hardware Multiplier7.2 Hardware Multiplier OperationThe hardware multiplier supports unsigned multiply, signed multipl

Página 73 - Decrement destination

Hardware Multiplier Operation7-4Hardware Multiplier7.2.2 Result RegistersThe result low register RESLO holds the lower 16-bits of the calculation resu

Página 74

Hardware Multiplier Operation7-5Hardware Multiplier7.2.3 Software ExamplesExamples for all multiplier modes follow. All 8x8 modes use the absoluteaddr

Página 75

Hardware Multiplier Operation7-6Hardware Multiplier7.2.4 Indirect Addressing of RESLOWhen using indirect or indirect autoincrement addressing mode to

Página 76

Hardware Multiplier Registers7-7Hardware Multiplier7.3 Hardware Multiplier RegistersThe hardware multiplier registers are listed in Table 7−4.Table 7−

Página 78

8-1 () ""The DMA controller module transfers data from one address to anotherwithout CPU intervention. This chapter describes the

Página 79

Address Space1-5Introduction1.4.3 Peripheral ModulesPeripheral modules are mapped into the address space. The address spacefrom 0100 to 01FFh is reser

Página 80

8-28.1 DMA IntroductionThe direct memory access (DMA) controller transfers data from one addressto another, without CPU intervention, across the entir

Página 81

8-3Figure 8−1. DMA Controller Block DiagramDMA Priority And ControlENNMIDTDMA Channel 2DMASRSBYTEDMA2SZDMA2DADMA2SADMADSTBYTEDMASRCINCRxDMADSTINCRx223

Página 82 - Jump if greater or equal

8-48.2 DMA OperationThe DMA controller is configured with user software. The setup and operationof the DMA is discussed in the following sections.8.2.

Página 83 - Jump if less

8-58.2.2 DMA Transfer ModesThe DMA controller has six transfer modes selected by the DMADTx bits aslisted in Table 8−1. Each channel is individually c

Página 84 - Jump unconditionally

8-6Single TransferIn single transfer mode, each byte/word transfer requires a separate trigger.The single transfer state diagram is shown in Figure 8−

Página 85 - Jump if negative

8-7Figure 8−3. DMA Single Transfer State DiagramResetWait for TriggerIdleHold CPU,Transfer one word/byte[+Trigger AND DMALEVEL = 0 ]OR[Trigger=1 AND

Página 86

8-8Block TransfersIn block transfer mode, a transfer of a complete block of data occurs after onetrigger. When DMADTx = 1, the DMAEN bit is cleared af

Página 87

8-9Figure 8−4. DMA Block Transfer State DiagramResetWait for TriggerIdleHold CPU,Transfer one word/byte[+Trigger AND DMALEVEL = 0 ]OR[Trigger=1 AND D

Página 88

8-10Burst-Block TransfersIn burst-block mode, transfers are block transfers with CPU activityinterleaved. The CPU executes 2 MCLK cycles after every f

Página 89 - No operation

8-11Figure 8−5. DMA Burst-Block Transfer State Diagram2 x MCLKResetWait for TriggerIdleHold CPU,Transfer one word/byteBurst State(release CPU for 2xMC

Página 90

1-6Introduction

Página 91

8-128.2.3 Initiating DMA TransfersEach DMA channel is independently configured for its trigger source with theDMAxTSELx bits as described in Table 8−2

Página 92

8-13Table 8−2.DMA Trigger OperationDMAxTSELx Operation0000 A transfer is triggered when the DMAREQ bit is set. The DMAREQ bit is automatically resetwh

Página 93

8-148.2.4 Stopping DMA TransfersThere are two ways to stop DMA transfers in progress:- A single, block, or burst-block transfer may be stopped with an

Página 94 - Rotate left arithmetically

8-158.2.6 DMA Transfer Cycle TimeThe DMA controller requires one or two MCLK clock cycles to synchronizebefore each single transfer or complete block

Página 95 - Rotate left through carry

8-168.2.7 Using DMA with System InterruptsDMA transfers are not interruptible by system interrupts. System interruptsremain pending until the completi

Página 96

8-178.2.9 Using the I2C Module with the DMA ControllerThe I2C module provides two trigger sources for the DMA controller. The I2Cmodule can trigger a

Página 97

8-188.3 DMA RegistersThe DMA registers are listed in Table 8−4:Table 8−4.DMA RegistersRegister Short Form Register Type Address Initial StateDMA contr

Página 98

8-19DMACTL0, DMA Control Register 015 14 13 12 11 10 9 8Reserved DMA2TSELxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)76543210DMA1TSELx DMA

Página 99

8-20DMACTL1, DMA Control Register 115 14 13 12 11 10 9 80 0 0 0 0 0 0 0r0 r0 r0 r0 r0 r0 r0 r0765432100 0 0 0 0DMAONFETCHROUNDROBINENNMIr0 r0 r0 r0 r0

Página 100 - RISC 16−Bit CPU

8-21DMAxCTL, DMA Channel x Control Register15 14 13 12 11 10 9 8Reserved DMADTx DMADSTINCRx DMASRCINCRxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0

Página 101 - Instruction Set

2-1System Resets, Interrupts, and Operating Modes This chapter describes the MSP430x1xx system resets, in

Página 102

8-22DMASRCBYTEBit 6 DMA source byte. This bit selects the source as a byte or word.0 Word1 ByteDMALEVELBit 5 DMA level. This bit selects between edge-

Página 103

8-23DMAxDA, DMA Destination Address Register15 14 13 12 11 10 9 8DMAxDAxrw rw rw rw rw rw rw rw76543210DMAxDAxrw rw rw rw rw rw rw rwDMAxDAx Bits15−0D

Página 105

9-1Digital I/O ("*This chapter describes the operation of the digital I/O ports. Ports P1-P2 areimplemented in MSP430x11xx devices. Ports

Página 106

Digital I/O Introduction9-2Digital I/O9.1 Digital I/O IntroductionMSP430 devices have up to 6 digital I/O ports implemented, P1 - P6. Each porthas eig

Página 107

Digital I/O Operation9-3Digital I/O9.2 Digital I/O Operation The digital I/O is configured with user software. The setup and operation of thedigital I

Página 108

Digital I/O Operation9-4Digital I/O9.2.4 Function Select Registers PxSELPort pins are often multiplexed with other peripheral module functions. See th

Página 109

Digital I/O Operation9-5Digital I/O9.2.5 P1 and P2 InterruptsEach pin in ports P1 and P2 have interrupt capability, configured with thePxIFG, PxIE, an

Página 110

Digital I/O Operation9-6Digital I/OInterrupt Edge Select Registers P1IES, P2IESEach PxIES bit selects the interrupt edge for the corresponding I/O pin

Página 111 - → PC − − − −

Digital I/O Registers9-7Digital I/O9.3 Digital I/O Registers Seven registers are used to configure P1 and P2. Four registers are used toconfigure port

Página 112

IMPORTANT NOTICETexas Instruments Incorporated and its subsidiaries (TI) reserve the right to make corrections, modifications,enhancements, improvemen

Página 113 - Chapter 4

System Reset and Initialization2-2System Resets, Interrupts, and Operating Modes2.1 System Reset and InitializationThe system reset circuitry shown in

Página 114

9-8Digital I/O

Página 115 - Note: XT2 Oscillator

10-1Watchdog Timer + The watchdog timer is a 16-bit timer that can be used as a watchdog or as aninterval timer. This chapter describes t

Página 116 - Basic Clock Module

Watchdog Timer Introduction10-2Watchdog Timer10.1 Watchdog Timer IntroductionThe primary function of the watchdog timer (WDT) module is to perform aco

Página 117 - 4.2.2 LFXT1 Oscillator

Watchdog Timer Introduction10-3Watchdog TimerFigure 10−1. Watchdog Timer Block DiagramWDTQnY1234Q6Q9Q13Q1516−bitCounterCLKAB11AENPUCSMCLKACLKClearPass

Página 118 - Disabling the DCO

Watchdog Timer Operation10-4Watchdog Timer10.2 Watchdog Timer OperationThe WDT module can be configured as either a watchdog or interval timer withthe

Página 119 - Adjusting the DCO frequency

Watchdog Timer Operation10-5Watchdog Timer10.2.4 Watchdog Timer InterruptsThe WDT uses two bits in the SFRs for interrupt control.- The WDT interrupt

Página 120 - ) for the DCO

Watchdog Timer Operation10-6Watchdog Timer10.2.5 Operation in Low-Power ModesThe MSP430 devices have several low-power modes. Different clock signalsa

Página 121 - 4.2.5 DCO Modulator

Watchdog Timer Registers10-7Watchdog Timer10.3 Watchdog Timer RegistersThe watchdog timer module registers are listed in Table 10−1.Table 10−1.Watchdo

Página 122

Watchdog Timer Registers10-8Watchdog TimerWDTCTL, Watchdog Timer Register15 14 13 12 11 10 9 8Read as 069hWDTPW, must be written as 05Ah76543210WDTHOL

Página 123 - Oscillator Fault Detection

Watchdog Timer Registers10-9Watchdog TimerIE1, Interrupt Enable Register 176543210NMIIE WDTIErw−0 rw−0Bits7-5These bits may be used by other modules.

Página 124 - Sourcing MCLK from a Crystal

System Reset and Initialization2-3System Resets, Interrupts, and Operating Modes2.1.1 Power-On Reset (POR)When the VCC rise time is slow, the POR dete

Página 125

Watchdog Timer Registers10-10Watchdog TimerIFG1, Interrupt Flag Register 176543210NMIIFG WDTIFGrw−(0) rw−(0)Bits7-5These bits may be used by other mod

Página 126

11-1Timer_A ,)Timer_A is a 16-bit timer/counter with three capture/compare registers. Thischapter describes Timer_A. Timer_A is implemented in al

Página 127 - DCOCTL, DCO Control Register

Timer_A Introduction11-2Timer_A11.1 Timer_A IntroductionTimer_A is a 16-bit timer/counter with three capture/compare registers.Timer_A can support mul

Página 128 - SELMx DIVMx SELS DIVSx DCOR

Timer_A Introduction11-3Timer_AFigure 11−1. Timer_A Block DiagramCompararator 2CCI15 0CCISxOUTMODxCaptureModeCMxSyncSCSCOVlogicOutputUnit2DSetQEQU0OUT

Página 129 - Basic Clock Module Registers

Timer_A Operation11-4Timer_A11.2 Timer_A OperationThe Timer_A module is configured with user software. The setup andoperation of Timer_A is discussed

Página 130

Timer_A Operation11-5Timer_A11.2.2 Starting the TimerThe timer may be started, or restarted in the following ways:- The timer counts when MCx > 0 a

Página 131 - Chapter 5

Timer_A Operation11-6Timer_AUp ModeThe up mode is used if the timer period must be different from 0FFFFh counts.The timer repeatedly counts up to the

Página 132 - 5.1 Flash Memory Introduction

Timer_A Operation11-7Timer_AContinuous ModeIn the continuous mode, the timer repeatedly counts up to 0FFFFh and restartsfrom zero as shown in Figure 1

Página 133 - 5.2 Flash Memory Segmentation

Timer_A Operation11-8Timer_AUse of the Continuous ModeThe continuous mode can be used to generate independent time intervals andoutput frequencies. Ea

Página 134 - 5.3 Flash Memory Operation

Timer_A Operation11-9Timer_AUp/Down ModeThe up/down mode is used if the timer period must be different from 0FFFFhcounts, and if symmetrical pulse gen

Página 135 - Table 5−1.Erase Modes

System Reset and Initialization2-4System Resets, Interrupts, and Operating Modes2.1.2 Brownout Reset (BOR)Some devices have a brownout reset circuit (

Página 136

Timer_A Operation11-10Timer_AChanging the Period Register TACCR0When changing TACCR0 while the timer is running, and counting in the downdirection, th

Página 137 - Initiating an Erase from RAM

Timer_A Operation11-11Timer_A11.2.4 Capture/Compare BlocksThree identical capture/compare blocks, TACCRx, are present in Timer_A.Any of the blocks may

Página 138 - Byte/Word Write

Timer_A Operation11-12Timer_AFigure 11−11.Capture CycleSecondCaptureTakenCOV = 1CaptureTakenNoCaptureTakenReadTakenCaptureClear Bit COVin Register TAC

Página 139

Timer_A Operation11-13Timer_A11.2.5 Output UnitEach capture/compare block contains an output unit. The output unit is usedto generate output signals s

Página 140

Timer_A Operation11-14Timer_AOutput Example—Timer in Up ModeThe OUTx signal is changed when the timer counts up to the TACCRx value,and rolls from TAC

Página 141 - Block Write

Timer_A Operation11-15Timer_AOutput Example—Timer in Continuous ModeThe OUTx signal is changed when the timer reaches the TACCRx andTACCR0 values, dep

Página 142 - Figure 5−11. Block Write Flow

Timer_A Operation11-16Timer_AOutput Example—Timer in Up/Down ModeThe OUTx signal changes when the timer equals TACCRx in either countdirection and whe

Página 143

Timer_A Operation11-17Timer_A11.2.6 Timer_A InterruptsTwo interrupt vectors are associated with the 16-bit Timer_A module:- TACCR0 interrupt vector fo

Página 144

Timer_A Operation11-18Timer_ATAIV Software ExampleThe following software example shows the recommended use of TAIV and thehandling overhead. The TAIV

Página 145

Timer_A Registers11-19Timer_A11.3 Timer_A RegistersThe Timer_A registers are listed in Table 11−3:Table 11−3.Timer_A RegistersRegister Short Form Regi

Página 146 - Flash Memory Controller

System Reset and Initialization2-5System Resets, Interrupts, and Operating Modes2.1.3 Device Initial Conditions After System ResetAfter a POR, the ini

Página 147 - 5.4 Flash Memory Registers

Timer_A Registers11-20Timer_ATACTL, Timer_A Control Register15 14 13 12 11 10 9 8Unused TASSELxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)

Página 148

Timer_A Registers11-21Timer_ATAR, Timer_A Register15 14 13 12 11 10 9 8TARxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)76543210TARxrw−(0) r

Página 149

Timer_A Registers11-22Timer_ATACCTLx, Capture/Compare Control Register15 14 13 12 11 10 9 8CMx CCISx SCS SCCI Unused CAPrw−(0) rw−(0) rw−(0) rw−(0) rw

Página 150

Timer_A Registers11-23Timer_ACCIEBit 4 Capture/compare interrupt enable. This bit enables the interrupt request ofthe corresponding CCIFG flag.0 Inter

Página 152

12-1Timer_B ,Timer_B is a 16-bit timer/counter with multiple capture/compare registers. Thischapter describes Timer_B. Timer_B3 (three capture/c

Página 153 - Chapter 6

Timer_B Introduction12-2Timer_B12.1 Timer_B IntroductionTimer_B is a 16-bit timer/counter with three or seven capture/compareregisters. Timer_B can su

Página 154 - 6.1 SVS Introduction

Timer_B Introduction12-3Timer_BFigure 12−1. Timer_B Block DiagramCCR6Compararator 6CCI15 0OUTMODxCaptureModeCMxSyncCOVlogicOutputUnit6DSetQEQU0OUTOUT6

Página 155 - Figure 6−1. SVS Block Diagram

Timer_B Operation12-4Timer_B12.2 Timer_B OperationThe Timer_B module is configured with user software. The setup andoperation of Timer_B is discussed

Página 156 - 6.2 SVS Operation

Timer_B Operation12-5Timer_B12.2.2 Starting the TimerThe timer may be started or restarted in the following ways:- The timer counts when MCx > 0 an

Página 157 - 6.2.3 Changing the VLDx Bits

System Reset and Initialization2-6System Resets, Interrupts, and Operating Modes2.2 InterruptsThe interrupt priorities are fixed and defined by the ar

Página 158 - 6.2.4 SVS Operating Range

Timer_B Operation12-6Timer_BUp ModeThe up mode is used if the timer period must be different from TBR(max) counts.The timer repeatedly counts up to th

Página 159 - 6.3 SVS Registers

Timer_B Operation12-7Timer_BContinuous ModeIn continuous mode the timer repeatedly counts up to TBR(max) and restartsfrom zero as shown in Figure 12−4

Página 160 - Supply Voltage Supervisor

Timer_B Operation12-8Timer_BUse of the Continuous ModeThe continuous mode can be used to generate independent time intervals andoutput frequencies. Ea

Página 161 - Chapter 7

Timer_B Operation12-9Timer_BUp/Down ModeThe up/down mode is used if the timer period must be different from TBR(max)counts, and if symmetrical pulse g

Página 162

Timer_B Operation12-10Timer_BChanging the Value of Period Register TBCL0When changing TBCL0 while the timer is running, and counting in the downdirect

Página 163 - Table 7−1.OP1 addresses

Timer_B Operation12-11Timer_B12.2.4 Capture/Compare BlocksThree or seven identical capture/compare blocks, TBCCRx, are present inTimer_B. Any of the b

Página 164 - MACS Underflow and Overflow

Timer_B Operation12-12Timer_BFigure 12−11.Capture CycleSecondCaptureTakenCOV = 1CaptureTakenNoCaptureTakenReadTakenCaptureClear Bit COVin Register TBC

Página 165 - 7.2.3 Software Examples

Timer_B Operation12-13Timer_BCompare Latch TBCLxThe TBCCRx compare latch, TBCLx, holds the data for the comparison to thetimer value in compare mode.

Página 166 - 7.2.5 Using Interrupts

Timer_B Operation12-14Timer_B12.2.5 Output UnitEach capture/compare block contains an output unit. The output unit is usedto generate output signals s

Página 167

Timer_B Operation12-15Timer_BOutput Example—Timer in Up ModeThe OUTx signal is changed when the timer counts up to the TBCLx value, androlls from TBCL

Página 168 - Hardware Multiplier

System Reset and Initialization2-7System Resets, Interrupts, and Operating Modes2.2.1 (Non)-Maskable Interrupts (NMI)(Non)-maskable NMI interrupts are

Página 169 - () ""

Timer_B Operation12-16Timer_BOutput Example—Timer in Continuous ModeThe OUTx signal is changed when the timer reaches the TBCLx and TBCL0values, depen

Página 170 - 8.1 DMA Introduction

Timer_B Operation12-17Timer_BOutput Example − Timer in Up/Down ModeThe OUTx signal changes when the timer equals TBCLx in either countdirection and wh

Página 171

Timer_B Operation12-18Timer_B12.2.6 Timer_B InterruptsTwo interrupt vectors are associated with the 16-bit Timer_B module:- TBCCR0 interrupt vector fo

Página 172 - 8.2 DMA Operation

Timer_B Operation12-19Timer_BTBIV, Interrupt Handler ExamplesThe following software example shows the recommended use of TBIV and thehandling overhead

Página 173 - Table 8−1.DMA Transfer Modes

Timer_B Registers12-20Timer_B12.3 Timer_B RegistersThe Timer_B registers are listed in Table 12−5:Table 12−5.Timer_B RegistersRegister Short Form Regi

Página 174 - Single Transfer

Timer_B Registers12-21Timer_BTimer_B Control Register TBCTL15 14 13 12 11 10 9 8Unused TBCLGRPx CNTLx Unused TBSSELxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0)

Página 175

Timer_B Registers12-22Timer_BUnusedBit 3 UnusedTBCLRBit 2 Timer_B clear. Setting this bit resets TBR, the TBCLK divider, and the countdirection. The T

Página 176 - Block Transfers

Timer_B Registers12-23Timer_BTBCCTLx, Capture/Compare Control Register15 14 13 12 11 10 9 8CMx CCISx SCS CLLDx CAPrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) r

Página 177

Timer_B Registers12-24Timer_BCCIEBit 4 Capture/compare interrupt enable. This bit enables the interrupt request ofthe corresponding CCIFG flag.0 Inter

Página 178 - Burst-Block Transfers

Timer_B Registers12-25Timer_BTBIV, Timer_B Interrupt Vector Register15 14 13 12 11 10 9 80 0 0 0 0 0 0 0r0 r0 r0 r0 r0 r0 r0 r0765432100 0 0 0 TBIVx 0

Página 179

System Reset and Initialization2-8System Resets, Interrupts, and Operating ModesFigure 2−5. Block Diagram of (Non)-Maskable Interrupt SourcesFlash Mod

Página 181

13-1USART Peripheral Interface, UART Mode !) " - !)The universal synchronous/asynchronous receive/transmit (USART)

Página 182 - 8.2.5 DMA Channel Priorities

USART Introduction: UART Mode13-2USART Peripheral Interface, UART Mode13.1 USART Introduction: UART ModeIn asynchronous mode, the USART connects the M

Página 183 - 8.2.6 DMA Transfer Cycle Time

USART Introduction: UART Mode13-3USART Peripheral Interface, UART ModeFigure 13−1. USART Block Diagram: UART ModeReceiver Shift RegisterTransmit Shift

Página 184

USART Operation: UART Mode13-4USART Peripheral Interface, UART Mode13.2 USART Operation: UART ModeIn UART mode, the USART transmits and receives chara

Página 185 - 8.2.9 Using the I

USART Operation: UART Mode13-5USART Peripheral Interface, UART Mode13.2.3 Asynchronous Communication FormatsWhen two devices communicate asynchronousl

Página 186 - 8.3 DMA Registers

USART Operation: UART Mode13-6USART Peripheral Interface, UART ModeThe URXWIE bit is used to control data reception in the idle-linemultiprocessor for

Página 187

USART Operation: UART Mode13-7USART Peripheral Interface, UART ModeAddress-Bit Multiprocessor FormatWhen MM = 1, the address-bit multiprocessor format

Página 188

USART Operation: UART Mode13-8USART Peripheral Interface, UART ModeAutomatic Error DetectionGlitch suppression prevents the USART from being accidenta

Página 189

USART Operation: UART Mode13-9USART Peripheral Interface, UART Mode13.2.4 USART Receive EnableThe receive enable bit, URXEx, enables or disables data

Página 190

System Reset and Initialization2-9System Resets, Interrupts, and Operating ModesFlash Access ViolationThe flash ACCVIFG flag is set when a flash acces

Página 191

USART Operation: UART Mode13-10USART Peripheral Interface, UART Mode13.2.5 USART Transmit EnableWhen UTXEx is set, the UART transmitter is enabled. Tr

Página 192

USART Operation: UART Mode13-11USART Peripheral Interface, UART Mode13.2.6 UART Baud Rate GenerationThe USART baud rate generator is capable of produc

Página 193 - ("*

USART Operation: UART Mode13-12USART Peripheral Interface, UART ModeBaud Rate Bit TimingThe first stage of the baud rate generator is the 16-bit count

Página 194 - 9.1 Digital I/O Introduction

USART Operation: UART Mode13-13USART Peripheral Interface, UART ModeTransmit Bit TimingThe timing for each character is the sum of the individual bit

Página 195 - 9.2 Digital I/O Operation

USART Operation: UART Mode13-14USART Peripheral Interface, UART ModeReceive Bit TimingReceive timing consists of two error sources. The first is the b

Página 196 - Digital I/O

USART Operation: UART Mode13-15USART Peripheral Interface, UART ModeFor example, the receive errors for the following conditions are calculated:Baud r

Página 197 - 9.2.5 P1 and P2 Interrupts

USART Operation: UART Mode13-16USART Peripheral Interface, UART ModeTypical Baud Rates and ErrorsStandard baud rate frequency data for UxBRx and UxMCT

Página 198 - Interrupt Enable P1IE, P2IE

USART Operation: UART Mode13-17USART Peripheral Interface, UART Mode13.2.7 USART InterruptsThe USART has one interrupt vector for transmission and one

Página 199 - 9.3 Digital I/O Registers

USART Operation: UART Mode13-18USART Peripheral Interface, UART ModeUSART Receive Interrupt OperationThe URXIFGx interrupt flag is set each time a cha

Página 200

USART Operation: UART Mode13-19USART Peripheral Interface, UART ModeReceive-Start Edge Detect OperationThe URXSE bit enables the receive start-edge de

Página 201 - + 

System Reset and Initialization2-10System Resets, Interrupts, and Operating ModesExample of an NMI Interrupt HandlerThe NMI interrupt is a multiple-so

Página 202

USART Operation: UART Mode13-20USART Peripheral Interface, UART ModeReceive-Start Edge Detect ConditionsWhen URXSE = 1, glitch suppression prevents th

Página 203 - Watchdog Timer

USART Registers: UART Mode13-21USART Peripheral Interface, UART Mode13.3 USART Registers: UART ModeTable 13−3 lists the registers for all devices impl

Página 204 - 10.2 Watchdog Timer Operation

USART Registers: UART Mode13-22USART Peripheral Interface, UART ModeUxCTL, USART Control Register76543210PENA PEV SPB CHAR LISTEN SYNC MM SWRSTrw−0 rw

Página 205 - Watchdog Timer Operation

USART Registers: UART Mode13-23USART Peripheral Interface, UART ModeUxTCTL, USART Transmit Control Register76543210Unused CKPL SSELx URXSE TXWAKE Unus

Página 206 - 10.2.6 Software Examples

USART Registers: UART Mode13-24USART Peripheral Interface, UART ModeUxRCTL, USART Receive Control Register76543210FE PE OE BRK URXEIE URXWIE RXWAKE RX

Página 207 - 10.3 Watchdog Timer Registers

USART Registers: UART Mode13-25USART Peripheral Interface, UART ModeUxBR0, USART Baud Rate Control Register 0765432102726252423222120rw rw rw rw rw rw

Página 208

USART Registers: UART Mode13-26USART Peripheral Interface, UART ModeUxRXBUF, USART Receive Buffer Register765432102726252423222120r r r r r r r rUxRXB

Página 209 - Watchdog Timer Registers

USART Registers: UART Mode13-27USART Peripheral Interface, UART ModeME1, Module Enable Register 176543210UTXE0†URXE0†rw−0 rw−0UTXE0†Bit 7 USART0 trans

Página 210

USART Registers: UART Mode13-28USART Peripheral Interface, UART ModeIE1, Interrupt Enable Register 176543210UTXIE0†URXIE0†rw−0 rw−0UTXIE0†Bit 7 USART0

Página 211 - Chapter 11

USART Registers: UART Mode13-29USART Peripheral Interface, UART ModeIFG1, Interrupt Flag Register 176543210UTXIFG0†URXIFG0†rw−1 rw−0UTXIFG0†Bit 7 USAR

Página 212 - 11.1 Timer_A Introduction

System Reset and Initialization2-11System Resets, Interrupts, and Operating ModesEach individual peripheral interrupt is discussed in the associated p

Página 213 - Timer_A Introduction

USART Registers: UART Mode13-30USART Peripheral Interface, UART ModeUTXIFG0‡Bit 1 USART0 transmit interrupt flag. UTXIFG0 is set when U0TXBUF is empty

Página 214 - 11.2 Timer_A Operation

13-31USART Peripheral Interface, UART Mode

Página 215 - Table 11−1.Timer Modes

14-1USART Peripheral Interface, SPI Mode !)"-The universal synchronous/asynchronous receive/transmit (USART)perip

Página 216 - Figure 11−2. Up Mode

USART Introduction: SPI Mode14-2USART Peripheral Interface, SPI Mode14.1 USART Introduction: SPI ModeIn synchronous mode, the USART connects the MSP43

Página 217 - Figure 11−4. Continuous Mode

USART Introduction: SPI Mode14-3USART Peripheral Interface, SPI ModeFigure 14−1. USART Block Diagram: SPI ModeReceiver Shift RegisterTransmit Shift Re

Página 218 - Use of the Continuous Mode

USART Operation: SPI Mode14-4USART Peripheral Interface, SPI Mode14.2 USART Operation: SPI ModeIn SPI mode, serial data is transmitted and received by

Página 219 - Figure 11−7. Up/Down Mode

USART Operation: SPI Mode14-5USART Peripheral Interface, SPI Mode14.2.2 Master ModeFigure 14−2. USART Master and External SlaveReceive Buffer UxRXBUFR

Página 220 - Use of the Up/Down Mode

USART Operation: SPI Mode14-6USART Peripheral Interface, SPI Mode14.2.3 Slave ModeFigure 14−3. USART Slave and External MasterReceive Buffer UxRXBUFRe

Página 221 - Capture Mode

USART Operation: SPI Mode14-7USART Peripheral Interface, SPI Mode14.2.4 SPI EnableThe SPI transmit/receive enable bit USPIEx enables or disables the U

Página 222 - Compare Mode

USART Operation: SPI Mode14-8USART Peripheral Interface, SPI ModeReceive EnableThe SPI receive enable state diagrams are shown in Figure 14−6 andFigur

Página 223 - Table 11−2.Output Modes

Related Documentation From Texas Instrumentsiii PrefaceAbout This ManualThis manual discusses modules and peripherals of the MSP430x1x

Página 224 - Timer_A Operation

System Reset and Initialization2-12System Resets, Interrupts, and Operating ModesReturn From InterruptThe interrupt handling routine terminates with t

Página 225

USART Operation: SPI Mode14-9USART Peripheral Interface, SPI Mode14.2.5 Serial Clock ControlUCLK is provided by the master on the SPI bus. When MM = 1

Página 226

USART Operation: SPI Mode14-10USART Peripheral Interface, SPI ModeSerial Clock Polarity and PhaseThe polarity and phase of UCLK are independently conf

Página 227 - TACCR0 Interrupt

USART Operation: SPI Mode14-11USART Peripheral Interface, SPI Mode14.2.6 SPI InterruptsThe USART has one interrupt vector for transmission and one int

Página 228

USART Operation: SPI Mode14-12USART Peripheral Interface, SPI ModeSPI Receive Interrupt OperationThe URXIFGx interrupt flag is set each time a charact

Página 229 - 11.3 Timer_A Registers

USART Registers: SPI Mode14-13USART Peripheral Interface, SPI Mode14.3 USART Registers: SPI ModeThe USART registers, shown in Table 14−1 and Table 14−

Página 230

USART Registers: SPI Mode14-14USART Peripheral Interface, SPI ModeUxCTL, USART Control Register76543210Unused Unused I2C†CHAR LISTEN SYNC MM SWRSTrw−0

Página 231 - TAR, Timer_A Register

USART Registers: SPI Mode14-15USART Peripheral Interface, SPI ModeUxTCTL, USART Transmit Control Register76543210CKPH CKPL SSELx Unused Unused STC TXE

Página 232

USART Registers: SPI Mode14-16USART Peripheral Interface, SPI ModeUxRCTL, USART Receive Control Register76543210FE Unused OE Unused Unused Unused Unus

Página 233

USART Registers: SPI Mode14-17USART Peripheral Interface, SPI ModeUxBR0, USART Baud Rate Control Register 0765432102726252423222120rw rw rw rw rw rw r

Página 234

USART Registers: SPI Mode14-18USART Peripheral Interface, SPI ModeUxRXBUF, USART Receive Buffer Register765432102726252423222120r r r r r r r rUxRXBUF

Página 235 - Chapter 12

System Reset and Initialization2-13System Resets, Interrupts, and Operating Modes2.2.4 Interrupt VectorsThe interrupt vectors and the power-up startin

Página 236 - 12.1 Timer_B Introduction

USART Registers: SPI Mode14-19USART Peripheral Interface, SPI ModeME1, Module Enable Register 176543210USPIE0†rw−0Bit 7 This bit may be used by other

Página 237 - Timer_B Introduction

USART Registers: SPI Mode14-20USART Peripheral Interface, SPI ModeIE1, Interrupt Enable Register 176543210UTXIE0†URXIE0†rw−0 rw−0UTXIE0†Bit 7 USART0 t

Página 238 - 12.2 Timer_B Operation

USART Registers: SPI Mode14-21USART Peripheral Interface, SPI ModeUTXIE0‡Bit 1 USART0 transmit interrupt enable. This bit enables the UTXIFG0 interrup

Página 239 - Table 12−1.Timer Modes

USART Registers: SPI Mode14-22USART Peripheral Interface, SPI ModeIFG1, Interrupt Flag Register 176543210UTXIFG0†URXIFG0†rw−1 rw−0UTXIFG0†Bit 7 USART0

Página 240 - Figure 12−2. Up Mode

14-23USART Peripheral Interface, SPI Mode

Página 241 - Figure 12−4. Continuous Mode

15-1USART Peripheral Interface, I2C Mode !) " - . The universal synchronous/asynchronous receive/transmit (USART)p

Página 242

I2C Module Introduction15-2USART Peripheral Interface, I2C Mode15.1 I2C Module IntroductionThe inter-IC control (I2C) module provides an interface bet

Página 243 - Figure 12−7. Up/Down Mode

I2C Module Introduction15-3USART Peripheral Interface, I2C ModeFigure 15−1. USART Block Diagram: I2C ModeReceive Shift RegisterTransmit Shift Register

Página 244

I2C Module Operation15-4USART Peripheral Interface, I2C Mode15.2 I2C Module OperationThe I2C module supports any slave or master I2C-compatible device

Página 245 - 12.2.4 Capture/Compare Blocks

I2C Module Operation15-5USART Peripheral Interface, I2C Mode15.2.1 I2C Module InitializationThe I2C module is part of the USART peripheral. Individual

Página 246 - Figure 12−11.Capture Cycle

Operating Modes2-14System Resets, Interrupts, and Operating Modes2.3 Operating ModesThe MSP430 family is designed for ultralow-power applications and

Página 247 - Table 12−2.TBCLx Load Events

I2C Module Operation15-6USART Peripheral Interface, I2C Mode15.2.2 I2C Serial DataOne clock pulse is generated by the master device for each data bitt

Página 248 - Table 12−4.Output Modes

I2C Module Operation15-7USART Peripheral Interface, I2C Mode15.2.3 I2C Addressing ModesThe I2C module supports 7-bit and 10-bit addressing modes.7-Bit

Página 249 - Timer_B Operation

I2C Module Operation15-8USART Peripheral Interface, I2C Mode15.2.4 I2C Module Operating ModesThe I2C module operates in master transmitter, master rec

Página 250

I2C Module Operation15-9USART Peripheral Interface, I2C ModeFigure 15−8. Master Transmitter ModeIDLEGenerate STARTI2CBUSY Is Set4 x I2CPSCI2CBB Is Set

Página 251

I2C Module Operation15-10USART Peripheral Interface, I2C ModeFigure 15−9. Master Receiver ModeIDLEGenerate START4 x I2CPSCI2CBB Is SetI2CSTT Is Cleare

Página 252 - 12.2.6 Timer_B Interrupts

I2C Module Operation15-11USART Peripheral Interface, I2C ModeArbitrationIf two or more master transmitters simultaneously start a transmission on theb

Página 253

I2C Module Operation15-12USART Peripheral Interface, I2C ModeAutomatic Data Byte CountingAutomatic data byte counting is supported in master mode with

Página 254 - 12.3 Timer_B Registers

I2C Module Operation15-13USART Peripheral Interface, I2C ModeFigure 15−11.Slave TransmitterI2CBB Is ClearedSend DataLow ByteTo Master2nd StartDetected

Página 255

I2C Module Operation15-14USART Peripheral Interface, I2C ModeFigure 15−12. Slave ReceiverIDLEI2CBB Is Cleared4 x I2CPSCYesReceive DataLow ByteFrom Mas

Página 256 - TBR, Timer_B Register

I2C Module Operation15-15USART Peripheral Interface, I2C Mode15.2.5 The I2C Data Register I2CDRThe I2CDR register can be accessed as an 8-bit or 16-bi

Página 257

Operating Modes2-15System Resets, Interrupts, and Operating ModesFigure 2−10. MSP430x1xx Operating Modes For Basic Clock SystemActive ModeCPU Is Activ

Página 258

I2C Module Operation15-16USART Peripheral Interface, I2C Mode15.2.6 I2C Clock Generation and SynchronizationThe I2C module is operated with the clock

Página 259

I2C Module Operation15-17USART Peripheral Interface, I2C Mode15.2.7 Using the I2C Module with Low Power ModesThe I2C module can be used with MSP430 lo

Página 260

I2C Module Operation15-18USART Peripheral Interface, I2C Mode15.2.8 I2C InterruptsThe I2C module has one interrupt vector for eight interrupt flags li

Página 261 - Chapter 13

I2C Module Operation15-19USART Peripheral Interface, I2C ModeI2CIV, Interrupt Vector GeneratorThe I2C interrupt flags are prioritized and combined to

Página 262

I2C Module Registers15-20USART Peripheral Interface, I2C Mode15.3 I2C Module RegistersThe I2C module registers are listed in Table 15−4.Table 15−4.I2C

Página 263 - USART Introduction: UART Mode

I2C Module Registers15-21USART Peripheral Interface, I2C ModeU0CTL, USART0 Control Register-I2C Mode76543210RXDMAEN TXDMAEN I2C XA LISTEN SYNC MST I2C

Página 264 - Figure 13−2. Character Format

I2C Module Registers15-22USART Peripheral Interface, I2C ModeI2CTCTL, I2C Transmit Control Register76543210I2CWORD I2CRM I2CSSELx I2CTRX I2CSTB I2CSTP

Página 265 - Figure 13−3. Idle-Line Format

I2C Module Registers15-23USART Peripheral Interface, I2C ModeI2CDCTL, I2C Data Control Register76543210Unused Unused I2CBUSYI2CSCLLOWI2CSBD I2CTXUDF I

Página 266 - USART Operation: UART Mode

I2C Module Registers15-24USART Peripheral Interface, I2C ModeI2CDRW, I2CDRB, I2C Data Register15 14 13 12 11 10 9 8I2CDRW High Byterw−0 rw−0 rw−0 rw−0

Página 267

I2C Module Registers15-25USART Peripheral Interface, I2C ModeI2CPSC, I2C Clock Prescaler Register76543210I2CPSCxrw−0 rw−0 rw−0 rw−0 rw−0 rw−0 rw−0 rw−

Página 268 - Automatic Error Detection

Operating Modes2-16System Resets, Interrupts, and Operating Modes2.3.1 Entering and Exiting Low-Power ModesAn enabled interrupt event wakes the MSP430

Página 269 - 13.2.4 USART Receive Enable

I2C Module Registers15-26USART Peripheral Interface, I2C ModeI2CSCLH, I2C Shift Clock High Register76543210I2CSCLHxrw−0 rw−0 rw−0 rw−0 rw−0 rw−0 rw−0

Página 270 - 13.2.5 USART Transmit Enable

I2C Module Registers15-27USART Peripheral Interface, I2C ModeI2COA, I2C Own Address Register, 7-Bit Addressing Mode15 14 13 12 11 10 9 80 0 0 0 0 0 0

Página 271

I2C Module Registers15-28USART Peripheral Interface, I2C ModeI2CSA, I2C Slave Address Register, 7-Bit Addressing Mode15 14 13 12 11 10 9 80 0 0 0 0 0

Página 272 - Baud Rate Bit Timing

I2C Module Registers15-29USART Peripheral Interface, I2C ModeI2CIE, I2C Interrupt Enable Register76543210STTIE GCIE TXRDYIE RXRDYIE ARDYIE OAIE NACKIE

Página 273 - Transmit Bit Timing

I2C Module Registers15-30USART Peripheral Interface, I2C ModeI2CIFG, I2C Interrupt Flag Register76543210STTIFG GCIFG TXRDYIFG RXRDYIFG ARDYIFG OAIFG N

Página 274 - Figure 13−9. Receive Error

I2C Module Registers15-31USART Peripheral Interface, I2C ModeI2CIV, I2C Interrupt Vector Register15 14 13 12 11 10 9 80 0 0 0 0 0 0 0r0 r0 r0 r0 r0 r0

Página 275

15-32USART Peripheral Interface, I2C Mode

Página 276 - Typical Baud Rates and Errors

16-1Comparator_A ,)Comparator_A is an analog voltage comparator. This chapter describesComparator_A. Comparator_A is implemented in MSP430x1

Página 277 - 13.2.7 USART Interrupts

Comparator_A Introduction16-2Comparator_A16.1 Comparator_A IntroductionThe comparator_A module supports precision slope analog-to-digitalconversions,

Página 278

Comparator_A Introduction16-3Comparator_AFigure 16−1. Comparator_A Block DiagramCAOUT+−CAEX0.5x0.25xSet_CAIFGCA1CCI1B+−0VGDSP2CA0P2CA1CAFCARSELCAONCAR

Página 279

Principles for Low-Power Applications2-17System Resets, Interrupts, and Operating Modes2.4 Principles for Low-Power ApplicationsOften, the most import

Página 280

Comparator_A Operation16-4Comparator_A16.2 Comparator_A Operation The comparator_A module is configured with user software. The setup andoperation of

Página 281

Comparator_A Operation16-5Comparator_A16.2.3 Output FilterThe output of the comparator can be used with or without internal filtering.When control bit

Página 282 - UxCTL, USART Control Register

Comparator_A Operation16-6Comparator_A16.2.5 Comparator_A, Port Disable Register CAPDThe comparator input and output functions are multiplexed with th

Página 283

Comparator_A Operation16-7Comparator_A16.2.7 Comparator_A Used to Measure Resistive ElementsThe Comparator_A can be optimized to precisely measure res

Página 284

Comparator_A Operation16-8Comparator_AThe thermistor measurement is based on a ratiometric conversion principle.The ratio of two capacitor discharge t

Página 285 - USART Registers: UART Mode

Comparator_A Registers16-9Comparator_A16.3 Comparator_A RegistersThe Comparator_A registers are listed in Table 16−1:Table 16−1.Comparator_A Registers

Página 286 - UxTXBUFx

Comparator_A Registers16-10Comparator_ACACTL1, Comparator_A Control Register 176543210CAEX CARSEL CAREFx CAON CAIES CAIE CAIFGrw−(0) rw−(0) rw−(0) rw−

Página 287 - ME2, Module Enable Register 2

Comparator_A Registers16-11Comparator_ACACTL2, Comparator_A, Control Register76543210Unused P2CA1 P2CA0 CAF CAOUTrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw

Página 288

16-12Comparator_A

Página 289

17-1ADC12 )(.The ADC12 module is a high-performance 12-bit analog-to-digital converter.This chapter describes the ADC12. The ADC12 is implemented in

Página 290

2-18System Resets, Interrupts, and Operating Modes

Página 291

ADC12 Introduction17-2ADC1217.1 ADC12 IntroductionThe ADC12 module supports fast, 12-bit analog-to-digital conversions. Themodule implements a 12-bit

Página 292 - Chapter 14

ADC12 Introduction17-3ADC12Figure 17−1. ADC12 Block DiagramSampleandHoldVeREF+12−bit SARVR−−16 x 12MemoryBuffer−−16 x 8MemoryControl−VR+VREF+VeREF−VRE

Página 293

ADC12 Operation17-4ADC1217.2 ADC12 OperationThe ADC12 module is configured with user software. The setup and operationof the ADC12 is discussed in the

Página 294 - USART Introduction: SPI Mode

ADC12 Operation17-5ADC1217.2.2 ADC12 Inputs and MultiplexerThe eight external and four internal analog signals are selected as the channelfor conversi

Página 295

ADC12 Operation17-6ADC1217.2.3 Voltage Reference GeneratorThe ADC12 module contains a built-in voltage reference with two selectablevoltage levels, 1.

Página 296 - Four-Pin SPI Master Mode

ADC12 Operation17-7ADC1217.2.5 Sample and Conversion TimingAn analog-to-digital conversion is initiated with a rising edge of the sampleinput signal S

Página 297 - Four-Pin SPI Slave Mode

ADC12 Operation17-8ADC12Pulse Sample ModeThe pulse sample mode is selected when SHP = 1. The SHI signal is used totrigger the sampling timer. The SHT0

Página 298 - Transmit Enable

ADC12 Operation17-9ADC12Sample Timing ConsiderationsWhen SAMPCON = 0 all Ax inputs are high impedance. When SAMPCON =1, the selected Ax input can be m

Página 299 - Receive Enable

ADC12 Operation17-10ADC1217.2.6 Conversion MemoryThere are 16 ADC12MEMx conversion memory registers to store conversionresults. Each ADC12MEMx is conf

Página 300 - 14.2.5 Serial Clock Control

ADC12 Operation17-11ADC12Single-Channel Single-Conversion ModeA single channel is sampled and converted once. The ADC result is written tothe ADC12MEM

Página 301 - Figure 14−9. USART SPI Timing

3-1RISC 16-Bit CPU   !This chapter describes the MSP430 CPU, addressing modes, and instructionset.Topic Page3.1 CPU Introduction 3-2. .

Página 302 - 14.2.6 SPI Interrupts

ADC12 Operation17-12ADC12Sequence-of-Channels ModeA sequence of channels is sampled and converted once. The ADC results arewritten to the conversion m

Página 303 - USART Operation: SPI Mode

ADC12 Operation17-13ADC12Repeat-Single-Channel ModeA single channel is sampled and converted continuously. The ADC results arewritten to the ADC12MEMx

Página 304

ADC12 Operation17-14ADC12Repeat-Sequence-of-Channels ModeA sequence of channels is sampled and converted repeatedly. The ADCresults are written to the

Página 305

ADC12 Operation17-15ADC12Using the Multiple Sample and Convert (MSC) BitTo configure the converter to perform successive conversions automaticallyand

Página 306

ADC12 Operation17-16ADC1217.2.8 Using the Integrated Temperature SensorTo use the on-chip temperature sensor, the user selects the analog inputchannel

Página 307

ADC12 Operation17-17ADC1217.2.9 ADC12 Grounding and Noise ConsiderationsAs with any high-resolution ADC, appropriate printed-circuit-board layout andg

Página 308 - USART Registers: SPI Mode

ADC12 Operation17-18ADC1217.2.10 ADC12 InterruptsThe ADC12 has 18 interrupt sources:- ADC12IFG0-ADC12IFG15- ADC12OV, ADC12MEMx overflow- ADC12TOV, ADC

Página 309

ADC12 Operation17-19ADC12ADC12 Interrupt Handling Software ExampleThe following software example shows the recommended use of ADC12IVand the handling

Página 310

ADC12 Registers17-20ADC1217.3 ADC12 RegistersThe ADC12 registers are listed in Table 17−2:Table 17−2.ADC12 RegistersRegister Short Form Register Type

Página 311

ADC12 Registers17-21ADC12ADC12CTL0, ADC12 Control Register 015 14 13 12 11 10 9 8SHT1x SHT0xrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)765

Página 312

CPU Introduction3-2RISC 16-Bit CPU3.1 CPU Introduction The CPU incorporates features specifically designed for modernprogramming techniques such as ca

Página 313

ADC12 Registers17-22ADC12MSCBit 7 Multiple sample and conversion. Valid only for sequence or repeated modes.0 The sampling timer requires a rising edg

Página 314

ADC12 Registers17-23ADC12ADC12CTL1, ADC12 Control Register 115 14 13 12 11 10 9 8CSTARTADDx SHSx SHP ISSHrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−

Página 315 - Chapter 15

ADC12 Registers17-24ADC12ADC12SSELxBits4-3ADC12 clock source select00 ADC12OSC01 ACLK10 MCLK11 SMCLKCONSEQxBits2-1Conversion sequence mode select00 Si

Página 316 - C Module Introduction

ADC12 Registers17-25ADC12ADC12MCTLx, ADC12 Conversion Memory Control Registers76543210EOS SREFx INCHxrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)

Página 317 - USART Peripheral Interface, I

ADC12 Registers17-26ADC12ADC12IE, ADC12 Interrupt Enable Register15 14 13 12 11 10 9 8ADC12IE15 ADC12IE14 ADC12IE13 ADC12IE12 ADC12IE11 ADC12IE10 ADC1

Página 318 - C Module Operation

ADC12 Registers17-27ADC12ADC12IV, ADC12 Interrupt Vector Register15 14 13 12 11 10 9 80 0 0 0 0 0 0 0r0 r0 r0 r0 r0 r0 r0 r0765432100 0 ADC12IVx 0r0 r

Página 320

18-1ADC10 )(/The ADC10 module is a high-performance 10-bit analog-to-digital converter.This chapter describes the ADC10. The ADC10 is implemented in

Página 321

ADC10 Introduction18-2ADC1018.1 ADC10 IntroductionThe ADC10 module supports fast, 10-bit analog-to-digital conversions. Themodule implements a 10-bit

Página 322 - Table 15−1.Master Operation

ADC10 Introduction18-3ADC10Figure 18−1. ADC10 Block Diagram100110000010000100110100010101100111SampleandHold10−bit SAR Divider/1 .. /8ACLKMCLKSMCLKADC

Página 323

CPU Introduction3-3RISC 16-Bit CPUFigure 3−1. CPU Block Diagram015MDB − Memory Data Bus Memory Address Bus − MAB16Zero, ZCarry, COverflow, VNegative,

Página 324

ADC10 Operation18-4ADC1018.2 ADC10 OperationThe ADC10 module is configured with user software. The setup and operationof the ADC10 is discussed in the

Página 325

ADC10 Operation18-5ADC1018.2.2 ADC10 Inputs and MultiplexerThe eight external and four internal analog signals are selected as the channelfor conversi

Página 326 - Slave Mode

ADC10 Operation18-6ADC1018.2.3 Voltage Reference GeneratorThe ADC10 module contains a built-in voltage reference with two selectablevoltage levels. Se

Página 327

ADC10 Operation18-7ADC1018.2.5 Sample and Conversion TimingAn analog-to-digital conversion is initiated with a rising edge of sample inputsignal SHI.

Página 328 - Figure 15−12. Slave Receiver

ADC10 Operation18-8ADC10Sample Timing ConsiderationsWhen SAMPCON = 0 all Ax inputs are high impedance. When SAMPCON =1, the selected Ax input can be m

Página 329 - Receive Overrun

ADC10 Operation18-9ADC1018.2.6 Conversion ModesThe ADC10 has four operating modes selected by the CONSEQx bits asdiscussed in Table 18−1.Table 18−1.Co

Página 330

ADC10 Operation18-10ADC10Single-Channel Single-Conversion ModeA single channel selected by INCHx is sampled and converted once. The ADCresult is writt

Página 331 - C Module with Low Power Modes

ADC10 Operation18-11ADC10Sequence-of-Channels ModeA sequence of channels is sampled and converted once. The sequencebegins with the channel selected b

Página 332 - Table 15−3.I

ADC10 Operation18-12ADC10Repeat-Single-Channel ModeA single channel selected by INCHx is sampled and converted continuously.Each ADC result is written

Página 333 - RETI ; Vector 0: No interrupt

ADC10 Operation18-13ADC10Repeat-Sequence-of-Channels ModeA sequence of channels is sampled and converted repeatedly. The sequencebegins with the chann

Página 334 - C Module Registers

GlossaryivGlossaryACLK Auxiliary Clock See Basic Clock ModuleADC Analog-to-Digital ConverterBOR Brown-Out Reset See System Resets, Interrupts, and Ope

Página 335

CPU Registers3-4RISC 16-Bit CPU3.2 CPU RegistersThe CPU incorporates sixteen 16-bit registers. R0, R1, R2 and R3 havededicated functions. R4 to R15 ar

Página 336 - C Transmit Control Register

ADC10 Operation18-14ADC10Using the MSC BitTo configure the converter to perform successive conversions automaticallyand as quickly as possible, a mult

Página 337 - C Data Control Register

ADC10 Operation18-15ADC1018.2.7 ADC10 Data Transfer ControllerThe ADC10 includes a data transfer controller (DTC) to automatically transferconversion

Página 338 - I2CNDAT, I

ADC10 Operation18-16ADC10One-Block Transfer ModeThe one-block mode is selected if the ADC10TB is reset. The value n inADC10DTC1 defines the total numb

Página 339 - C Clock Prescaler Register

ADC10 Operation18-17ADC10Figure 18−10. State Diagram for Data Transfer Control in One-Block Transfer ModeDTC idleDTC resetn=0 (ADC10DTC1)InitializeSta

Página 340 - C Shift Clock Low Register

ADC10 Operation18-18ADC10Two-Block Transfer ModeThe two-block mode is selected if the ADC10TB bit is set. The value n inADC10DTC1 defines the number o

Página 341 - I2COA, I

ADC10 Operation18-19ADC10Figure 18−12. State Diagram for Data Transfer Control in Two-Block Transfer ModeDTC idleDTC resetADC10B1 = 0ADC10TB = 1n=0 (A

Página 342 - I2CSA, I

ADC10 Operation18-20ADC10Continuous TransferA continuous transfer is selected if ADC10CT bit is set. The DTC will not stopafter block one in (one-bloc

Página 343 - C Interrupt Enable Register

ADC10 Operation18-21ADC1018.2.8 Using the Integrated Temperature SensorTo use the on-chip temperature sensor, the user selects the analog inputchannel

Página 344 - C Interrupt Flag Register

ADC10 Operation18-22ADC1018.2.9 ADC10 Grounding and Noise ConsiderationsAs with any high-resolution ADC, appropriate printed-circuit-board layout andg

Página 345 - C Interrupt Vector Register

ADC10 Operation18-23ADC1018.2.10 ADC10 InterruptsOne interrupt and one interrupt vector are associated with the ADC10 asshown in Figure 18−17. When th

Página 346

CPU Registers3-5RISC 16-Bit CPU3.2.2 Stack Pointer (SP)The stack pointer (SP/R1) is used by the CPU to store the return addressesof subroutine calls a

Página 347 - ,)

ADC10 Registers18-24ADC1018.3 ADC10 RegistersThe ADC10 registers are listed in Table 18−3.Table 18−3.ADC10 RegistersRegister Short Form Register Type

Página 348

ADC10 Registers18-25ADC10ADC10CTL0, ADC10 Control Register 015 14 13 12 11 10 9 8SREFx ADC10SHTx ADC10SR REFOUT REFBURSTrw−(0) rw−(0) rw−(0) rw−(0) rw

Página 349 - Comparator_A

ADC10 Registers18-26ADC10MSCBit 7 Multiple sample and conversion. Valid only for sequence or repeated modes.0 The sampling requires a rising edge of t

Página 350 - 16.2 Comparator_A Operation

ADC10 Registers18-27ADC10ADC10CTL1, ADC10 Control Register 115 14 13 12 11 10 9 8INCHx SHSx ADC10DF ISSHrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(

Página 351 - 16.2.3 Output Filter

ADC10 Registers18-28ADC10ADC10DIVxBits7-5ADC10 clock divider000 /1001 /2010 /3011 /4100 /5101 /6110 /7111 /8ADC10SSELxBits4-3ADC10 clock source select

Página 352

ADC10 Registers18-29ADC10ADC10MEM, Conversion-Memory Register, Binary Format15 14 13 12 11 10 9 80 0 0 0 0 0 Conversion Resultsr0 r0 r0 r0 r0 r0 r r76

Página 353

ADC10 Registers18-30ADC10ADC10DTC0, Data Transfer Control Register 076543210Reserved ADC10TB ADC10CT ADC10B1ADC10FETCHr0 r0 r0 r0 rw−(0) rw−(0) rw−(0)

Página 354

ADC10 Registers18-31ADC10ADC10DTC1, Data Transfer Control Register 176543210DTC Transfersrw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0) rw−(0)DTCTra

Página 356

19-1DAC12 ().The DAC12 module is a 12-bit, voltage output digital-to-analog converter. Thischapter describes the DAC12. Two DAC12 modules are implem

Página 357

CPU Registers3-6RISC 16-Bit CPU3.2.3 Status Register (SR)The status register (SR/R2), used as a source or destination register, can beused in the regi

Página 358

DAC12 Introduction19-2DAC1219.1 DAC12 IntroductionThe DAC12 module is a 12-bit, voltage output DAC. The DAC12 can beconfigured in 8- or 12-bit mode an

Página 359 - Chapter 17

DAC12 Introduction19-3DAC12Figure 19−1. DAC12 Block DiagramDAC12_0DAC12_0OUT2.5V or 1.5V reference from ADC12DAC12SREFxVR−VR+DAC12_0DATDAC12_0LatchDAC

Página 360 - 17.1 ADC12 Introduction

DAC12 Operation19-4DAC1219.2 DAC12 OperationThe DAC12 module is configured with user software. The setup and operationof the DAC12 is discussed in the

Página 361 - ADC12 Introduction

DAC12 Operation19-5DAC1219.2.2 DAC12 ReferenceThe reference for the DAC12 is configured to use either an external referencevoltage or the internal 1.5

Página 362 - 17.2 ADC12 Operation

DAC12 Operation19-6DAC1219.2.4 DAC12_xDAT Data FormatThe DAC12 supports both straight binary and 2’s compliment data formats.When using straight binar

Página 363 - Analog Port Selection

DAC12 Operation19-7DAC1219.2.5 DAC12 Output Amplifier Offset CalibrationThe offset voltage of the DAC12 output amplifier can be positive or negative.W

Página 364 - 17.2.4 Auto Power-Down

DAC12 Operation19-8DAC1219.2.6 Grouping Multiple DAC12 ModulesMultiple DAC12s can be grouped together with the DAC12GRP bit tosynchronize the update o

Página 365 - Extended Sample Mode

DAC12 Operation19-9DAC1219.2.7 DAC12 InterruptsThe DAC12 interrupt vector is shared with the DMA controller. Software mustcheck the DAC12IFG and DMAIF

Página 366 - Pulse Sample Mode

DAC12 Registers19-10DAC1219.3 DAC12 RegistersThe DAC12 registers are listed in Table 19−2:Table 19−2.DAC12 RegistersRegister Short Form Register Type

Página 367 - Sample Timing Considerations

DAC12 Registers19-11DAC12DAC12_xCTL, DAC12 Control Register15 14 13 12 11 10 9 8Reserved DAC12SREFx DAC12RES DAC12LSELxDAC12CALONDAC12IRrw−(0) rw−(0)

Página 368 - 17.2.7 ADC12 Conversion Modes

CPU Registers3-7RISC 16-Bit CPU3.2.4 Constant Generator Registers CG1 and CG2Six commonly-used constants are generated with the constant generatorregi

Página 369 - x = pointer to ADC12MCTLx

DAC12 Registers19-12DAC12DAC12AMPxBits7-5DAC12 amplifier setting. These bits select settling time vs. currentconsumption for the DAC12 input and outpu

Página 370 - Sequence-of-Channels Mode

DAC12 Registers19-13DAC12DAC12_xDAT, DAC12 Data Register15 14 13 12 11 10 9 80 0 0 0 DAC12 Datar(0) r(0) r(0) r(0) rw−(0) rw−(0) rw−(0) rw−(0)76543210

Página 372

CPU Registers3-8RISC 16-Bit CPU3.2.5 General−Purpose Registers R4 - R15The twelve registers, R4−R15, are general-purpose registers. All of theseregist

Página 373 - Stopping Conversions

Addressing Modes3-9RISC 16-Bit CPU3.3 Addressing ModesSeven addressing modes for the source operand and four addressing modesfor the destination opera

Página 374 - ADC12 Operation

Addressing Modes3-10RISC 16-Bit CPU3.3.1 Register ModeThe register mode is described in Table 3−4.Table 3−4.Register Mode DescriptionAssembler Code Co

Página 375

Addressing Modes3-11RISC 16-Bit CPU3.3.2 Indexed ModeThe indexed mode is described in Table 3−5.Table 3−5.Indexed Mode DescriptionAssembler Code Conte

Página 376 - 17.2.10 ADC12 Interrupts

Addressing Modes3-12RISC 16-Bit CPU3.3.3 Symbolic ModeThe symbolic mode is described in Table 3−6.Table 3−6.Symbolic Mode DescriptionAssembler Code Co

Página 377

Addressing Modes3-13RISC 16-Bit CPU3.3.4 Absolute ModeThe absolute mode is described in Table 3−7.Table 3−7.Absolute Mode DescriptionAssembler Code Co

Página 378 - 17.3 ADC12 Registers

Register Bit Conventionsv Register Bit ConventionsEach register is shown with a key indicating the accessibility of the eachindividual bit, and the

Página 379

Addressing Modes3-14RISC 16-Bit CPU3.3.5 Indirect Register ModeThe indirect register mode is described in Table 3−8.Table 3−8.Indirect Mode Descriptio

Página 380

Addressing Modes3-15RISC 16-Bit CPU3.3.6 Indirect Autoincrement ModeThe indirect autoincrement mode is described in Table 3−9.Table 3−9.Indirect Autoi

Página 381

Addressing Modes3-16RISC 16-Bit CPU3.3.7 Immediate ModeThe immediate mode is described in Table 3−10.Table 3−10.Immediate Mode DescriptionAssembler Co

Página 382

Instruction Set3-17RISC 16-Bit CPU3.4 Instruction SetThe complete MSP430 instruction set consists of 27 core instructions and 24emulated instructions.

Página 383 - Modifiable only when ENC = 0

Instruction Set3-18RISC 16-Bit CPU3.4.1 Double-Operand (Format I) InstructionsFigure 3−9 illustrates the double-operand instruction format.Figure 3−9.

Página 384 - ADC12IFGx

Instruction Set3-19RISC 16-Bit CPU3.4.2 Single-Operand (Format II) InstructionsFigure 3−10 illustrates the single-operand instruction format.Figure 3−

Página 385 - ADC12 interrupt vector value

Instruction Set3-20RISC 16-Bit CPU3.4.3 JumpsFigure 3−11 shows the conditional-jump instruction format.Figure 3−11. Jump Instruction FormatC 10-Bit PC

Página 386

Instruction Set3-21 RISC 16−Bit CPUADC[.W] Add carry to destinationADC.B Add carry to destinationSyntax ADC dst or ADC.W dstADC.B dstOper

Página 387 - Chapter 18

Instruction Set3-22 RISC 16−Bit CPUADD[.W] Add source to destinationADD.B Add source to destinationSyntax ADD src,dst or ADD.W src,dstADD.B src,dstOp

Página 388 - 18.1 ADC10 Introduction

Instruction Set3-23 RISC 16−Bit CPUADDC[.W] Add source and carry to destinationADDC.B Add source and carry to destinationSyntax ADDC src,dst or ADDC.

Página 390 - 18.2 ADC10 Operation

Instruction Set3-24 RISC 16−Bit CPUAND[.W] Source AND destinationAND.B Source AND destinationSyntax AND src,dst or AND.W src,dstAND.B src,dstOperation

Página 391

Instruction Set3-25 RISC 16−Bit CPUBIC[.W] Clear bits in destinationBIC.B Clear bits in destinationSyntax BIC src,dst or BIC.W src,dstBIC.B src,dstOp

Página 392 - 18.2.4 Auto Power-Down

Instruction Set3-26 RISC 16−Bit CPUBIS[.W] Set bits in destinationBIS.B Set bits in destinationSyntax BIS src,dst or BIS.W src,dstBIS.B src,dstOperati

Página 393 - Figure 18−3. Sample Timing

Instruction Set3-27 RISC 16−Bit CPUBIT[.W] Test bits in destinationBIT.B Test bits in destinationSyntax BIT src,dst or BIT.W src,dstOperation src .AN

Página 394

Instruction Set3-28 RISC 16−Bit CPU* BR, BRANCH Branch to ... destinationSyntax BR dstOperation dst −> PCEmulation MOV dst,PCDescription An

Página 395 - 18.2.6 Conversion Modes

Instruction Set3-29 RISC 16−Bit CPUCALL SubroutineSyntax CALL dstOperation dst −> tmp dst is evaluated and storedSP − 2 −> SPPC −> @S

Página 396

Instruction Set3-30 RISC 16−Bit CPU* CLR[.W] Clear destination* CLR.B Clear destinationSyntax CLR dst or CLR.W dstCLR.B dstOperation 0 −> dstEmulat

Página 397

Instruction Set3-31 RISC 16−Bit CPU* CLRC Clear carry bitSyntax CLRCOperation 0 −> CEmulation BIC #1,SRDescription The carry bit (C) is cleared.

Página 398

Instruction Set3-32 RISC 16−Bit CPU* CLRN Clear negative bitSyntax CLRNOperation 0 → Nor(.NOT.src .AND. dst −> dst)Emulation BIC #4,SRDescription

Página 399

Instruction Set3-33 RISC 16−Bit CPU* CLRZ Clear zero bitSyntax CLRZOperation 0 → Zor(.NOT.src .AND. dst −> dst)Emulation BIC #2,SRDescription The

Página 400 - Using the MSC Bit

Contentsvii 1 Introduction 1-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Página 401 - ADC10 Operation

Instruction Set3-34 RISC 16−Bit CPUCMP[.W] Compare source and destinationCMP.B Compare source and destinationSyntax CMP src,dst or CMP.W src,dstCMP.

Página 402 - One-Block Transfer Mode

Instruction Set3-35 RISC 16−Bit CPU* DADC[.W] Add carry decimally to destination* DADC.B Add carry decimally to destinationSyntax DADC dst or D

Página 403

Instruction Set3-36 RISC 16−Bit CPUDADD[.W] Source and carry added decimally to destinationDADD.B Source and carry added decimally to destinationSynt

Página 404 - Two-Block Transfer Mode

Instruction Set3-37 RISC 16−Bit CPU* DEC[.W] Decrement destination* DEC.B Decrement destinationSyntax DEC dst or DEC.W dstDEC.B dstOperation dst −

Página 405

Instruction Set3-38 RISC 16−Bit CPU* DECD[.W] Double-decrement destination* DECD.B Double-decrement destinationSyntax DECD dst or DECD.W ds

Página 406 - DTC Transfer Cycle Time

Instruction Set3-39 RISC 16−Bit CPU* DINT Disable (general) interruptsSyntax DINTOperation 0 → GIEor(0FFF7h .AND. SR → SR / .NOT.src .AND. dst −>

Página 407

Instruction Set3-40 RISC 16−Bit CPU* EINT Enable (general) interruptsSyntax EINTOperation 1 → GIEor(0008h .OR. SR −> SR / .src .OR. dst −> dst

Página 408

Instruction Set3-41 RISC 16−Bit CPU* INC[.W] Increment destination* INC.B Increment destinationSyntax INC dst or INC.W dstINC.B dstOperation dst + 1

Página 409 - 18.2.10 ADC10 Interrupts

Instruction Set3-42 RISC 16−Bit CPU* INCD[.W] Double-increment destination* INCD.B Double-increment destinationSyntax INCD dst or INCD.W dstINCD.B dst

Página 410 - 18.3 ADC10 Registers

Instruction Set3-43 RISC 16−Bit CPU* INV[.W] Invert destination* INV.B Invert destinationSyntax INV dstINV.B dstOperation .NOT.dst −> dstEmulation

Página 411

Contentsviii3 RISC 16-Bit CPU 3-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Página 412

Instruction Set3-44 RISC 16−Bit CPUJC Jump if carry setJHS Jump if higher or sameSyntax JC labelJHS labelOperation If C = 1: PC + 2 × offset −> PCI

Página 413

Instruction Set3-45 RISC 16−Bit CPUJEQ, JZ Jump if equal, jump if zeroSyntax JEQ label, JZ labelOperation If Z = 1: PC + 2 × offset −> PCIf Z = 0

Página 414

Instruction Set3-46 RISC 16−Bit CPUJGE Jump if greater or equalSyntax JGE labelOperation If (N .XOR. V) = 0 then jump to label: PC + 2 × offset −>

Página 415

Instruction Set3-47 RISC 16−Bit CPUJL Jump if lessSyntax JL labelOperation If (N .XOR. V) = 1 then jump to label: PC + 2 × offset −> PCIf (N .XOR

Página 416

Instruction Set3-48 RISC 16−Bit CPUJMP Jump unconditionallySyntax JMP labelOperation PC + 2 × offset −> PCDescription The 10-bit signed offset con

Página 417

Instruction Set3-49 RISC 16−Bit CPUJN Jump if negativeSyntax JN labelOperation if N = 1: PC + 2 × offset −> PCif N = 0: execute following instruc

Página 418

Instruction Set3-50 RISC 16−Bit CPUJNC Jump if carry not setJLO Jump if lowerSyntax JNC labelJLO labelOperation if C = 0: PC + 2 × offset −> PCif C

Página 419 - Chapter 19

Instruction Set3-51 RISC 16−Bit CPUJNE Jump if not equalJNZ Jump if not zeroSyntax JNE labelJNZ labelOperation If Z = 0: PC + 2 × offset −> PCIf Z

Página 420 - 19.1 DAC12 Introduction

Instruction Set3-52 RISC 16−Bit CPUMOV[.W] Move source to destinationMOV.B Move source to destinationSyntax MOV src,dst or MOV.W src,d

Página 421 - DAC12 Introduction

Instruction Set3-53 RISC 16−Bit CPU* NOP No operationSyntax NOPOperation NoneEmulation MOV #0, R3Description No operation is performed. The instruct

Página 422 - 19.2 DAC12 Operation

Contentsix 6 Supply Voltage Supervisor 6-1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Página 423 - 19.2.2 DAC12 Reference

Instruction Set3-54 RISC 16−Bit CPU* POP[.W] Pop word from stack to destination* POP.B Pop byte from stack to destinationSyntax POP dstPOP.B dstOper

Página 424 - 19.2.4 DAC12_xDAT Data Format

Instruction Set3-55 RISC 16−Bit CPUPUSH[.W] Push word onto stackPUSH.B Push byte onto stackSyntax PUSH src or PUSH.W srcPUSH.B srcOper

Página 425 - Figure 19−5. Positive Offset

Instruction Set3-56 RISC 16−Bit CPU* RET Return from subroutineSyntax RETOperation @SP→ PCSP + 2 → SPEmulation MOV @SP+,PCDescription The return addre

Página 426

Instruction Set3-57 RISC 16−Bit CPURETI Return from interruptSyntax RETIOperation TOS → SRSP + 2 → SPTOS → PCSP + 2 → SPDescription The status regis

Página 427 - 19.2.7 DAC12 Interrupts

Instruction Set3-58 RISC 16−Bit CPU* RLA[.W] Rotate left arithmetically* RLA.B Rotate left arithmeticallySyntax RLA dst or RLA.W dstRLA.B dstOperatio

Página 428 - 19.3 DAC12 Registers

Instruction Set3-59 RISC 16−Bit CPU* RLC[.W] Rotate left through carry* RLC.B Rotate left through carrySyntax RLC dst or RLC.W dstRLC.B dstOperation

Página 429

Instruction Set3-60 RISC 16−Bit CPURRA[.W] Rotate right arithmeticallyRRA.B Rotate right arithmeticallySyntax RRA dst or RRA.W dstRRA.B dstOperation M

Página 430

Instruction Set3-61 RISC 16−Bit CPURRC[.W] Rotate right through carryRRC.B Rotate right through carrySyntax RRC dst or RRC.W dstRRC dstOperation C −&

Página 431

Instruction Set3-62 RISC 16−Bit CPU* SBC[.W] Subtract source and borrow/.NOT. carry from destination* SBC.B Subtract source and borrow/.NOT. carry fro

Página 432

Instruction Set3-63 RISC 16−Bit CPU* SETC Set carry bitSyntax SETCOperation 1 −> CEmulation BIS #1,SRDescription The carry bit (C) is set.Status

Comentários a estes Manuais

Sem comentários