introduction to embedded and real-time systems – w14: an ... · systems perspective): – basics...

44
Introduction to Embedded and Real-Time Systems – W14: An Introduction to Communication Systems and Final Course Conclusions

Upload: others

Post on 14-Aug-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Introduction to Embedded and Real-Time Systems – W14:

An Introduction to Communication Systems and

Final Course Conclusions

Page 2: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

What communication systems do you know?

Page 3: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Outline

• Wired Communication– Communication model– Modulation, demodulation

• Wireless Communication– Sharing the medium– Throughput limits (Shannon-Hartley)‏– Link budget, free space path loss

• Available Technologies– Example: dam monitoring

Page 4: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Wired Communication

Page 5: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Communication Model

Transmitterchannel

Receiver

Page 6: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Communication Model

Transmitterchannel

Receiver

Noise

DistortionFilteringFrequency shift...

ModulationCoding(Compression)‏

DemodulationDecoding(Decompression)‏

Page 7: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 (serial port)‏

• Hardware:– 3 wires: TxD, RxD, Ground

RxD

Transceiver1

Transceiver2

TxD

Ground

TxD

RxD

Ground

Transceiver = Transmitter + Receiver

Page 8: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 (serial port)‏

• Signal: between RxD/TxD and Ground

RxD

Transceiver1

Transceiver2

TxD

Ground

TxD

RxD

Ground

Page 9: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 Modulation

Page 10: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 Demodulation

Page 11: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 Delay

• Packet-based– 1 byte / packet– 8 data bits + 2 control bits = 10 bits

• Transmission speed– max. 115'200 bits/s (bps)‏

• Propagation speed:– approx. c (speed of light) ‏

Page 12: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

RS-232 Delay

• Transmission delay– 10 bits / 115'200 bps = 86.8 us

• Signal propagation delay (2 m cable)‏– 2 m / c = 6.6712819 ns

• Processing delay:– ~ 1 us (modulation, demodulation, processing)‏

• Total: ~ 90 us = 0.09 ms

Page 13: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Wireless Communication

Page 14: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Transmitterchannel =

ElectroMagneticwaves in air

Receiver

Noise

ReflectionsFadingInterferenceOther EM sources...

Communication Model

Page 15: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Communication Model

Transmitterchannel =

ElectroMagneticwaves in air

Receiver

Noise

ReflectionsFadingInterferenceOther EM sources...

Channel estimationAdvanced modulation typesCoding and error correction

Page 16: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Sharing the Medium

2

1

3

Page 17: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Sharing the Medium

• TDMA– Time-Division Multiple Access– “You shut up while I talk“– Time allocation

• Fixed, synchronizede.g. mobile phones (GSM)‏

• Dynamic (check if channel is free)e.g. Wireless LAN (802.11b/g/n)‏

1 2 3 2 3 time

Page 18: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Sharing the Medium

• FDMA– Frequency-Division MA– e.g. FM radio channels– Frequency regulation

• BAKOM (CH) ‏

1 2 3

frequencyallocated by BAKOM

bandwidth

Page 19: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Sharing the Medium

• CDMA (spread spectrum)‏– Code-Division MA– Using different transmission codes– e.g. GPS– Interesting properties

• Wide channels (fading)‏• Concurrent communication

– More complex demodulation

Page 20: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Throughput (bits/s)‏

• TDMA, FDMA, CDMA can be combined• Total throughput is shared

TDMA

CDMA

FDMA

Page 21: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Shannon-Hartley Limit

• Hard theoretical limit on throughput– More bandwidth = higher throughput– More power (SNR) = higher throughput

C: capacity (throughput)‏B: bandwidthS: signal power (W)‏N: noise power (W)‏

Page 22: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Power

• Increased power– higher throughput– mobile systems: shorter battery life– increased health risk (?)‏

• Regulation– CH: BAKOM– e.g. WLAN: 100 mW

Page 23: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Power

• Unit: W (Watt)‏– Often written in dBm (decibels mW)‏

