Learning Module 9. Managing the Sensor: Embedded Computing. Paul Flikkema. Department of Electrical Engineering Northern Arizona University

Similar documents
Lecture (01) Introducing Embedded Systems and the Microcontrollers By: Dr. Ahmed ElShafee

Computer Hardware Requirements for Real-Time Applications

Lecture 1. Course Overview and The 8051 Architecture

ECE 471 Embedded Systems Lecture 2

Digital Electronics 27. Digital System Design using PLDs

Microcontroller basics

System Architecture Directions for Networked Sensors[1]

Microcontroller: CPU and Memory

Unlocking the Potential of Your Microcontroller

Introduction to L.A.P. 1

Basic Components of Digital Computer

INDUSTRIAL TRAINING:6 MONTHS PROGRAM TEVATRON TECHNOLOGIES PVT LTD

Choosing a Micro for an Embedded System Application

Overview of Microcontroller and Embedded Systems

WHICH MICRO? What does MCU needs to do in my system? What are the tasks? Dr. Adriana Becker-Gomez

PIC32&Overview& E155&

Z8 Encore! XP F1680 Series 8-Bit Flash Solution with Extended Peripherals

TEVATRON TECHNOLOGIES PVT. LTD Embedded! Robotics! IoT! VLSI Design! Projects! Technical Consultancy! Education! STEM! Software!

ELCT708 MicroLab Session #1 Introduction to Embedded Systems and Microcontrollers. Eng. Salma Hesham

Embedded System Project (521423S) - Specifications

Rad-Hard Microcontroller For Space Applications

Embedded Systems Design (630414) Lecture 1 Introduction to Embedded Systems Prof. Kasim M. Al-Aubidy Computer Eng. Dept.

Introduction to Embedded Systems

Introduction to Embedded Systems

ELEG3923 Microprocessor Ch.0 & Ch.1 Introduction to Microcontroller

Lecture 5: Computing Platforms. Asbjørn Djupdal ARM Norway, IDI NTNU 2013 TDT

Betrouwbare Elektronica ontwerpen en Produceren

MicroProcessor. MicroProcessor. MicroProcessor. MicroProcessor

2-bit ARM Cortex TM -M3 based Microcontroller FM3 Family MB9A130 Series

Hello, and welcome to this presentation of the STM32L4 power controller. The STM32L4 s power management functions and all power modes will also be

Final Exam Study Guide

OPERATIONAL UP TO. 300 c. Microcontrollers Memories Logic

Introduction to Embedded Systems

STM32F3. Cuauhtémoc Carbajal ITESM CEM 12/08/2013

Atmel Exploits FPGA Flexibility in Application Development for Customizable Microcontroller-based Systems Peter Bishop, Atmel Corporation 22-Dec-2008

Embedded Systems: Hardware Components (part I) Todor Stefanov

Chapter 5: ASICs Vs. PLDs

RZ Embedded Microprocessors

WS_CCESBF7-OUT-v1.00.doc Page 1 of 8

A First Look at Microprocessors

AT-501 Cortex-A5 System On Module Product Brief

Getting Started With the Stellaris EK-LM4F120XL LaunchPad Workshop. Version 1.05

Module Introduction. This training module provides an overview of Freescale s scalable solutions for low data rate 2.4 GHz connectivity.

MT2 Introduction Embedded Systems. MT2.1 Mechatronic systems

EMBEDDED SYSTEMS COURSE CURRICULUM

Computer Hardware Requirements for ERTSs: Microprocessors & Microcontrollers

The industrial technology is rapidly moving towards ARM based solutions. Keeping this in mind, we are providing a Embedded ARM Training Suite.

STM32G0 MCU Series Efficiency at its Best

AVR XMEGA TM. A New Reference for 8/16-bit Microcontrollers. Ingar Fredriksen AVR Product Marketing Director

Introduction to Embedded Systems

Ali Karimpour Associate Professor Ferdowsi University of Mashhad

EMBEDDED SYSTEMS WITH ROBOTICS AND SENSORS USING ERLANG

Product Technical Brief S3C2440X Series Rev 2.0, Oct. 2003

Approximately half the power consumption of earlier Renesas Technology products and multiple functions in a 14-pin package

Microprocessors/Microcontrollers

