Distributed Embedded Systems

Slides:



Advertisements
Similar presentations
Chapter 2 Network Models.
Advertisements

PROTOCOLS AND ARCHITECTURE Lesson 2 NETS2150/2850.
1 Chapter 9 Computer Networks. 2 Chapter Topics OSI network layers Network Topology Media access control Addressing and routing Network hardware Network.
© 2008 Wayne Wolf Overheads for Computers as Components 2 nd ed. Networking for Embedded Systems zWhy we use networks. zNetwork abstractions. zExample.
Review on Networking Technologies Linda Wu (CMPT )
COMPUTER NETWORKS.
1 Computer Networks Course: CIS 3003 Fundamental of Information Technology.
1 Protocol Interaction (ISO’s Open Systems Interconnection (OSI model)) the 7 layers.
Protocols and the TCP/IP Suite Chapter 4. Multilayer communication. A series of layers, each built upon the one below it. The purpose of each layer is.
Chapter 1 Overview Review Overview of demonstration network
Presentation on Osi & TCP/IP MODEL
Lecture 2 TCP/IP Protocol Suite Reference: TCP/IP Protocol Suite, 4 th Edition (chapter 2) 1.
What is a Protocol A set of definitions and rules defining the method by which data is transferred between two or more entities or systems. The key elements.
Protocols and the TCP/IP Suite
ECE 354 Copyright ECE Department, some slides modified from W. Wolf, Computers as Components, Morgan Kaufmann, 2005 Big Picture: Lab 3 Networks (OSI-view)
Computer Communication & Networks Lecture # 02 Nadeem Majeed Choudhary
Department of Electronic Engineering City University of Hong Kong EE3900 Computer Networks Introduction Slide 1 A Communications Model Source: generates.
Introduction to Networks CS587x Lecture 1 Department of Computer Science Iowa State University.
Data and Computer Communications Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based Applications.
DEVICES AND COMMUNICATION BUSES FOR DEVICES NETWORK
1 The Internet and Networked Multimedia. 2 Layering  Internet protocols are designed to work in layers, with each layer building on the facilities provided.
1 Kyung Hee University Chapter 2 Network Models. 2 Kyung Hee University 2.1 LAYERED TASKS We use the concept of layers in our daily life. As an example,
© 2000 Morgan Kaufman Overheads for Computers as Components Networks zNetwork-based design. yCommunication analysis. ySystem performance analysis. zInternet-enabled.
Network Protocols n ISO OSI 7-layer model n TCP/IP suite l TCP/UDP l IP l Ethernet/Token Ring l ICMP.
William Stallings Data and Computer Communications
Lecture Topics: 11/27 Networks Layered Model Ethernet IP.
Network Models.
1 Chapter 4. Protocols and the TCP/IP Suite Wen-Shyang Hwang KUAS EE.
Renesas Electronics America Inc. © 2010 Renesas Electronics America Inc. All rights reserved. Overview of Ethernet Networking A Rev /31/2011.
Voice Over Internet Protocol (VoIP) Copyright © 2006 Heathkit Company, Inc. All Rights Reserved Presentation 5 – VoIP and the OSI Model.
Roadmap  Introduction to Basics  Computer Network – Components | Classification  Internet  Clients and Servers  Network Models  Protocol Layers.
Data and Computer Communications Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based Applications.
OSI Model OSI MODEL. Communication Architecture Strategy for connecting host computers and other communicating equipment. Defines necessary elements for.
OSI Model OSI MODEL.
Network Models.
What is a Protocol A set of definitions and rules defining the method by which data is transferred between two or more entities or systems. The key elements.
Example DLL Protocols 1. High-Level Data Link Control (HDLC).
Chapter 5 Network and Transport Layers
Chapter 16 – Networking Outline 16.1 Introduction
Lecture (2).
A quick intro to networking
Scaling the Network: The Internet Protocol
Click to edit Master subtitle style
Part I. Overview of Data Communications and Networking
OSI Protocol Stack Given the post man exemple.
Layered Architectures
Understand the OSI Model Part 2
Networking for Home and Small Businesses – Chapter 6
Lecture 6: TCP/IP Networking By: Adal Alashban
IOS Network Model 2nd semester
Net 431: ADVANCED COMPUTER NETWORKS
CS 457 – Lecture 6 Ethernet Spring 2012.
Networking for Home and Small Businesses – Chapter 6
Protocols and the TCP/IP Suite
Data and Computer Communications by William Stallings Eighth Edition
NETWORKING TECHNOLOGIES (II)
I. Basic Network Concepts
Chapter Goals Compare and contrast various technologies for home Internet connections Explain packet switching Describe the basic roles of various network.
Lecture 6: TCP/IP Networking 1nd semester By: Adal ALashban.
Protocol layering and data
Network Model.
TCP/IP Protocol Suite: Review
1 TRANSMISSION CONTROL PROTOCOL / INTERNET PROTOCOL (TCP/IP) K. PALANIVEL Systems Analyst, Computer Centre Pondicherry University, Puducherry –
OSI Model OSI MODEL.
Chapter 2 Network Models
Network Models CCNA Instructor Training Course October 12-17, 2009
Scaling the Network: The Internet Protocol
Protocols and the TCP/IP Suite
Networking for Home and Small Businesses – Chapter 6
Protocol layering and data
Presentation transcript:

