mirror of
				https://github.com/Tediore/battery2mqtt.git
				synced 2025-11-03 20:46:35 +01:00 
			
		
		
		
	Add heartbeat
This commit is contained in:
		@@ -132,6 +132,10 @@ def get_info():
 | 
			
		||||
                    logging.debug('Sending MQTT payload: ' + str(payload))
 | 
			
		||||
        except Exception as e:
 | 
			
		||||
            logging.error(f'Message send failed: {e}')
 | 
			
		||||
    try:
 | 
			
		||||
        client.publish("battery2mqtt/" + MQTT_TOPIC + '/status', 'online', 0, True)
 | 
			
		||||
    except Exception as e:
 | 
			
		||||
        logging.error(f'Message send failed: {e}')
 | 
			
		||||
 | 
			
		||||
check_conditions()
 | 
			
		||||
mqtt_connect()
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user