EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Watchdog timer

Started by magesh December 17, 2010
Hello,

I am a newbie to Embedded systems.

We are using Linux. 


watchdog timer implementation as follows:

In the software setting the watchdog timer and on timeout it clears the
hardware register which is used by the hardware to check if the system
needs to be reset or not.

But we are facing some problem in the hardware ( for example video is
freezing and the system hangs). In this case how to make the system reset
?

Will watchdog timers be used only for the problems in Software ? If so how
to reset the system in case of hardware failures ?

Thanks


	   
					
---------------------------------------		
Posted through http://www.EmbeddedRelated.com
On Dec 17, 7:43=A0am, "magesh" <rvaneetha@n_o_s_p_a_m.yahoo.co.in>
wrote:
> Hello, > > I am a newbie to Embedded systems. > > We are using Linux. > > watchdog timer implementation as follows: > > In the software setting the watchdog timer and on timeout it clears the > hardware register which is used by the hardware to check if the system > needs to be reset or not. > > But we are facing some problem in the hardware ( for example video is > freezing and the system hangs). In this case how to make the system reset > ? > > Will watchdog timers be used only for the problems in Software ? If so ho=
w
> to reset the system in case of hardware failures ? > > Thanks > > --------------------------------------- =A0 =A0 =A0 =A0 > Posted throughhttp://www.EmbeddedRelated.com
I'm not sure I understand the problem, but it sounds as if you have a 'reset' problem - not just a watchdog timer problem. Do you experience hardware problems with a 'push button' reset? If so, those must be addressed first.
"magesh" <rvaneetha@n_o_s_p_a_m.yahoo.co.in> wrote in message 
news:A7GdneodF6Bo9ZbQnZ2dnUVZ_uOdnZ2d@giganews.com...
> > But we are facing some problem in the hardware ( for example video is > freezing and the system hangs). In this case how to make the system reset > ? > > Will watchdog timers be used only for the problems in Software ? If so how > to reset the system in case of hardware failures ? >
The idea behind the watchdog timer is that you should choose some part of your application code that executes periodically in normal circumstances. You should set the timeout in the watchdog timer to be just greater than the maximum expected time between successive executions of that bit of code. Then when your system hangs, your code doesn't get executed, the watchdog timer is not reset, the watchdog times out and a system reset occurs, Regards, Chris Burrows CFB Software http://www.cfbsoftware.com
Hi Chris,

Chris Burrows wrote:
> "magesh" <rvaneetha@n_o_s_p_a_m.yahoo.co.in> wrote in message > news:A7GdneodF6Bo9ZbQnZ2dnUVZ_uOdnZ2d@giganews.com... >> But we are facing some problem in the hardware ( for example video is >> freezing and the system hangs). In this case how to make the system reset >> ? >> >> Will watchdog timers be used only for the problems in Software ? If so how >> to reset the system in case of hardware failures ? > > The idea behind the watchdog timer is that you should choose some part of > your application code that executes periodically in normal circumstances. > You should set the timeout in the watchdog timer to be just greater than the > maximum expected time between successive executions of that bit of code. > > Then when your system hangs, your code doesn't get executed, the watchdog > timer is not reset, the watchdog times out and a system reset occurs,
I think the OP is missing the key criteria that the watchdog must -- itself -- trigger the reset (in hardware). And that stroking the watchdog just interrupts that process (until you fail to do so!). I.e., it seems as if the OP has a *task* (thread, process, etc.) that acts as the hardware watchdog would. So, when the processor goes south, that task is just as crippled (unable to reset the processor) as the "main application". Strategies for how best to stroke the watchdog are yet another subject... :>

The 2024 Embedded Online Conference