Distributed Embedded Systems

Class Goals At the conclusion of this class, the student should be able to: Understand differences between co-processors and accelerators Understand how to interface an accelerator to a CPU Compare accelerated single-threaded and multi-threaded applications Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Topic Outline Networking Embedded Systems Networking Fundamentals The I2C Bus Ethernet Internet Protocol (IP) Networks Analyses of Networks Summary Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Networking Embedded Systems

Network Elements ES Each embedded system (ES) may communicate with any other ES in the network. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Networks in embedded systems initial processing more processing PE sensor PE PE actuator Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Why distributed? Resource constrained platforms cannot perform the entire application Automated application updates Functionality is widely varied among a set of embedded platforms Timing constraints Centralized control of resources may increase network traffic loading Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Embedded System in a Bakery App Server PE1 PE3 PE4 PE2 PE5 Network Measure Temp Adjust Mix Dough Muffin Throughput Cook Time Recipes Orders … Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Networking Fundamentals

The OSI Seven Layer Model International Standards Organization (ISO) developed the Open Systems Interconnection (OSI) model to describe networks: Provides a standard way to classify network components and operations. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

OSI model application end-use interface presentation data format session application dialog control transport connections network end-to-end service data link reliable data transport physical mechanical, electrical Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Links Sources Network protocols. Files Files HTTP TCP IP packets Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Distributed Network Architectures Many different types of networks: topology; scheduling of communication; routing. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Point-to-point networks One source, one or more destinations, no data switching (serial port): PE 3 PE 1 PE 2 link 1 link 2 Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Bus networks Common physical connection: PE 1 PE 2 PE 3 PE 4 packet format header address data ECC EOT Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Bus arbitration Fixed: Same order of resolution every time. Fair: every PE has same access over long periods. round-robin: rotate top priority among Pes. fixed A B C A B C round-robin A B C B C A t A,B,C A,B,C Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Message-based programming Transport layer provides message-based programming interface: send_msg(adrs,data1); Data must be broken into packets at source, reassembled at destination. Data-push programming: make things happen in network based on data transfers. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

The I2C Bus

I2C Bus Serial communications bus 0 - 400 Kbps operation (100 Kbps typical) SDA – Serial DAta Line SCL – Serial CLock Line Loosely-defined electrical specification Low implementation cost Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C bus Characteristics: Supports multiple bus masters fixed-priority arbitration. Several microcontrollers come with built-in I2C controllers Each I2C device is given a unique bus address Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C physical layer master A master B SDA SCL slave 1 slave 2 Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C data format u u /V t/s /V t/s MSB LSB Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C electrical interface Open collector interface: + SDA + SCL Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C signaling Sender pulls down bus for 0. Sender listens to bus---if it tried to send a 1 and heard a 0, someone else is simultaneously transmitting. Transmissions occur in 8-bit bytes. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C data link layer Every device has an address (7 bits in standard, 10 bits in extension) LSB of address signals read or write General call address allows broadcast Address 00000000 is the indicator for a “general call” or broadcast Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C bus arbitration Sender listens while sending address. When sender hears a conflict, if its address is higher, it stops signaling. Low-priority senders relinquish control early enough in clock cycle to allow bit to be transmitted reliably. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C transmissions (multi-) byte write S Adrs Word-adr Data P Start Write (LSB of address) Stop (multi-) byte write S Adrs Word-adr Data P Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I2C transmissions Write addreses, then read S Adrs Word-adr S Adrs 1 Start Write (LSB of address) Read (LSB of address) Stop Write addreses, then read S Adrs Word-adr S Adrs 1 Data P Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Ethernet

Ethernet Dominant LAN technology Typical: 10/100 Mb/s and 1 Gb/s Future: 10 Gbps and 40 Gbps Goal: reliable communication over an unreliable medium. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Ethernet topology Bus-based system, several possible physical layers: Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

