thermferm/mqtt.c

changeset 652
16d3d4b58b5b
parent 632
9bd017df749b
child 666
48cc8868f9f4
--- a/thermferm/mqtt.c	Wed Mar 27 15:49:31 2024 +0100
+++ b/thermferm/mqtt.c	Wed Mar 27 17:19:46 2024 +0100
@@ -1,5 +1,5 @@
 /*****************************************************************************
- * Copyright (C) 2016-2023
+ * Copyright (C) 2016-2024
  *   
  * Michiel Broek <mbroek at mbse dot eu>
  *
@@ -26,6 +26,7 @@
 #include "rdconfig.h"
 #include "devices.h"
 #include "xutil.h"
+#include "delay.h"
 #include "mqtt.h"
 
 extern sys_config       Config;
@@ -1731,7 +1732,7 @@
                     mosquitto_disconnect(mosq);
                     mqtt_disconnect_sent = TRUE;
                 }
-                usleep(100000);
+		mDelay(100);
             }
             rc = MOSQ_ERR_SUCCESS;
         } while (rc == MOSQ_ERR_SUCCESS && mqtt_connected);

mercurial