• Gain / loss: factors– Often written in dB (decibels)‏

Page 24: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Link Budget

TX powerTX lossesTX antenna gainFree space path lossRX antenna gainRX losses

RX power

RX sensitivity

100 mW0.51.61.0106e81.60.5

20 dBm-3 dB2 dB-80 dB2 dB-3 dB

-85 dBm

-62 dBm

Margin 23 dB200

Typical WLAN link budget (100 m, dipole antennas):

Page 25: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Free Space Path Loss

• Signal power decay in air:

• Proportional to the square of the distance d• Proportional to the square of the frequency f

– high frequency = high loss– low frequency = low bandwidth

Page 26: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Available Technologies

Page 27: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Dam MonitoringVibrations Temperature

A few wired technologies:Copper line (8 Mbps)‏Analog phone line (56 kbps)‏ADSL (8 Mbps)‏USB (< 15 m, 480 Mbps) ‏Ethernet (< 200 m, 1 Gbps)‏RS-232 / RS-485 (< 100 m, 115 kbps)‏SATA (< 1 m, 6 Gbps)‏

A few wireless technologies:Satellite link (long delay, 2 Mbps)‏Bluetooth (< 10 m, 1 Mbps)‏WLAN (< 100 m, 54 Mbps)‏Mobile phone (100 kbps, subscription)‏Wireless link (1 Mbps)‏Packet radio (9.6 kbps)‏HQ

Page 28: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Some Pointers for Embedded System

Technology in Civil/Environmental

Engineering

Page 29: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Civil Engineering Applications• Structural Health Monitoring (SMH)

– Embedded Networks Laboratory, USC, Los Angeles, U.S.A., Prof. R. Govindan: http://enl.usc.edu/projects/shm/index.html

– Structural Engineering Laboratory, EMPA, Duebendorf, Prof. M. Motavalli, Dr. G. Feltrinhttp://www.empa.ch/plugin/template/empa/93/*/---/l=2

- Prof. D. Culler, EECS department, UCB, Berkeley, U.S.A.:http://www.eecs.berkeley.edu/~binetude/ggb/

- Prof. J. Wallace and B. Kaiser, CENS, UCLA, Los Angeles, U.S.A. http://research.cens.ucla.edu/projects/2007/Seismic/Tall_Special/

Page 30: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Civil Engineering Applications• (Decentralized) Structural Control

– Laboratory for Smart Structural systems, Prof. Y. Wang, GaTech, Atlanta, U.S.A.http://people.ce.gatech.edu/~ywang/research.htm#_WirelessControl

- Prof. Ian Smith, EPFL, IMAC (active structures) http://imacwww.epfl.ch/Common/research-en.jsp

- DISAL (Smart bridge project, in collaboration with EMPA): http://www5.epfl.ch/swis/page26715.html

- Laboratory for Intelligent Structural Technology, Prof. J. P. Lynch, University of Michigan: http://www-personal.umich.edu/~jerlynch/index.html

Page 31: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Environmental Engineering Applications• Environmental Monitoring using sensor networks

- http://research.cens.ucla.edu/research/, Prof. D. Estrin (UCLA, Los Angeles, U.S.A.), Director; work on urban sensing, animal and plants, aquatic environment, contaminant transport

- Profs. M. Vetterli, M. Parlange, K. Aberer and DISAL (EPFL)http://sensorscope.epfl.ch/index.php/Main_Page

- Swiss Experiment (several Swiss institutions, Dr. M. Lehning, WSL Davos, Principal Investigator): http://lsir-swissex.epfl.ch/index.php/Main_Page

- Prof. Paul Flikkema (NAU, Flagstaff, U.S.A), Prof. J. Clark (Duke University, U.S.A) http://wisardnet.nau.edu/

Page 32: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Environmental Engineering Applications• Waste treatment process using (wired) sensor networks:

– EAWAG innovative sensing technology (Prof. H. Sigrist)http://www.eawag.ch/organisation/abteilungen/eng/schwerpunkte/abwasser/msr_konzept/index_EN

