Conclusion Speech. Content Organization Pronunciation Handwriting.

Slides:



Advertisements
Similar presentations
Interrupts, Low Power Modes and Timer A (Chapters 6 & 8)
Advertisements

4-1 Timers Timers can be used for  timing  event counting  pulse width measurement  pulse generation  frequency multiplication There are 8 Timers.
C Examples 1.
Chung-Ta King National Tsing Hua University
Programmable Keyboard/ Display Interface: 8279
8051 Core Specification.
CSCI 4717/5717 Computer Architecture
Introduction of Holtek HT-46 series MCU
Architectural Support for OS March 29, 2000 Instructor: Gary Kimura Slides courtesy of Hank Levy.
The Cortex-M3 Embedded Systems: LM3S9B96 Microcontroller – System Control Refer to Chapter 6 in the reference book “Stellaris® LM3S9B96 Microcontroller.
INTERRUPTS PROGRAMMING
Lecture 13: TI MSP430 Watchdog Timer and Real-Time Clock
AVR Reset Sources When a reset event occurs.... -I/O registers set to initial values immediately -internal delay stretched to allow power to stabilize.
LAB 7: WDT+ and Low-Power Optimization
Serial Peripheral Interface Module MTT M SERIAL PERIPHERAL INTERFACE (SPI)
Ch. 9 Interrupt Programming and Real-Time Sysstems From Valvano’s Introduction to Embedded Systems.
8253 TIMER. Engr 4862 Microprocessors 8253 / 8254 Timer A.k.a. PIT (programmable Interval Timer), used to bring down the frequency to the desired level.
8254 Counter/Timer Counter Each of the three counter has 3 pins associated CLK: input clock frequency- 8 MHz OUT GATE: Enable (high) or disable.
ARM Timers.
1 4-Integrating Peripherals in Embedded Systems. 2 Introduction Single-purpose processors  Performs specific computation task  Custom single-purpose.
System Clocks.
M Semiconductor Products Sector Computer Operating Properly Module Detail Slide #1 of 7 Tutorial Introduction PURPOSE -To explain how to configure and.
8254 SOFTWARE PROGRAMMABLE TIMER/COUNTER
Timers The timers of the PIC16C7X microcontroller can be briefly described in only one sentence. There are three completely independent timers/counters.
Clock Options and Sleep Modes. Clock Sources Flash Fuse bits can be programmed to choose one of the following Clock sources: 1. External RC Osc. f = 1/(3RC).
The 8253 Programmable Interval Timer
Khaled A. Al-Utaibi  Interrupt-Driven I/O  Hardware Interrupts  Responding to Hardware Interrupts  INTR and NMI  Computing the.
Prepared by Eng. Musa Alyaman1 Chapter Seven Chapter Seven PIC16F87x.
Lecture 25: LM3S9B96 Microcontroller – Watchdog Timer.
The Functions of Operating Systems Interrupts. Learning Objectives Explain how interrupts are used to obtain processor time. Explain how processing of.
Lecture 11 Low Power Modes & Watchdog Timers
Interrupt.
© 2009, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction  Purpose This course provides an introduction to the peripheral functions.
Timer Timer is a device, which counts the input at regular interval (δT) using clock pulses at its input. The counts increment on each pulse and store.
Low Power Modes MTT48 V LOW POWER OPERATION.
ATtiny23131 A SEMINAR ON AVR MICROCONTROLLER ATtiny2313.
1 © Unitec New Zealand Interrupt Lecture 6 Date: - 20 Sept, 2011 Embedded Hardware ETEC 6416.
Interrupts  An interrupt is any service request that causes the CPU to stop its current execution stream and to execute an instruction stream that services.
© 2009, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction  Purpose This course provides an introduction to the peripheral functions.
System Integration Module MTT Motoola SYSTEM INTEGRATION MODULE (SIM)
Chapter 5 - Interrupts.
1-3 GPIO_Output(LuminaryLibrary) 1.Alter the output current to 4mA 2.Let LED0 turn on but LED 1 turn off. Modify your program in E:\yourname\arm.
C Examples 1. Download Links dsPIC30F4011/4012 Data Sheet dsPIC30F4013/3014 dsPIC30F Family Reference Manual MikroC MikroC Manual MikroC Quick Reference.
Lecture 4 General-Purpose Input/Output NCHUEE 720A Lab Prof. Jichiang Tsai.
Lecture 22: LM3S9B96 Microcontroller – SysTick and General-Purpose Timers.
Time Management.  Time management is concerned with OS facilities and services which measure real time.  These services include:  Keeping track of.
The Cortex-M3 Embedded Systems: LM3S9B96 Microcontroller – Watchdog Timers Refer to Chapter 11 in the reference book “Stellaris® LM3S9B96 Microcontroller.
Computer Operating Properly Module MTT COMPUTER OPERATING PROPERLY MODULE (COP)
Introduction to Exceptions 1 Introduction to Exceptions ARM Advanced RISC Machines.
Special Features. Device Configuration bits Revision Device Configuration bits Revision On-chip Power-on Reset (POR) Revision On-chip Power-on Reset (POR)
TM Freescale Confidential Proprietary Freescale™ and the Freescale logo are trademarks of Freescale Semiconductor, Inc. All other product or service names.
TIMERS.
Timer modules in PIC 16F877.  The PIC 16F877 basically has three independent timer modules,  denoted by the symbols, TIMER-0, TIMER1,andTIMER2. . These.
68HC11 Interrupts & Resets.
Refer to Chapter 5 in the reference book
Interrupts In 8085 and 8086.
RX Watchdog Timer (WDT)
Programmable Interval Timer
Programmable Interval Timer 8254 LECTURE 3
Refer to Chapter 3 in the reference book
AVR Addressing Modes Subject: Microcontoller & Interfacing
RX Compare Match Timer (CMT)
Processor Fundamentals
전자의료시스템 및 실습 System Configuration/Interrupt
嵌入式微控制器编程 Embedded Microcontroller Programming
8253 – PROGRAMMABLE INTERVAL TIMER (PIT). What is a Timer? Timer is a specialized type of device that is used to measure timing intervals. Timers can.
8051 Development System Details
Presentation transcript:

