Page 1 of 1

Help with watch dog

Posted: Fri Feb 10, 2017 4:23 pm
by RLOPES780
Good Morning;

I need to use the watch dog in the attached program.
To make its use correct, do I just need to enable in project options and enable self-cleaning watch dog?
Or do I need to add something else in the code?

Grateful.

Ricardo.

Re: Help with watch dog

Posted: Fri Feb 10, 2017 4:44 pm
by Benj
Hello Ricardo,

To enable the watchdog timer you can normally do this in the Configuration tab of the project options.

The Auto Clear Watchdog timer tickbox in the project options will automatically clear the watchdog for you when calling component macros and when calling large delays (ms / s). It's up to you if you want this on or not. You may find things like delays are effected with this switched on.

You may find you need to add extra watchdog clear instructions into your program. You can do this by adding the following code inside a C icon.

Code: Select all

MX_CLEAR_WATCHDOG;