• Env. monitoring using distributed robotic systems:– Aquatic microbic observing systems (Prof. G. Sukhatme,

USC Los Angeles, U.S.A.) http://robotics.usc.edu/~namos/index.html

– Adapting sampling of oceans (Prof. N. E. Leonard, Princeton, U.S.A.): http://www.princeton.edu/~dcsl/asap/

Page 33: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Course Take Home Messages

Page 34: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

What is an Embedded System?

From Wikipedia: An embedded system is a special-purpose computersystem designed to perform one or a few dedicated functions often with real-time computing constraints. It is usually embedded as part of a complete device including hardware and mechanical parts. In contrast, a general-purpose computer, such as a personal computer, can do many different tasks depending on programming.

Page 35: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Consumer Market Devices

Digital Watch

Weather station

Digital video camera

Digital camera

Page 36: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Niche Market – Scientific Equipment Commercially Available

Sensorscopestation, 2nd generation

Mica-Z

e-puck

Handheld Airborne Mapping System

Page 37: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

What is Challenging in Designing Embedded Systems?

• Computation is subject to physical and resource constraints such as timing, deadlines, memory restrictions, and power consumption requirements.

• The traditional abstraction of separating software from the hardware is more difficult. Hardware and software are integrally intertwined.

Page 38: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

What we did cover• Fundamentals of signal processing:

– Analog/Digital signals, Time/Frequency domains, Filters, Converters

• Fundamentals of computer science (from an embedded systems perspective):– Basics of computer architecture– UNIX (crash course)– C programming (vs Java, Matlab)

• Fundamentals of embedded and real-time systems:– Microprocessors, microcontrollers, memory– Sensors and actuators– Basic control techniques and concepts– Communication systems

Page 39: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Our Main Objectives for Civil and Environmental Engineers

• This course should allow you to become a power user of the key instruments in civil and environmental engineering used nowadays (sensor networks, meteorological stations, data loggers, etc.) and in the future (exploratory and cleaning robots, robotics sensor networks, etc.)

• This course should allow you to collaborate more efficiently with electrical and computer engineers in general and, in particular, to give you sufficient background to attend, if any interest, the follow-up master course on distributed intelligent systems

Page 40: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Why is this objective realistic?• Off-the-shelf hardware components are becoming more and

more flexible, cheap, small, and standardized. The design complexity is continuously shifting to software!

• You have domain knowledge which can be translated to code: as long as you can program in the appropriate language you can contribute to design embedded systems for applications in your area!

• However, since in embedded systems hardware and software are more intertwined than in other computer systems because of hardware resources constraints, you need to have an idea of what these constraints are and be ready to analyze the specifications of a given hardware system or component.

Page 41: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Next Iteration• 5 ECTS, i.e. 150 h workload• Breakdown:

– 2 ECTS lecture (attendance, preparation, exam)– 2 ECTS lab+hwk (probably 10 labs @ 6 h each)– 1 ECTS course project (30 h work)

• Full in English• SSIE compulsory, SGC optional• Remain at BS 6th semester for the time being

for both sections• All your valuable will back will be considered

Page 42: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

A Note for SGC Students

• Optional courses = motivated students• The content is clear and will remain about the

same (with more problem domain examples), do not come to this course if not motivated

• 27/40 ECTS (available 23 WS, 17 SS) this year; next year 28/45 ECTS (available 26 WS, 19 SS): do your planning well (i.e. have backup if you do not like the course in the first weeks)!

• If not enough optional courses, ask for more at SGC!

Page 43: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Master Course on Distributed Intelligent Systems

We focused in giving you some understanding of one device

The reality is however that most of the civil/environmental applications requires a network of devices …

Page 44: Introduction to Embedded and Real-Time Systems – W14: An ... · systems perspective): – Basics of computer architecture – UNIX (crash course) – C programming (vs Java, Matlab)

Thank you for your attention and valuable feedback!