find cpu datasheet , watchdog relate registers:

0x18060008 watchdong timer control

0x1806000c watchdog timer

we can read and write watchdog register under uboot console:

#mw 0x1806000c 0xffffffff  1

#mw 0x1806000c 0x10000000  1

#mw 0x18060008    0x3  1

#md 0x18060008  1

#md 0x1806000c 1

// init watchdog function

//init watchdog timer

//int watchdon timer
control

// watchdog action  bit[1:0]

#define No_action                         0

#define General_purpose_interrupt         1

#define Non_maskable_interrupt            2

#define Full_chip_reset                   3

#define WATCHDOG_TIMER_CONTROL  0x18060008

#define WATCHDOG_TIMER          0x1806000c

void enable_watchdog(){

ath_reg_wr(WATCHDOG_TIMER,0xffffffff);

ath_reg_wr(WATCHDOG_TIMER_CONTROL, Full_chip_reset);

}

void disable_watchdog(){

ath_reg_wr(WATCHDOG_TIMER_CONTROL, No_action);

}

void feed_watchdog(){

ath_reg_wr(WATCHDOG_TIMER,0xffffffff);

}

after we  encapsulated watchdog interface; we can enable watchdog in the uboot bootup stage

learning uboot how to enable watchdog in qca4531 cpu的更多相关文章

  1. learning uboot support web http function in qca4531 cpu

    reference :https://forum.openwrt.org/viewtopic.php?id=43237 reference :http://blog.chinaunix.net/uid ...

  2. learning uboot auto switch to stanbdy system in qca4531 cpu

    design: when uboot load kerne failed,we can switch to stanbdy system; how to realize: when boot fail ...

  3. learning uboot enable protect console

    reference :https://github.com/lentinj/u-boot/blob/master/doc/README.autoboot how to enable protect s ...

  4. learning uboot how to set ddr parameter in qca4531 cpu

    DDR工作频率  在600MHZ. include/configs/board953x.h #define CFG_PLL_FREQ            CFG_PLL_650_600_200 #d ...

  5. learning uboot test command

    uboot commad test test - minimal test like /bin/sh so we can use test command to some judge for exam ...

  6. learning uboot distro design in am335x-evm board

    reference: uboot_dir/doc/README.distro Linux distributions are faced with supporting a variety of bo ...

  7. learning uboot switch to standby system using button

    pseudocode: If(reset_button was pressed ) { Change  uboot env bootslot^1 }

  8. learning uboot source command

    reference: http://www.denx.de/wiki/DULG/UBootCmdGroupExec => help source source - run script from ...

  9. learning uboot fstype command

    => fstypefstype - Look up a filesystem type Usage:fstype <interface> <dev>:<part&g ...

随机推荐

  1. 20145317彭垚《网络对抗》Exp9 Web安全基础实践

    20145317彭垚<网络对抗>Exp9 Web安全基础实践 基础问题回答 SQL注入攻击原理,如何防御? SQL注入攻击就是通过把SQL命令插入到Web表单递交或输入域名或页面请求的查询 ...

  2. Git入门私房菜

    昨天下午参考廖雪峰的博客和其他一些文章,简单了解了一下传说中的Git,发现常见用法入门还是挺容易上手的,在此做一些笔记,方便以后查阅和复习. Git安装 Linux sudo apt-get inst ...

  3. 怎么在VS监视DataSet类型的数据

    旧版本 先监视DataSet,打开dataset,dataset下面有一个tablesTables打开有一个非公共成员,然后下面有一个List,List中存储了每一张表的信息 下图所示的List下面的 ...

  4. C#学习笔记(五):while循环和for循环

    while循环 while循环和for循环,可以相互替换,范围和效能一样,理解事物的逻辑不一样 while循环用于条件不确定的逻辑 for循环用于计算次数的逻辑 for循环 快捷写法,按两下TAB i ...

  5. Ubuntu 下 su:authentication failure的解决办法

    Ubuntu下使用 su 切换到超级用户时候遇到下面的问题 su: Authentication failure 解决办法: $ sudo passwd root Enter new UNIX pas ...

  6. plsql过期解决方法

    1.首先,登陆PL/SQL Developer,PL/SQL Developer要到期了 2.输入指令“regedit”打开注册表,如图所示 3.然后,在注册表里按HKEY_CURRENT_USER\ ...

  7. mybatis generator插件系列--lombok插件 (减少百分之九十bean代码)

    经常使用mybatis generator生成代码的你 有没有因为生成的getter/setter而烦恼呢? 有没有生成后又手动加toString/hashCode/Equals方法呢? 有没有改一个 ...

  8. Python写ROS 订阅与发布程序

    1. 编写talker代码 vim ..../src/talker.py #!/usr/bin/env python # license removed for brevity import rosp ...

  9. unable to find resource 'xxx\xx\overview.vm' in any resource loader.

    ResourceManager : unable to find resource 'C:\Test\TestConfig\overview.vm' in any resource loader.or ...

  10. Ubuntu16.04下的主题美化

    1.先下载桌面外观管理工具 sudo apt-get install unity-tweak-tool 2.gnome工具 sudo apt-get install gnome-tweak-tool ...