The invention relates to a door dog device with alarm function, wherein said device comprises latch, counter, and controller; when the counter reaches the target value preset in latch, it can alarm to the system via interruption alarm signal, and send out interruption mark signal to the controller, therefore, the system can based on alarm signal store and copy the system data, to avoid data loss and error caused by system reset without alarm function; in addition, the zero of door dog can be processed by several methods as hardware reset, software reset and automatic reset, without additional timer in system to periodically reset the door dog, to save system resource and reduce cost.