Conclusion Speech

Content Organization Pronunciation Handwriting

Lab 5 Watchdog A watchdog timer can generate an interrupt or a reset when a time-out value is reached. The watchdog timer is used to regain control when a system has failed due to a software error or due to the failure of an external device to respond in the expected way. The LM3S9B92 microcontroller has two Watchdog Timer Modules, one module is clocked by the system clock (Watchdog Timer 0) and the other is clocked by the PIOSC (Watchdog Timer 1). The two modules are identical except that WDT1 is in a different clock domain, and therefore requires synchronizers. As a result, WDT1 has a bit defined in the Watchdog Timer Control (WDTCTL) register to indicate when a write to a WDT1 register is complete. Software can use this bit to ensure that the previous access has completed before starting the next access.

The Stellaris LM3S9B92 controller has two Watchdog Timer modules with the following features: ■ 32-bit down counter with a programmable load register ■ Separate watchdog clock with an enable ■ Programmable interrupt generation logic with interrupt masking ■ Lock register protection from runaway software ■ Reset generation logic with an enable/disable ■ User-enabled stalling when the microcontroller asserts the CPU Halt flag during debug

The Watchdog Timer can be configured to generate an interrupt to the controller on its first time-out, and to generate a reset signal on its second time-out. Once the Watchdog Timer has been configured, the lock register can be written to prevent the timer configuration from being inadvertently altered.

Functional Description The Watchdog Timer module generates the first time-out signal when the 32-bit counter reaches the zero state after being enabled; enabling the counter also enables the watchdog timer interrupt. After the first time-out event, the 32-bit counter is re-loaded with the value of the Watchdog Timer Load (WDTLOAD) register, and the timer resumes counting down from that value. Once the Watchdog Timer has been configured, the Watchdog Timer Lock (WDTLOCK) register is written, which prevents the timer configuration from being inadvertently altered by software. If the timer counts down to its zero state again before the first time-out interrupt is cleared, and the reset signal has been enabled by setting the RESEN bit in the WDTCTL register, the Watchdog timer asserts its reset signal to the system. If the interrupt is cleared before the 32-bit counter reaches its second time-out, the 32-bit counter is loaded with the value in the WDTLOAD register, and counting resumes from that value. If WDTLOAD is written with a new value while the Watchdog Timer counter is counting, then the counter is loaded with the new value and continues counting.

Writing to WDTLOAD does not clear an active interrupt. An interrupt must be specifically cleared by writing to the Watchdog Interrupt Clear (WDTICR) register. The Watchdog module interrupt and reset generation can be enabled or disabled as required. When the interrupt is re-enabled, the 32-bit counter is preloaded with the load register value and not its last state.

Register Access Timing Because the Watchdog Timer 1 module has an independent clocking domain, its registers must be written with a timing gap between accesses. Software must guarantee that this delay is inserted between back-to-back writes to WDT1 registers or between a write followed by a read to the registers. The timing for back-to-back reads from the WDT1 module has no restrictions. The WRC bit in the Watchdog Control (WDTCTL) register for WDT1 indicates that the required timing gap has elapsed. This bit is cleared on a write operation and set once the write completes, indicating to software that another write or read may be started safely. Software should poll WDTCTL for WRC=1 prior to accessing another register. Note that WDT0 does not have this restriction as it runs off the system clock.

Initialization and Configuration To use the WDT, its peripheral clock must be enabled by setting the WDT bit in the RCGC0 register, see page 271. The Watchdog Timer is configured using the following sequence: 1. Load the WDTLOAD register with the desired timer load value. 2. If WDT1, wait for the WRC bit in the WDTCTL register to be set. 3. If the Watchdog is configured to trigger system resets, set the RESEN bit in the WDTCTL register. 4. If WDT1, wait for the WRC bit in the WDTCTL register to be set. 5. Set the INTEN bit in the WDTCTL register to enable the Watchdog and lock the control register. If software requires that all of the watchdog registers are locked, the Watchdog Timer module can be fully locked by writing any value to the WDTLOCK register. To unlock the Watchdog Timer, writea value of 0x1ACC.E551.

Experiment 5 Goal : comprehend the principle of the watchdog timer. learn how to initialize and start watchdog timer module. get familiar with API function in Luminary library about watchdog, understand the function of watchdog.

Content: Initial state: both yellow and green LED are turned on ; Press any key of Up , Down , Left and Right , yellow led (LED0) will flash in follow pattern: on 0.1S , off 0.1S , on 0.1S , off 0.1S , on 0.1S , off 0.5S , one cycle is 1S ; Push down Press key , turn on green led ( LED1 ) 0.1S and “feed dog”; Set watchdog period to 2S. The system will be reset, back to initial state, if you do not feed dog before the yellow LED finishes 4 cycles flashing.