Watchdog timer special function register and example software design

Publisher:梦中徐来Latest update time:2013-03-30 Source: dzscKeywords:Watchdog Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
    1. Watchdog timer special function register

  (1) Watchdog timer control register WTCON

  The watchdog timer control register WTCON is shown in Table 1. WTCON can enable the watchdog timer to select the clock signal from 4 different clock sources, enable or disable interrupts, and enable or disable the watchdog timer reset signal input.

  Table 1 Watchdog timer control register WTCON

  The watchdog timer is used to recover normal operation from an error after power supply using S3C44B0X. If you do not want to restart the processor, then the watchdog timer is disabled; if you want to use the normal timing function provided by the watchdog timer, you need to use the interrupt and watchdog timer functions.

  (2) Watchdog timer data register WTDAT

  The watchdog timer data register WTDAT is shown in Table 2. WTDAT is used to set the time limit value. After the watchdog timer is initialized, WTDAT cannot be automatically loaded into the timer counter. Initialization uses 0x8000. After the first time limit occurs, the WTDAT value will be automatically loaded into WTCNT.

  Table 2 Watchdog timer data register WTDAT

  (3) Watchdog timer count register WTCNT

  The watchdog timer count register WTCNT is shown in Table 3. WTCNT contains the current count value of the watchdog timer under normal operation, so before enabling, the watchdog timer count register needs to be set to an initial value of 0x8000.

  Table 3 Watchdog timer count register WTCNT

  2. Example software design

  The software design of the watchdog in this example mainly includes the initialization of the watchdog, feeding the dog, etc. Through the following program, the user can intuitively see the process of the watchdog resetting the system. [page]

  Function to turn on/off the LED light:

Keywords:Watchdog Reference address:Watchdog timer special function register and example software design

Previous article:Reliability Technology and Development of Single Chip Microcomputer System
Next article:ADC0809 AD converter basic application technology

Recommended ReadingLatest update time:2024-11-17 10:48

STM8L timer2 timing interrupt
Introduction This article introduces how to use timer2 to generate timer interrupts in the STM8L series. experiment platform Compiler software: IAR for STM8 1.42.2 Hardware platform: stm8l101f3p6 development board Emulator: ST-LINK Library version: STM8L_STMTouch_Lib_V1.1.0 Experimental procedures 1. A
[Microcontroller]
STM8L timer2 timing interrupt
TQ2416 development board TIMER interrupt application control device
       This issue introduces the control device code application of the new generation ARM9 development board TQ2416, using TIMER code to control the time period of the device. Timer syntax, timer code, the function is to repeatedly trigger the timer event of the specified window within the specified time interval.
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号