Figure 1.1: Some embedded device. In this course we shall learn microcontroller and FPGA based embedded system.

FOR IOT PRODUCT DEVELOPMENT

Microprocessor Systems

Infineon C167CR microcontroller, 256 kb external. RAM and 256 kb external (Flash) EEPROM. - Small single-board computer (SBC) with an

Network Embedded Systems Sensor Networks Fall Hardware. Marcus Chang,

Classification of Semiconductor LSI

A First Look at Microprocessors

Low-Cost Microcontrollers

Introduction to ARM LPC2148 Microcontroller

Remote Keyless Entry In a Body Controller Unit Application

EE 354 Fall 2015 Lecture 1 Architecture and Introduction

8051 Compiler Gets 56% More DMIPS/MHz with 30-50% Smaller Code.

STM32 Cortex-M3 STM32F STM32L STM32W

Accelerometer with Analog and Digital I/O for StackableUSB USB1600

XMEGA Series Of AVR Processor. Presented by: Manisha Biyani ( ) Shashank Bolia (

PIC Microcontroller and

Introduction to OS. Introduction MOS Mahmoud El-Gayyar. Mahmoud El-Gayyar / Introduction to OS 1

IMC5-1EO. Embedded Operating Systems. Damien MASSON Last modification: November 12, 2013

Interconnects, Memory, GPIO

CPT-DA Texas Instruments TMS320F28377D controlcard compatible. DA Series Interface Card. Technical Brief

Typical Applications: GHz Bluetooth low energy systems - Proprietary 2.4 GHz systems - Sports and leisure equipment - Mobile phone accessories,

TI SimpleLink dual-band CC1350 wireless MCU

PIC Microcontroller Introduction

Intel Galileo gen 2 Board

PD215 Mechatronics. Week 3/4 Interfacing Hardware and Communication Systems

OUTLINE. STM32F0 Architecture Overview STM32F0 Core Motivation for RISC and Pipelining Cortex-M0 Programming Model Toolchain and Project Structure

Copyright 2016 Xilinx

MetaWatch Firmware Design Guide

ZLF645 Crimzon Flash Microcontroller with ZBase Database Industry Leading Universal Infrared Remote Control (UIR) Solution

EMBEDDED SOFTWARE DEVELOPMENT. George Hadley 2017, Images Property of their Respective Owners

Military Grade SmartFusion Customizable System-on-Chip (csoc)

Renesas New Generation of R8C/Tiny Series MCUs Adds 1.8V Support and Coprocessing With Background Operation to Enable Low-cost Innovative Designs

Team 3. By: Miriel Garcia. Microcontrollers/ TI MSP430F5438A. ECE 480 senior Design. Application Note 4/3/15

PRODUCT PREVIEW TNETV1050 IP PHONE PROCESSOR. description

Ali Karimpour Associate Professor Ferdowsi University of Mashhad

Overview of Embedded Systems in Medical Applications

Cypress PSoC 6 Microcontrollers

STM32 F-2 series High-performance Cortex-M3 MCUs

EMBEDDED SYSTEM BASICS AND APPLICATION

Embedded Systems: Architecture

Factsheet 16FX Concept Compatible Platform of 16-bit Microcontrollers

T he key to building a presence in a new market

Advanced Embedded Systems

Analog, Mixed-Signal and Power Management

Embedded Programming with ARM Cortex-M3 Basic Experiments 1

Transcription:

Learning Module 9 Managing the Sensor: Embedded Computing Paul Flikkema Department of Electrical Engineering Northern Arizona University

Outline Networked Embedded Systems Hardware Software Languages Operating systems Energy efficiency

What are embedded systems? Computing systems that interact with the physical world at its time-scale appliances, mobile phones, medical devices Real-time systems: embedded systems that must meet deadlines navigation systems Life-critical systems: reliability, guaranteed responsiveness automobile and aircraft control

Example: ESC

Embedded Systems -- Facts Use 99% of all digital silicon Usually a combination of sensors, actuators, analog/mixed signal electronics, digital hardware and software Often use wired and/or wireless communication and networking

WSN nodes are deeply embedded systems Many nodes => low cost nodes Low cost => Low clock frequency Small program memory Small data memory Long battery life Long battery life => Low power consumption

Digital Logic Standard Logic Progammable Logic (FPLDs) ASICs Full Custom TTL 74xx CMOS 4xxx PLDs FPGAs CPLDs Microprocessor & RAM Gate Arrays Standard Cell Digital logic technologies (Hamblen and Furman) Structured ASIC: generic logic elements (memory, I/O) plus customizable logic. Platform ASICs add complex functional Blocks (e.g., processor cores, memory controllers, Ethernet controllers) CPLD = Complex Programmable Logic Device

Speed, Density, Complexity, Market Volume needed for Product PLDs CPLDs FPGAs ASICs Full Custom VLSI Design (Hamblen and Furman) Engineering Cost, Time to Develop Product Digital logic technology tradeoffs

Energy consumption is a critical factor Would like to have digital hardware optimized for the WSN node application Full-custom is too expensive for smallvolume markets FPGA power consumption is decreasing QuickLogic PolarPro Actel Igloo SiliconBlue ice Need strong peripheral support Software-programmable MCU s still best

Outline Networked Embedded Systems Hardware Software Languages Operating systems Energy efficiency

The hardware must support a sensor node s three main tasks Sense Compute Control Communicate Compute Hibernate 1. CPU 2. Peripherals 3. Power management

Microprocessor (MPU) or Microcontroller (MCU)? An MCU performs dedicated functions within an overall system MCU s contain rich set of on-chip peripherals on-chip program (non-volatile) program memory

MCU market is extremely competitive ~$15B market (2008) strong growth in automotive space Analog Devices, Atmel, Cyan Technology, Freescale, Fujitsu, Luminary Micro, Microchip, Renesas, Silicon Labs, ST Micro, Texas Instruments, Toshiba, Zilog

Computer Hardware Organization Processor Memory Interconnection Structure I/O The interconnection structure is normally one or more busses

Structure of a Processor Control Unit Bus Data Processing Unit Program Counter Address Generation Logic Address Register Control Circuitry Control Signals Status Register ALU Stack Pointer Instruction Register Data Register Register File

Basic Datapath From Data Bus Register File Control Unit selects Registers and ALU function To Data Bus To Address Bus ALU Status to Control Unit

From CPU to MCU (Cyan Technology)

Memory: on-chip (Cyan Technology)

Memory: Off-chip Non-Volatile FLASH Up to ~1M writes NOR fast read slow erase/write random access program storage NAND slow read fast erase/ write serial interface data storage prone to errors FRAM Up to ~10B writes High speed Random access Very low power consumption MRAM coming? Very high speed Larger sizes No known wear-out

Peripherals define MCU s (Cyan Technology)

MCU Peripherals Timers watchdog timers Counters Comparators A/D and D/A converters GPIO PWM outputs Motor control Communication I2C, SPI, serial USB Ethernet Analog peripherals Multiplexers Programmable-gain amplifiers (PGA s)

How can we improve energy efficiency in embedded systems? 1. Ensure that every electronic component uses the minimum amount of energy to do its job Optimize process technologies Digital, analog, RF Improve power regulation and management 2. Ensure that no electronic component uses energy unless it is doing something useful Clock domains (and gating) Power domains (and gating) Dynamic voltage scaling

Example: ST Micro STM32 (ST Micro and Embedded Control Europe)

Example: Texas Instruments MSP430F5XXX

Modern Hardware Support for Debugging In-circuit debugging Hardware support JTAG No hardware overhead Requires custom interface and software Tracing aka logging Requires only serial port Flexible Significant overhead on target hardware New - power debugging

Choosing an MCU for a Sensor Node Design datapath width development toolchain family coverage support! memory OTP or FLASH SRAM power consumption SRAM retention peripherals real-time clock A/D converter resolution speed D/A converter resolution speed communication serial, USB, Ethernet voltage

G2 WiSARD Functional H/W Design 1-Wire Light(4) Temp(4) General Purpose(2) Memory SRAM FLASH/FRAM Brain Board Analog I/O PWM(2) Pwr(2) Radio Board Int Power Micro- Controller PIC18F8720 Power Mgmt System Time Ext Power SPI+ Enclosure Transceiver Micro- Controller PIC18F452 Sensor Board

Outline Networked Embedded Systems Hardware Software Languages Operating systems Energy efficiency

Software Languages C is the lingua franca of embedded systems programming* Up until now, many systems were programmed using assembly language C is close the the hardware, but not too close Reasonable balance of design speed and code efficiency Occasionally write critical sections in assembly language A more high-level language may succeed some day *not including safety-critical systems

Software Design Hierarchy Pre-processor Compiler Assembler Linker Loader Assembly C Language Assembly Language Libraries Hardware

Software Design Hierarchy: with Operating System Application Program Interface C OS Assembly Language Assembly Language Libraries Hardware

Embedded systems software design: knowledge hierarchy Development Tools Existing Codebase MCU-specific Compiler Specific MCU and Board Generic Language (C) Target MCU Family

How to control peripherals: two ways Direct Access direct writes to control and data registers Tedious for programmer Lean and fast Less portable Macros help Library Access access via function calls Easier for programmer Invokes overhead Code: library routine Time: function call More portable Family-specific

Interfacing with the physical world: how to handle asynchronous events Two approaches: Polling: Program explicitly checks whether a signal has changed Interrupts: Program clears, then enables, a latch that will trigger when a signal changes Interrupt handler (or ISR) is a (small) routine that is invoked as soon as possible after the signal change

Asynchronously interrupting the flow of execution Need to save state Can require volatile type qualifier ISR New chips support nested interrupts

The best solution is application-dependent Polling Simple Can waste CPU time and energy Easy to debug Does not scale well Motivates system-level support via timetriggering executive Interrupts Requires special hardware Easy to code, but can cause hard-to-find bugs Elegant solution for handling rare events Used in some MCU programming models

Operating Systems Purposes allocate resources via scheduler time on hardware resources CPU, DMA, peripherals Provide mediated, astracted interfaces to memory (including a file system) Peripherals I/O

WSN engineering invokes cross-layer design challenges! PHY and MAC Routing and Application (selforganization) MAC and Embedded Software (codesign) Embedded Software and ULP MCU s Source and Channel Coding P. Flikkema

Operating systems are a form of executive Type Properties Examples Event loop Simplest Tasks are functions Periodic task execution Hand-written Time-triggered executive Time-triggered Time slotted into frames/slots Scheduler runs once/frame Tasks are functions WiSARD executive FlexRay OSEKtime Distributed RTOS s Cooperative OS Pre-emptive OS Event-driven Task queue with reserved slots NesC Most complex Priority-driven TinyOS Contiki Nut/OS FreeRTOS FreeRTOS Linux Many RTOS s

Innovative software architectures are needed! Programs should be more obvious Prototyping should be easier Time should be a first-class concept Software design process should incorporate co-design with hardware and application energy-awareness minimization of energy consumption

Outline Networked Embedded Systems Hardware Software Languages Operating systems Energy efficiency

The embedded system power grid

Measuring Power and Energy On-line Switched capacitors Current mirror On-chip ADC with precision resistor Monitor regulator Requires switching regulator Difficult to deal with signal measurement

Why is measuring energy difficult? Power signal is wideband Brief pulses (<1 ms) of activity Hours or days of hibernation =>Need high-quality time measurement Power signal is multi-scale in magnitude Up to ~50 ma when active As low as ~2 µa when hibernating Requires scaling of measurement

Precise and accurate measurement of embedded system energy demand

How can we improve energy efficiency? 1. Embedded Systems 1. Ensure that every electronic component uses the minimum amount of energy to do its job Optimize process technologies Digital, analog, RF Improve power regulation and management 2. Ensure that no electronic component uses energy unless it is doing something useful Clock domains (and gating) Power domains (and gating) Dynamic voltage scaling

WSN engineering invokes cross-layer design challenges! PHY and MAC Routing and Application (selforganization) MAC and Embedded Software (codesign) Embedded Software and ULP MCU s Source and Channel Coding P. Flikkema

Example: ST Micro STM32 (ST Micro and Embedded Control Europe)

Example: Texas Instruments MSP430F5XXX (Texas Instruments)

Take away messages WSN node design is complex Hardware platform (MCU) System software Energy efficiency => h/w-s/w co-design New MCUs are expanding potential for energy-efficient design at the cost of increased software complexity New s/w design approaches are needed Time Energy