cleanup debug out

This commit is contained in:
2021-01-27 16:47:25 +01:00
parent 8e614e76c7
commit b9e0769843
6 changed files with 19 additions and 96 deletions

View File

@ -262,8 +262,8 @@ void vMeshOtaUtilPrintOtaProgress(const uint32_t* const cpcu32TotalImageSize, co
/**
* @fn void vMeshOtaUtilAddAllNeighboursToQueue(void)
* @brief add all neigbhours (children and parent) to queue
* @param void
* @brief add all neigbhours (children and parent) to queue, except node used in parameter
* @param const mesh_addr_t* const cpcMeshNodeAddr
* @return void
* @author Hendrik Schutter
* @date 21.01.2021
@ -287,13 +287,11 @@ void vMeshOtaUtilAddAllNeighboursToQueue(const mesh_addr_t* const cpcMeshNodeAdd
}
else
{
ESP_LOGI(LOG_TAG, "AddAllNodes: parent: %x - %x", addrParent.addr[5], cpcMeshNodeAddr->addr[5]);
vMeshOtaUtilAddNodeToPossibleUpdatableQueue(addrParent.addr);
}
}
else
{
ESP_LOGI(LOG_TAG, "AddAllNodes: NULL parent");
vMeshOtaUtilAddNodeToPossibleUpdatableQueue(addrParent.addr);
}
@ -313,13 +311,11 @@ void vMeshOtaUtilAddAllNeighboursToQueue(const mesh_addr_t* const cpcMeshNodeAdd
}
else
{
ESP_LOGI(LOG_TAG, "AddAllNodes: Child: %x", childrenAddr[u16Index].addr[5]);
vMeshOtaUtilAddNodeToPossibleUpdatableQueue(childrenAddr[u16Index].addr);
}
}
else
{
ESP_LOGI(LOG_TAG, "AddAllNodes: NULL Child: %x", childrenAddr[u16Index].addr[5]);
vMeshOtaUtilAddNodeToPossibleUpdatableQueue(childrenAddr[u16Index].addr);
}
}
@ -366,19 +362,15 @@ void vMeshOtaUtilClearNeighboursQueue(const mesh_addr_t* const cpcMeshNodeAddr)
{
if((bMeshNetworkCheckMacEquality(sNode.addr, cpcMeshNodeAddr->addr)))
{
ESP_LOGI(LOG_TAG, "REMOVE_NODE: remove node %x", sNode.addr[5]);
//same node --> don't add again
}
else
{
ESP_LOGI(LOG_TAG, "//node is NOT cpcMeshNodeAddr: %x --> keep it in queue", sNode.addr[5]);
//node is NOT cpcMeshNodeAddr --> keep it in queue
vMeshOtaUtilAddNodeToPossibleUpdatableQueue(sNode.addr);
}
}
else
{
ESP_LOGI(LOG_TAG, "REMOVE_NODE: queue leer");
}
}//end nodes
}
@ -402,7 +394,7 @@ void vMeshOtaUtilAddNodeToPossibleUpdatableQueue(const uint8_t* const cpcu8MAC)
}
else
{
ESP_LOGI(LOG_TAG, "added node \"%x:%x:%x:%x:%x:%x\" to possible updatable queue", addrNode.addr[0], addrNode.addr[1], addrNode.addr[2], addrNode.addr[3], addrNode.addr[4], addrNode.addr[5]);
ESP_LOGD(LOG_TAG, "added node \"%x:%x:%x:%x:%x:%x\" to possible updatable queue", addrNode.addr[0], addrNode.addr[1], addrNode.addr[2], addrNode.addr[3], addrNode.addr[4], addrNode.addr[5]);
}
}
@ -426,14 +418,14 @@ void vMeshOtaUtilAddOtaMessageToQueue(const MESH_PACKET_t* const cpcuMeshPacket)
switch (cpcuMeshPacket->type)
{
case OTA_Abort:
ESP_LOGI(LOG_TAG, "added ota message to queue: OTA_Abort from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
ESP_LOGD(LOG_TAG, "added ota message to queue: OTA_Abort from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
break;
case OTA_Version_Request:
ESP_LOGI(LOG_TAG, "added ota message to queue: OTA_Version_Request from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
ESP_LOGD(LOG_TAG, "added ota message to queue: OTA_Version_Request from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
break;
case OTA_Version_Response:
ESP_LOGI(LOG_TAG, "added ota message to queue: OTA_Version Response from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
ESP_LOGD(LOG_TAG, "added ota message to queue: OTA_Version Response from 0x%x", cpcuMeshPacket->meshSenderAddr.addr[5]);
break;
default:
break;