CSMA/CD Carrier sense multiple access with collision detection: sense collisions; exponentially back off in time; retransmit. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Ethernet packet format preamble start frame source adrs dest adrs length data payload padding CRC Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Ethernet performance Quality-of-service tends to non-linearly decrease at high load levels. Can’t guarantee real-time deadlines. However, may provide very good service at proper load levels. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Internet Protocol (IP) Networks

Internet Protocol Internet Protocol (IP) is basis for Internet. Provides an internetworking standard: between two Ethernets, Ethernet and token ring, etc. Higher-level services are built on top of IP. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

IP in communication application application presentation presentation session session IP transport transport network network network data link data link data link physical physical physical node A router node B Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

IP packet Includes: Maximum data payload is 65,535 bytes. version, service type, length time to live, protocol source and destination address data payload Maximum data payload is 65,535 bytes. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

IP addresses 32 bits in early IP, 128 bits in IPv6. Typically written in form xxx.xx.xx.xx. Names (foo.baz.com) translated to IP address by domain name server (DNS). Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Internet routing Best effort routing: Routing can vary: doesn’t guarantee data delivery at IP layer. Routing can vary: session to session; packet to packet. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Higher-level Internet services Transmission Control Protocol (TCP) provides connection-oriented service. Quality-of-service (QoS) guaranteed services are under development. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

The Internet service stack FTP HTTP SMTP telnet SNMP TCP UDP User Datagram Protocol IP Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Analyses of Networks

Networks Network-based design. Internet-enabled systems. Communication analysis. System performance analysis. Internet-enabled systems. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Communication analysis First, understand delay for single message. Delay for multiple messages depends on: network protocol; devices on network. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Message delay Assume: Delay: single message; no contention. tm = tx + tn + tr = xmtr overhead + network xmit time + rcvr overhead Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Example: I2C message delay Network transmission time dominates. Assume 100 kbits/sec, one 8-bit byte. Number of bits in packet: npacket = start + address + data + stop = 1 + 8 + 8 + 1 = 18 bits Time required to transmit: 1.8 x 10-4 sec. 20 instructions on 8 MHz controller adds 2.5 x 10-6 delay on xmtr, rcvr. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Multiple messages If messages can interfere with each other, analysis is more complex. Model total message delay: ty = td + tm = wait time for network + message delay Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Arbitration and delay Fixed-priority arbitration introduces unbounded delay for all but highest-priority device. Unless higher-priority devices are known to have limited rates that allow lower devices to transmit. Round-robin arbitration introduces bounded delay proportional to N. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Example: adjusting messages to reduce delay Task graph: Network: 3 4 execution time Transmission time = 4 allocation P1 P2 M1 M2 M3 d1 d2 P3 Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Initial schedule M1 P1 M2 P2 M3 P3 network d1 d2 Time = 15 time 5 10 time 5 10 15 20 Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

New design Modify P3: reads one packet of d1, one packet of d2 computes partial result continues to next packet Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

New schedule M1 P1 M2 P2 M3 P3 P3 P3 P3 network d1 d2 d1 d2 d1 d2 d1 Time = 12 time 5 10 15 20 Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Hardware platform design Need to choose: number and types of PEs; number and types of networks. Evaluate a platform by allocating processes, scheduling processes and communication. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

I/O-intensive systems Start with I/O devices, then consider computation: inventory required devices; identify critical deadlines; chooses devices that can share PEs; analyze communication times; choose PEs to go with devices. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Computation-intensive systems Start with shortest-deadline tasks: Put shortest-deadline tasks on separate PEs. Check for interference on critical communications. Allocate low-priority tasks to common PEs wherever possible. Balance loads wherever possible. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Internet-enabled embedded system Internet-enabled embedded system: any embedded system that includes an Internet interface (e.g., refrigerator). Internet appliance: embedded system designed for a particular Internet task (e.g. email). Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Examples Laser printer. Personal digital assistant (PDA). Home automation system. Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Summary Resource constrained embedded systems may require communication with other systems to complete a job The selected networking strategy determines the overall performance of a set of networked embedded systems The designer must consider system performance as well as the cost to implement Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Assignment Work on final projects and term papers Complete remaining class presentations Schedule to present final projects/papers Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Questions ? Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007

Acknowledgements Some of the presentation materials were provided by Morgan Kaufmann Publishers Additional material was developed by the GWU Computer Science course instructors Y. Williams/J. Hoenig Csci-339/HFU, Spring 2007