Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: EALib EthernetInterface_vz mbed-rtos mbed
Fork of header_main_colinas_V0-20-09-14 by
wdt_manager.h
00001 #ifndef __WDT_MANAGER_H__ 00002 #define __WDT_MANAGER_H__ 00003 00004 #include "EthernetInterface.h" 00005 #include "mbed.h" 00006 #include "wdt.h" 00007 00008 extern Watchdog wdt; 00009 extern Timer wdt_timer; 00010 00011 extern UDPSocket udp_wdt_client; 00012 const uint16_t EXTERNAL_WDT_SERVER_PORT = 9395; 00013 const uint16_t EXTERNAL_WDT_HEADER_PORT = 6612; 00014 const uint8_t MIN_CBX_IN_A_BRANCH = 2; 00015 00016 inline int init_wdt () 00017 { 00018 wdt.Configure ( 30.0 ); 00019 wdt_timer.start (); 00020 return ( 0 ); 00021 } 00022 00023 inline int init_external_wdt() 00024 { 00025 udp_wdt_client.set_blocking( false, 0 ); 00026 return ( udp_wdt_client.bind( 6612 ) ); 00027 } 00028 00029 inline void reconnect_extern_wdt_socket() 00030 { 00031 udp_wdt_client.close(); 00032 udp_wdt_client.bind( 6612 ); 00033 udp_wdt_client.set_blocking( false, 0 ); 00034 } 00035 00036 #endif
Generated on Tue Jul 12 2022 16:25:14 by
