com.esf.device.watchdog.service
Interface IWatchdogService


public interface IWatchdogService

This interface provides methods for starting, stopping, and updating a hardware watchdog present on the system. Updating the watchdog, once started, prevents the system from rebooting.

Author:
chad.kienle

Field Summary
static java.lang.String SERVICE_NAME
          Reports the class name representing this interface.
 
Method Summary
 short getDefaultTimeout()
          Returns the default timeout value of the hardware watchdog.
 short getTimeout()
          Returns the timeout value for the hardware watchdog in increments of 100ms.
 void setTimeout(short timeout)
          Sets the current timeout value for the underlying hardware watchdog.
 void startWatchdog()
          Starts the hardware watchdog on the device.
 void stopWatchdog()
          Stops the hardware Watchdog on the device
 void updateWatchdog()
          Updates the Watchdog to prevent a system reboot by resetting the timer
 

Field Detail

SERVICE_NAME

public static final java.lang.String SERVICE_NAME
Reports the class name representing this interface.

Method Detail

startWatchdog

public void startWatchdog()
Starts the hardware watchdog on the device. If a timeout value has not been set, the watchdog will use its default timeout.


stopWatchdog

public void stopWatchdog()
Stops the hardware Watchdog on the device


updateWatchdog

public void updateWatchdog()
Updates the Watchdog to prevent a system reboot by resetting the timer


getTimeout

public short getTimeout()
Returns the timeout value for the hardware watchdog in increments of 100ms.

Returns:
A short representing the hardware timeout value.

getDefaultTimeout

public short getDefaultTimeout()
Returns the default timeout value of the hardware watchdog.

Returns:
A short representing the hardware watchdog's default timeout.

setTimeout

public void setTimeout(short timeout)
Sets the current timeout value for the underlying hardware watchdog. When setting the timeout after the watchdog has been started the count will be reset. The timeout value should be specified in increments of 100 milliseconds. For example: A timeout value of 20 would be 2000 milliseconds.

Parameters:
timeout - A short representing the new timeout value in increments of 100ms.
Throws:
java.lang.Exception - throws an Exception if the supplied timeout is not valid.


Copyright © 2009 Eurotech Inc. All rights reserved.