Modified watchdog method to receive specific types of messages and receive a callback function.