Started working on aqhome-nodes which will replace aqhomed.
This commit is contained in:
@@ -94,6 +94,22 @@ const char *AQH_Value2Msg_GetValueAsWindowStateString(const GWEN_MSG *msg)
|
||||
|
||||
|
||||
|
||||
const char *AQH_Value2Msg_GetValueTypeUnits(const GWEN_MSG *msg)
|
||||
{
|
||||
uint8_t t;
|
||||
|
||||
t=AQH_Value2Msg_GetValueType(msg);
|
||||
switch(t) {
|
||||
case AQH_MSG_VALUE2_TYPE_TEMP: return "Celsius";
|
||||
case AQH_MSG_VALUE2_TYPE_HUMIDITY: return "%";
|
||||
case AQH_MSG_VALUE2_TYPE_DOOR: return NULL;
|
||||
default: break;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
double AQH_Value2Msg_GetValue(const GWEN_MSG *msg)
|
||||
{
|
||||
if ((AQH_NodeMsg_GetMsgType(msg)==AQH_MSG_TYPE_VALUE2) &&
|
||||
|
||||
@@ -34,6 +34,7 @@ AQHOME_API double AQH_Value2Msg_GetValue(const GWEN_MSG *msg);
|
||||
|
||||
AQHOME_API const char *AQH_Value2Msg_GetValueAsWindowStateString(const GWEN_MSG *msg);
|
||||
AQHOME_API const char *AQH_Value2Msg_GetValueTypeName(const GWEN_MSG *msg);
|
||||
AQHOME_API const char *AQH_Value2Msg_GetValueTypeUnits(const GWEN_MSG *msg);
|
||||
|
||||
AQHOME_API void AQH_Value2Msg_DumpToBuffer(const GWEN_MSG *msg, GWEN_BUFFER *dbuf, const char *sText);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user