thermferm/thermferm.h

changeset 554
ab9f22ab57b5
parent 553
4091d4fe217f
child 557
ae17042a6d39
equal deleted inserted replaced
553:4091d4fe217f 554:ab9f22ab57b5
131 */ 131 */
132 typedef struct _units_list { 132 typedef struct _units_list {
133 struct _units_list *next; 133 struct _units_list *next;
134 int version; /* Record version */ 134 int version; /* Record version */
135 char *uuid; /* uid code */ 135 char *uuid; /* uid code */
136 char *name; /* friendly name */ 136 char *product_uuid; /* Beer product uuid */
137 char *product_code; /* Beer product code */
138 char *product_name; /* Beer product name */
137 char *alias; /* alias name 'unit1' */ 139 char *alias; /* alias name 'unit1' */
138 float volume; /* Volume of this unit */ 140 float volume; /* Volume of this unit */
139 char *air_address; /* DS18B20 address */ 141 char *air_address; /* DS18B20 address */
140 int air_state; /* 0=ok, 1=missing, 2=error */ 142 int air_state; /* 0=ok, 1=missing, 2=error */
141 int air_temperature; /* Air temperature in C * 1000 */ 143 int air_temperature; /* Air temperature in C * 1000 */
195 time_t prof_primary_done; /* Profile primary is done */ 197 time_t prof_primary_done; /* Profile primary is done */
196 int prof_fridge_mode; /* Profile fridge/beer mode */ 198 int prof_fridge_mode; /* Profile fridge/beer mode */
197 pid_var *PID_cool; /* PID cooler */ 199 pid_var *PID_cool; /* PID cooler */
198 pid_var *PID_heat; /* PID heater */ 200 pid_var *PID_heat; /* PID heater */
199 int mqtt_flag; /* MQTT print values flag */ 201 int mqtt_flag; /* MQTT print values flag */
202 char *event_msg; /* Event message to log */
200 int alarm_flag; /* Alarm flag */ 203 int alarm_flag; /* Alarm flag */
201 int alarm_last; /* Last alarm state */ 204 int alarm_last; /* Last alarm state */
202 } units_list; 205 } units_list;
203 206
204 #define UNITMODE_OFF 0 /* Unit turned off */ 207 #define UNITMODE_OFF 0 /* Unit turned off */
208 #define UNITMODE_PROFILE 4 /* Unit runs in profile mode */ 211 #define UNITMODE_PROFILE 4 /* Unit runs in profile mode */
209 212
210 #define MQTT_FLAG_DATA 0x0001 /* Show updated data values */ 213 #define MQTT_FLAG_DATA 0x0001 /* Show updated data values */
211 #define MQTT_FLAG_BIRTH 0x0002 /* Show birth instead of data */ 214 #define MQTT_FLAG_BIRTH 0x0002 /* Show birth instead of data */
212 #define MQTT_FLAG_DEATH 0x0004 /* Show death of a unit */ 215 #define MQTT_FLAG_DEATH 0x0004 /* Show death of a unit */
216 #define MQTT_FLAG_DLOG 0x0008 /* Send DLOG message */
213 217
214 218
215 219
216 /* 220 /*
217 * Alarm bits, value above 255 are serious alarms. 221 * Alarm bits, value above 255 are serious alarms.

mercurial