adapted to latest changes in gwen, more work on data and nodes servers.
This commit is contained in:
@@ -471,7 +471,9 @@ int _sendRebootRequest(GWEN_MSG_ENDPOINT *epTcp, unsigned int uid)
|
||||
return GWEN_ERROR_GENERIC;
|
||||
}
|
||||
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD, GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0,
|
||||
GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
GWEN_MsgEndpoint_AddSendMessage(epTcp, msgOut);
|
||||
GWEN_Msg_free(msgNode);
|
||||
return 0;
|
||||
@@ -490,7 +492,9 @@ int _sendFlashStart(GWEN_MSG_ENDPOINT *epTcp, unsigned int uid)
|
||||
return GWEN_ERROR_GENERIC;
|
||||
}
|
||||
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD, GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0,
|
||||
GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
GWEN_MsgEndpoint_AddSendMessage(epTcp, msgOut);
|
||||
GWEN_Msg_free(msgNode);
|
||||
return 0;
|
||||
@@ -509,7 +513,9 @@ int _sendFlashEnd(GWEN_MSG_ENDPOINT *epTcp, int reason)
|
||||
return GWEN_ERROR_GENERIC;
|
||||
}
|
||||
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD, GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0,
|
||||
GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
GWEN_MsgEndpoint_AddSendMessage(epTcp, msgOut);
|
||||
GWEN_Msg_free(msgNode);
|
||||
return 0;
|
||||
@@ -555,7 +561,9 @@ int _sendFlashRecord(GWEN_MSG_ENDPOINT *epTcp,
|
||||
return GWEN_ERROR_GENERIC;
|
||||
}
|
||||
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD, GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0,
|
||||
GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
GWEN_MsgEndpoint_AddSendMessage(epTcp, msgOut);
|
||||
GWEN_Msg_free(msgNode);
|
||||
|
||||
|
||||
@@ -190,7 +190,7 @@ void _printNodeFromMsg(const GWEN_MSG *msg)
|
||||
uint32_t u;
|
||||
int64_t ts64;
|
||||
GWEN_TIMESTAMP *ts;
|
||||
|
||||
|
||||
ts64=AQH_GetDevicesResponseIpcMsg_GetTimestamp(msg);
|
||||
ts=GWEN_Timestamp_fromInt64(ts64); /* TODO: fix timestamp */
|
||||
|
||||
@@ -254,7 +254,8 @@ int _sendGetDevices(GWEN_MSG_ENDPOINT *epTcp)
|
||||
{
|
||||
GWEN_MSG *msgOut;
|
||||
|
||||
msgOut=AQH_GetDevicesRequestIpcMsg_new(AQH_MSGTYPE_IPC_NODES_GETDEVICES_REQ);
|
||||
msgOut=AQH_GetDevicesRequestIpcMsg_new(AQH_MSGTYPE_IPC_NODES_GETDEVICES_REQ,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0);
|
||||
if (msgOut==NULL) {
|
||||
DBG_ERROR(NULL, "Error creating message");
|
||||
return GWEN_ERROR_GENERIC;
|
||||
|
||||
@@ -175,7 +175,7 @@ int _sendPing(GWEN_MSG_ENDPOINT *epTcp, int nodeAddr)
|
||||
{
|
||||
GWEN_MSG *msgOut;
|
||||
|
||||
msgOut=AQH_PingIpcMsg_new(AQH_MSGTYPE_IPC_NODES_PING, nodeAddr);
|
||||
msgOut=AQH_PingIpcMsg_new(AQH_MSGTYPE_IPC_NODES_PING, GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0, nodeAddr);
|
||||
if (msgOut==NULL) {
|
||||
DBG_ERROR(NULL, "Error creating message");
|
||||
return GWEN_ERROR_GENERIC;
|
||||
|
||||
@@ -212,7 +212,9 @@ int _doSetValue(GWEN_DB_NODE *dbArgs)
|
||||
DBG_ERROR(NULL, "Error creating message");
|
||||
return GWEN_ERROR_GENERIC;
|
||||
}
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD, GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
msgOut=AQH_ForwardIpcMsg_new(AQH_MSGTYPE_IPC_NODES_FORWARD,
|
||||
GWEN_MsgEndpoint_GetNextMessageId(epTcp), 0,
|
||||
GWEN_Msg_GetConstBuffer(msgNode), GWEN_Msg_GetBytesInBuffer(msgNode));
|
||||
if (msgOut==NULL) {
|
||||
DBG_ERROR(NULL, "Error creating message");
|
||||
return GWEN_ERROR_GENERIC;
|
||||
|
||||
Reference in New Issue
Block a user