WatchdogTimer Class
(Automation::WatchdogTimer)The WatchdogTimer More...
Header: | #include <WatchdogTimer.h> |
Inherits: | CDPOperator<T> |
Public Functions
WatchdogTimer(const CDPPropertyBase &in) |
Reimplemented Public Functions
- 18 public functions inherited from CDPOperator
- 17 public functions inherited from CDPOperatorBase
- 46 public functions inherited from CDPBaseObject
- 26 public functions inherited from CDP::StudioAPI::CDPNode
- 22 public functions inherited from CDP::StudioAPI::ICDPNode
Additional Inherited Members
- 1 public variable inherited from CDPOperatorBase
- 1 static public member inherited from CDPBaseObject
- 1 protected function inherited from CDP::StudioAPI::CDPNode
- 8 protected variables inherited from CDPOperator
- 5 protected variables inherited from CDPOperatorBase
- 11 protected variables inherited from CDPBaseObject
Detailed Description
The WatchdogTimer
WatchdogTimer is an operator to detect Reset input inactivity. When Reset is inactive for more than set by Delay input, Timeout output will go high until Reset becomes active again. On application startup, WatchdogTimer remains in a timed out state until it receives the first Reset value change at its input.
Arguments
Name | Description |
---|---|
Reset | Change on Reset value restarts internal delay timer to postpone Timeout going high. |
Delay | Delay sets the amount of time in seconds allowed between Reset input changes. |
Timeout | Timeout becomes high after Reset is inactive for at least the time set by Delay. |
Example
Below is an example plot with Reset input becoming inactive and Timeout going high in response to the inactivity.
Actual Processing Code of the WatchdogTimer
unsigned int WatchdogTimer<T>::Process() { m_output = Timer.TimedOut(); if (LastResetValue != m_input) { Timer.Reset(static_cast<double>(*Delay)); Timer.Start(); LastResetValue = static_cast<double>(m_input); } return STATUS_OK; }
See also Argument.
Member Function Documentation
WatchdogTimer::WatchdogTimer(const CDPPropertyBase &in)
Default constructs an instance of WatchdogTimer.
[override virtual]
void WatchdogTimer::Configure(XMLPrimitive *operatorXML)
[override virtual]
unsigned int WatchdogTimer::Process()
Get started with CDP Studio today
Let us help you take your great ideas and turn them into the products your customer will love.