Download introduction to msp430 and more Lecture notes Microprocessors in PDF only on Docsity!
EEM336 Microprocessors I
Dr. Hakan Şenel
Eskisehir Technical University
Electrical Engineering Department
Eskişehir, Turkey
Course Objectives
- To describe embedded systems and their components
- To understand principles of microcontroller architecture
- To program in assembly language.
- To program embedded systems in C Language.
- To master data structures and subroutine calls
- To start writing programs in C language
- To describe polling, interrupts and resets
- To explain I/O, timing and communications
- To understand inter-chip communication, sensor
interfacing.
Important Notes
- You will be given lab boards to you. You are supposed to do your experiments at home, i.e. home- experiment. You are encouraged to colloborate with your classmates. You have no restrictions. More colloborations, more you get from this course.
- There will be a quiz just before each Lab session. You are required to receive at least 50% of the quiz grade. Otherwise, you will be dismissed and get null.
- In the lab session, you will be asked to finish a task that is very similar to lab-homework.
- At the end of the course, you will return the lab board back to lab assistants.
- You can buy the lab boards on your own on TI.COM
Lab Assistants
- There will be no lab assistants assigned. You are
supposed to finish the lab work with the
instructor.
- Lab quizes must last at most 10 minutes. If the
answer takes more time, send an e-mail.
- If you fail 3 lab quizes, you will be dismissed
from the lab.
- During lab sessions, you can not collaborate with
your classmates. You are on your own!!! If we
understand that lab work you have done is copied
from someone else, you will get 0.
Weekly Program
- Week 1: General introduction
- Week 2: Introduction to microcontrollers, Addressing modes,
- Week 3: Assembly Instructions, Arithmetic operations, branch instructions
- Week 4: Assembly Instructions, multiplication and division
- Week 5: Stack and subroutines, stack frame, parameter passing, GPIO
- Week 6: Midterm 1 (Mostly about assembly programming)
- Week 7: I/O system, interfacing with LEDs, buttons, etc
- Week 8 : Interrupt based I/O
- Week 9: Introduction to Timers
- Week 10: Timers (Input Capture, Output Compare)
- Week 11: Realtime clock, watchdog timer
- Week 12: Midterm 2 (About interrupts, timers, GPIO)
- Week 13: Sensors, Analog to Digital Conversion
- Week 14: ADC Examples (GPIO + Timers + ADC)
- Final Exam: About almost everything.
Sources
- Main Source
- Introduction to Embedded Systems: Using Microcontrollers and the MSP430, Manuel Jiménez
- Rogelio Palomera, Isidoro Couvertier, Springer
- Alternative source:
- MSP430 Microcontroller Basics, John H. Davies,
- http://www.ti.com/tool/MSP-EXP430FR
- http://www.ti.com/product/MSP430FR
What is a Computer?
- In early days, computers were human clerks who
calculated using certain methods.
- Human clerks are replaced by electronic
computing machines that exist in every part of our lives.
- During the late 1940s and early 1950s, the phrase
'computing machine' gradually gave way simply to 'computer’.
- Nowadays, hard computing tasks are handled by
electronic computing machines and their names are abbreviated as «computers».
What’s a Computer?
- A machine capable of executing instructions
on data.
- What distinguishes a computer is its ability
to store its own instructions.
- In general, a computer (computing machined)
is a general purpose device (mechanical or
electro-mechanical or electronic) that can be
programmed to carry out a set of arithmetic
or logical operations automatically.
Turing Machine
- He proved that some such machine would be capable of
performing any conceivable mathematical computation if it were representable as an algorithm.
- He described an abstract digital computing machine
consisting of a limitless memory and a scanner that moves back and forth through the memory, symbol by symbol (i.e. instructions), reading what it finds and writing further symbols.
- He introduced the notion of a 'Universal Machine' with
the idea that such a machine is provably capable of computing anything that is computable by executing a program stored on tape, allowing the machine to be programmable.
Turing Machine
- Von Neumann acknowledged that the central
concept of the modern computer was due to
this paper.
- Turing machines are to this day a central object
of study in theory of computation.
- Except for the finite memory limitations,
modern computers are said to be Turing-
complete. In other words, they have the
capability of executing algorithms equivalent
to a Turing machine.
The Film : «Enigma»
- During World War II, the English
mathematical genius Alan Turing tries to
crack the German Enigma code with help
from fellow mathematicians.
- Alan Turing’s life is given in a film called
Enigma (2014). Please watch it to see how
mathematics is related to computer
engineering.
History of Computers
- First digital computer might be the abacus used by the Chinese 3000-4000 years ago.
- Slide rule was initially crude, but long-lived, and could only multiply and divide, a characteristic of analog computers.
- Pascal’s adding machine of 1642 was a better first example of an analog computer, but like the abacus, it was only a calculator.
- All of these lacked a means of storing a program.
Babbage
- Charles Babbage was Lucasian Professor of Mathematics
at Cambridge University from 1828 to 1839.
- Babbage is known as the «father of computers»
- Babbage's proposed Difference Engine was a special-
purpose digital computing machine for the automatic production of mathematical tables (such as logarithm tables, etc).
- The Difference Engine consisted entirely of mechanical
components - gear wheels, rods, ratchets, pinions, etc.
- Decimal numbers were represented by the positions of 10-
toothed wheels mounted in columns.
- Babbage exhibited a small working model in 1822.
Babbage
- Babbage also proposed a machine called Analytical Engine.
- It was considerably more complicated than the Difference Engine.
- It is known as the first general-purpose mechanical digital
computer.
- The Analytical Engine had a memory store and a central processing unit (or 'mill').
- It was able to select from among alternative actions consequent upon the outcome of its previous actions (i.e. Today it is known as conditional branching).
- For output, the machine would have a printer, a curve plotter
and a bell. The machine would also be able to punch numbers onto cards to be read in later.