Watchdog

Started by blejku, October 11, 2013, 01:26:41 AM

Previous topic - Next topic

blejku

Welcome
How to run a watchdog on the A20? Debian does not have an official watchdog device and I can not find how to start
The only thing that I found it.
/ lib/modules/3.4.61 + / kernel / drivers / watchdog

David Goadby

I'm needing this too. Did you get anywhere yet?

David Goadby

David Goadby

I'm going to assume that this works in a similar way to other ARM units so there should be a compiler constant called CONFIG_WATCHDOG which needs to be set when compiling the kernel.

If /dev/watchdog exists then maybe it is already enabled.

To arm the watchdog you open /dev/watchdog and write anything to it.

The watchdog will timeout after 19 or 20 seconds unless it is "kicked".

To "kick" the watchdog write anything to /dev/watchdog

I haven't tried it but writing 0 to /dev/watchdog should disable it.

I will report more after I have it running. ;-)

David Goadby

blejku

I decided that it would be an external watchdog circuit. I care for maximum stability. I used the MAX6373 because of the start of the system and retard the heartbeat signal

David Goadby

Funnily enough I think the MAX6373 is a better choice. Using an external watchdog ensures both a good reset at start-up and a reliable watchdog mechanism. There are always lots of I/O's spare to drive it too.

David Goadby

Leonardo

Hello, where did you connect the Watchdog chip output? Is the GPIO-2 pin 40 (reset_n) useful for the purpose? Is there any suitable input of the AXP209 available on gpio connector? Because the reset_n signal goes only to the A20.

Leo

David Goadby

I picked up /reset on GPIO-2 Pin 40 but you can use the NO side of the reset switch too.

kestas

I'm trying to use sunxi-wdt on ArchLinux on A20-OLinuXino-MICRO. It seams driver is loaded, but I can't make the A20 to reboot.

# dmesg | grep sunxi-wdt
[    2.336594] sunxi-wdt 1c20c90.watchdog: Watchdog enabled (timeout=16 sec, nowayout=1)


Tried to reboot using (both /dev/watchdog and /dev/watchdog0):

# echo a > /dev/watchdog
# cat > /dev/watchdog
a


Also tried watchdog daemon. I see the following lines in dmesg output, but board dosn't reboot:


[38899.172710] watchdog watchdog0: watchdog did not stop!


Software watchdog (softdog kernel module) works as expected. Am I missing someting specific to A20?