Docsity

Embedded RealTime Systems: Midterm Preparation - Topics and Review - Prof. Andrew Fagg, Study notes of Aerospace Engineering

Partial preview of the text

Download Embedded RealTime Systems: Midterm Preparation - Topics and Review - Prof. Andrew Fagg and more Study notes Aerospace Engineering in PDF only on Docsity!

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Last Time

  • Interrupts:
    • A means for temporarily stopping the

execution of the main program to executeanother small piece of code

  • In response to some event (either external

from or internal to the chip)

  • Timer/counters and regular interrupts(no interrupts on the midterm)

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Today

  • Midterm review• Homework 3 (due right now)• Project 3 due Thursday after break (don’t

wait!)

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Midterm Exam

  • No books• No electronic devices• You may bring 1 page of

your own

notes

  • Double-sided
    • Assigned seating

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Digital Logic

-^

Basic gates– Truth table– Symbols used in circuit diagrams– NOT, AND, OR, NAND, NOR, XOR– Tristate buffers

-^

Boolean algebra– Notation– Precedence– Basic laws: associative, distributive, commutative– Demorgan’s laws– Basic identities

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Number Representations

  • Conversion between binary and:
    • Decimal– Hexidecimal
      • Bit-wise operations

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Arithmetic

  • Adding/subtracting binary numbers• Shifting left/right (multiplication/division by

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Microprocessor Components

  • Memory• Registers:
    • General purpose– Special purpose, e.g.:
      • Program counter• Instruction register
        • Instruction decoder• Arithmetic logical unit• Data bus

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Microcontroller I/O

DDRx PORTx

PINx

  • Function of

the primarycomponents– DDRx– PORTx– PINx

  • Relationship

to C code

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Counter/Timers

(small question)• How to generate an event that occurs N

seconds into the future?

  • How to measure the time from now until

some event?

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Counter/Timers

  • Timer 0
    • 8-bit counter– Prescaler: 1, 8, 64, 256, 1024
      • Timer 1:
        • 16-bit counter– Prescaler: same as timer 0
          • Timer 2:
            • 8-bit counter– Prescaler: 1, 8, 32, 64, 128, 256, 1024

Andrew H. Fagg: Embedded Real-

Time Systems: Midterm Prep

Next Time

  • Continue with interrupts