Course Hero has millions of student submitted documents similar to the one
below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.
Find millions of documents on Course Hero - Study Guides, Lecture Notes, Reference Materials, Practice Exams and more.
Course Hero has millions of course specific materials providing students with the best way to expand
their education.
Below is a small sample set of documents:
BYU - CS - 124
132Chapter 5used in comparison, arithmetic, and logic operations and for masks to pick out bits 03. It is no accident that the most commonly tested bits in the status register are in these positions (Figure 5.3) and the same is true for registers in oth
BYU - CS - 124
Architecture of the MSP430 Processor153If you use C, you could try writing the code for the shift register in a more elegant way than the preceding snippet. This treats the register as a byte for the shift but as bits to insert the new value. Would a un
BYU - CS - 124
CHAPTER 5Architecture of the MSP430 ProcessorThe chapter describes the central processing unit (CPU) of the MSP430 and its most closely associated modules, the clock generator and reset circuitry. The earlier parts of the chapter, which cover the CPU an
BYU - CS - 124
186Chapter 6Check first to see whether an intrinsic function is available to do the job without leaving C. Many of these are declared in the header file intrinsics.h to perform functions that are not possible in standard C. For example, the _ _swap_byte
BYU - CS - 124
CHAPTER 6Functions, Interrupts, and Low-Power ModesA well-structured program should be divided into separate modules-functions in C or subroutines in assembly language. There is nothing special about this in embedded systems. If you wish to write subrou
BYU - CS - 124
330Chapter 8by one interval of two cycles. (The frequency would be 877.7 Hz if this pattern were the exact output.) The two durations are clear on the oscilloscope trace. The signal sounds terrible and is quite unusable, even if its average frequency is
BYU - CS - 124
CHAPTER 8TimersMost modern microcontrollers provide a range of timers and the MSP430 is no exception. All devices contain two types of timer and some have five. Each type of timer module works in essentially the same way in all devices. Timer_A is ident
BYU - CS - 124
Mixed-Signal Systems: Analog Input and Output393Schmitt trigger and interrupts on standard digital inputs can be used for the measurement instead of a comparator.9.2Analog-to-Digital Conversion: General IssuesAlthough Comparator_A produces digital va
BYU - CS - 124
Mixed-Signal Systems: Analog Input and Output Example 9.12475Modify Listing 9.12 so that the intensity of the LED responds to the ambient light in the opposite way: The LED gets brighter as the surroundings become darker. It is a lot easier to test this
BYU - CS - 124
534Chapter 10transmission. The results were strange because of the problems that I mentioned in the section "Digital Input and Output: Parallel Ports" on page 208. Enabling the pull resistor removes the full drive from the pin, so the sharp edges in Fig
BYU - CS - 124
Chapter 10Watchdog Timer+The watchdog timer+ (WDT+) is a 16-bit timer that can be used as a watchdog or as an interval timer. This chapter describes the WDT+ The WDT+ is implemented in all MSP430x2xx devices.TopicPage10.1 Watchdog Timer+ Introduction
BYU - CS - 124
Negative Numbers and Binary SubtractionWe have seen how simple logic gates can perform the process of binary addition. It is only logical to assume that a similar circuit could perform binary subtraction. If we look at the possibilites involved in subtra
BYU - CS - 124
Chapter 3RISC 16 Bit CPUThis chapter describes the MSP430 CPU, addressing modes, and instruction set.Topic3.1 3.2 3.3 3.4PageCPU Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-2 CPU Registers
BYU - CS - 124
The 1-to-2 Line Decoder/DemultiplexerThe opposite of the multiplexer circuit, logically enough, is the demultiplexer. This circuit takes a single data input and one or more address inputs, and selects which of multiple outputs will receive the input sign
BYU - CS - 124
The Two-Input MultiplexerOne circuit I've received a number of requests for is the multiplexer circuit. This is a digital circuit with multiple signal inputs, one of which is selected by separate address inputs to be sent to the single output. It's not e
BYU - CS - 124
Prefix b c l n p w dw f fn fp t g u Type BYTE charUsage Signed 8-bit value Signed 8-bit value (usually an ASCII character) long Signed 32-bit value int Signed 16-bit value U16 : pointer Generic prefix for a pointer to the next type U16 : WORD Unsigned
BYU - CS - 124
Chapter 5 MSP430 ISA The Instruction SetTopics to Cover.n n n n n n n nMSP430 ISA Instruction Formats Double Operand Instructions Single Operand Instructions Jump Instructions Addressing Modes Instruction Disassembly Emulated InstructionsBYU CS/ECEnC
BYU - CS - 124
Clock accuracy in ppmCrystal Clock accuracy is defined in terms of ppm or parts per million and it gives a convenient way of comparing accuracies of different crystal specifications. . The following headings give practical calculations showing the typica
BYU - CS - 124
CS/ECEn 124, W2012 Homework #1 Abstraction (Ch 2)Questions:NameSectionScore/ 41Answers:1. (3 points) Can a higher level programming language instruct a computer to compute more than a lower level programming language? Explain.2. (3 points) Name th
BYU - CS - 124
CS/ECEn 124, W2012 Homework #2 Digital Logic (Ch 3)Questions:NameSectionScore/ 38Answers:1. (4 points) How many select lines and how many output lines do the following multiplexers have? a. b. c. d. 32-input multiplexer 16-input multiplexer 5-input
BYU - CS - 124
CS/ECEn 124, W2012 Homework #3 Digital Logic (Ch 3)Questions:NameSectionScore/46Answers:1. (10 points) Identify the type of logic (combinational or sequential) for each of the following: a. ALU b. D-latch c. Decoder d. Driver e. Flip-Flop f. Invert
BYU - CS - 124
CS/ECEn 124, W2012 Homework #4 Von Neumann (Ch 4) MSP430 ISA (Ch 5)Questions:NameSectionScore/ 47Answers:1. (11 points) For each statement below, indicate if a CISC or RISC architecture is best described: a. b. c. d. e. f. g. h. i. j. k. Cheaper pr
BYU - CS - 124
CS/ECEn 124, W2012 Homework #7 Stacks (Ch 8) Interrupts (9)Questions:NameSectionScore/ 36Answers:1. (3 points) Define subroutine cohesion. What properties of cohesion should be found in your subroutines?2. (3 points) Define subroutine coupling. Wh
BYU - CS - 124
An introduction to the TI MSP430 low-power microcontrollers OverviewThe MSP430 is a very clean 16-bit byte-addressed processor with a 64K unified address space, and memorymapped peripherals. The current family includes a variety of on-chip peripherals, a
BYU - CS - 124
AN-1023APPLICATION NOTEOne Technology Way P.O. Box 9106 Norwood, MA 02062-9106, U.S.A. Tel: 781.329.4700 Fax: 781.461.3113 www.analog.comFall Detection Application by Using 3-Axis Accelerometer ADXL345by Ning JiaINTRODUCTIONADXL345 MEMS ACCELEROMETE
BYU - CS - 124
AN-1025APPLICATION NOTEOne Technology Way P.O. Box 9106 Norwood, MA 02062-9106, U.S.A. Tel: 781.329.4700 Fax: 781.461.3113 www.analog.comUtilization of the First In, First Out (FIFO) Buffer in Analog Devices, Inc.Digital Accelerometersby Christopher
BYU - CS - 124
3-Axis, 2 g/4 g/8 g/16 g Digital Accelerometer ADXL345FEATURESUltralow power: as low as 40 A in measurement mode and 0.1 A in standby mode at VS = 2.5 V (typical) Power consumption scales automatically with bandwidth User-selectable resolution Fixed 10-
BYU - CS - 124
AccelerometersFantasy & RealityBy Harvey Weinberg [harvey.weinberg@analog.com]As applications engineers supporting ADIs compact, low-cost, gravity-sensitive iMEMsaccelerometers, we get to hear lots of creative ideas about how to employ accelerometers i
BYU - CS - 124
Adding Binary NumbersA key requirement of digital computers is the ability to use logical functions toperform arithmetic operations. The basis of this is addition; if we can add twobinary numbers, we can just as easily subtract them, or get a little fa
BYU - CS - 124
ASCII Chart012345670NULDLESP0@P`p1SOHDC1!1AQaq2STXDC2"2BRbr3ETXDC3#3CScsOr here's another chart:4EOTDC4$4DTdt5ENQNAK%5EUeu6ACKSYN&6FVfv7BELETB'7GWgw8BSCAN(8HXhx9HT
BYU - CS - 124
Basic Logical Functions andGatesWhile each logical element or condition must always have a logic value ofeither "0" or "1", we also need to have ways to combine different logical signalsor conditions to provide a logical result.For example, consider
BYU - CS - 124
Boolean AlgebraOne of the primary requirements when dealing with digital circuits is to findways to make them as simple as possible. This constantly requires that complexlogical expressions be reduced to simpler expressions that nevertheless produceth
BYU - CS - 124
PrefixbclnpwdwffnfptguTypeBYTEcharUsageSigned 8-bit valueSigned 8-bit value (usually anASCII character)longSigned 32-bit valueintSigned 16-bit valueU16 : pointerGeneric prefix for a pointer to thenext typeU16 : WORDUnsigned 16
BYU - CS - 124
Node:Top, Next:Preface, Previous:(dir), Up:(dir)C Programming Tutorial (K&R version 4)This is a C Programming Tutorial for people who have a little experience with aninterpreted programming language, such as Emacs Lisp or a GNU shell.Edition 4.02Copy
BYU - CS - 124
Formatting with printfThe example program above does not produce a very neat layout on the screen. Theconversion specifiers in the printf string can be extended to give more information.The % and the character type act like brackets around the extra in
BYU - CS - 124
Arrays as ParametersWhat happens if we want to pass an array as a parameter? Does the program copy theentire array into local storage? The answer is no because it would be a waste of timeand memory. Arrays can be passed as parameters, but only as varia
BYU - CS - 124
feof()This function returns a true or false result. It tests whether or not the end of a file hasbeen reached and if it has it returns `true' (which has any value except zero); otherwisethe function returns `false' (which has the value zero). The form
BYU - CS - 124
Listing Cref.c123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354/*//**//* C programming utility : variable referencer*//**//*//* See notes abov
BYU - CS - 124
Clock accuracy in ppmCrystal Clock accuracy is defined in terms of ppm or parts per million and it gives a convenient way ofcomparing accuracies of different crystal specifications..The following headings give practical calculations showing the typica
BYU - CS - 124
/- CRC functions -/u_long crc32_table[256];/* Initialized first time "crc32()" is called. If you prefer, you can* statically initialize it at compile time. [Another exercise.]*/u_long crc32(u_char *buf, int len)cfw_u_char *p;u_long crc;if (!crc32
BYU - CS - 124
INTRODUCTION TO COMPUTING SYSTEMSCS/ECEn 124 Course SyllabusWinter 2012Instructor: Paul RoperOffice: 3370 TMCB, 422-8149Office Hours: MWF 9:00-10:50 AMEmail: proper@cs.byu.eduSection 001Section 002Help SessionsMWF 1:00-1:50 PMMWF 3:00-3:50 PMM
BYU - CS - 124
A Guide to DebouncingAugust 2004Rev 1: April, 2006Rev 2: April, 2007Rev 3: June, 2008Jack G. Gansslejack@ganssle.comThe Ganssle GroupPO Box 38346Baltimore, MD 21231(410) 504-6660fax (647) 439-1454 2004 The Ganssle Group. This work may be used
BYU - CS - 124
Derived Logical Functions andGatesWhile the three basic functions AND, OR, and NOT are sufficient toaccomplish all possible logical functions and operations, some combinations areused so commonly that they have been given names and logic symbols of th
BYU - CS - 124
Deriving the XOR FunctionOn the previous page we stated that the Exclusive-OR, or XOR function can bedescribed verbally as, "Either A or B, but not both." In the realm of digital logicthere are several ways of stating this in a more detailed and precis
BYU - CS - 124
Digital LogicDigital or binary logic has fascinated many people over the years. The very idea that atwo-valued number system can possibly be the basis for the most powerful andsophisticated computers seems astounding, to say the least. Nevertheless, it
BYU - CS - 124
The replacement parts/accessories for the eZ430X Development Board are available at the BYU ECEn StockRoom (416 CB) as follows:DescriptionLCD DisplayServoTransponderJumperThermistorDevelopment BoardSound ModulePartLCD - NHD-C160100DiZ-FSW-FBWT
BYU - CS - 124
MSP-FET430 Flash Emulation Tool (FET) (for Use With Code Composer Essentials for MSP430 Version 3.1)User's GuideLiterature Number: SLAU157I May 2005 Revised February 20092SLAU157I May 2005 Revised February 2009 Submit Documentation FeedbackContentsP
BYU - CS - 124
FM24CL6464Kb Serial 3V F-RAM MemoryFeatures64K bit Ferroelectric Nonvolatile RAM Organized as 8,192 x 8 bits Unlimited Read/Write Cycles 45 year Data Retention NoDelay Writes Advanced High-Reliability Ferroelectric ProcessFast Two-wire Serial Int
BYU - CS - 124
The Function Pointer TutorialsIntroduction to C and C+ Function Pointers, Callbacks and Functorswritten by Lars HaendelJanuary 2005, Bochum, Germanyhttp:/www.newty.deemail: Have a look at the web page pleaseversion 2.07Copyright (c) 2000-2005 by La
BYU - CS - 124
REV C (February 22, 2010)Secondary (L)HDEFIIIOPin SignalSW_2ADXL345 INT1/2SW_4LCD BacklightPrimary (R)P2.0 (ACLK/A0)P2.1 (SMCLK/A1)P2.2 (TA0/A2)P2.3 (TA1/A3)P2.4 (TA2/A4)P2.6P2.7XIN - GDO0 (O)XOUT - GDO2 (O)IIIOOOOP3.0 (UCB
BYU - CS - 124
Hex File FormatsThis appendix describes the Intel hex object format and the TI-txt file format.The Intel hex object format supports 16-bit addresses and consists of a 9-character (4-field) prefix that defines the start ofrecord, byte count, load addres
BYU - CS - 124
How to Access FRAM.The FM24CL64 is a 64-kilobit nonvolatile memory employing an advancedferroelectric process. A ferroelectric random access memory or F-RAM is nonvolatileand performs reads and writes like a RAM. It provides reliable data retention for
BYU - CS - 124
How to Change Clock Speed.The MSP430 addresses the conflicting demands for high performance, lowpower, and a precise frequency by using three internal clocks, which can bederived from up to four sources. These are the internal clocks, which are thesam
BYU - CS - 124
How To Change The Processor Clock.The MSP430 was designed to power-up quickly from low-power mode withouthaving to wait a long time for the clock to settle. The Digitally ControlledOscillator (DCO) of the MSP430F2274 is an accurate and stable clock tha
BYU - CS - 124
How to Condition an Analog Signal.An analog-to-digital converter (abbreviated ADC, A/D or A to D) is a device whichconverts continuous analog signals to discrete digital numbers. Due to the finiteresolution and the unavoidable imperfections in all type
BYU - CS - 124
How To Control a Servo.What is a Servo?A servo is a small device that has a rotating output shaft. This shaft can bepositioned to specific angular positions by sending the servo a coded signal.As long as the coded signal exists on the input line, the
BYU - CS - 124
How To Debounce A Switch.A switch is a mechanical device that "opens" and "closes" a circuit. Theswitches on the eZ430X board are normally open, letting the inputs be pulledhigh (a logic one) by the internal MSP430 port pull-up resistors. A closed ord
BYU - CS - 124
How to Determine the Length of a String.A C string can be created from a binary data type by using the sprintf() function. Byincluding the standard C I/O library ("#include <stdio.h>" and defining a characterarray of sufficient size for the string, the
BYU - CS - 124
How to Draw a Continuous Line.A continuous line is drawn if neither the delta x nor delta y is greater than 1 pixel. Inthe following example, the x value always increments by 1 while the y value onlydecrements by 1 when needed to conform to the "ideal"
BYU - CS - 124
How to Draw Images and Text on theLCD.The New Haven NHD-C160100DiZ-FSW-FBW LCM (Liquid Crystal DisplayGraphic Module) is a 160 column x 100 row, 16-level dot, reflective, LiquidCrystal Display with a side white LED backlight. Display data and commands
BYU - CS - 124
How to Draw Various Shapes.Draw a circle on the LCD by calling:void lcd_circle(int x0, int y0, int r0, int pen);wherex0, y0 = coordinates of the center of the circler0 = radius of circlepen = pen value (0 = erase, 1 = single line)Example:lcd_circl