# HG changeset patch # User ideenmodellierer # Date 1575320585 -3600 # Node ID 2d980f76503483aec342a2d8a980eaa80d1e31a2 # Parent 1db721dda6827d73db8f66566f398541253b3d4a Bugfix: Merge / cleanup problem: wrong variable used for receiption diff -r 1db721dda682 -r 2d980f765034 Discovery/Src/tComm.c --- a/Discovery/Src/tComm.c Sun Dec 01 19:55:15 2019 +0100 +++ b/Discovery/Src/tComm.c Mon Dec 02 22:03:05 2019 +0100 @@ -534,7 +534,7 @@ while((answer == prompt4D4C(receiveStartByteUart)) && (timeoutCounter < UART_TIMEOUT_SECONDS)) /* try receive once a second */ { - if(HAL_UART_Receive(&UartHandle, (uint8_t*)&aRxByte, 1, 1000)!= HAL_OK) + if(HAL_UART_Receive(&UartHandle, (uint8_t*)&localRx, 1, 1000)!= HAL_OK) { timeoutCounter++; get_globalStateList(&status); @@ -591,8 +591,11 @@ count = 0; // Ignore communication on Text like RING, CONNECT, - if(type < 0x60) return prompt4D4C(receiveStartByteUart); - + if(type == 0xFF) return 0; + if(type < 0x60) + { + return prompt4D4C(receiveStartByteUart); + } // service mode only commands if(receiveStartByteUart == BYTE_SERVICE_MODE) { @@ -632,8 +635,6 @@ logCopyDataLength.u32bit = 0; totalDiveCount.u16bit = 0; #endif - // Exit communication on 0xFF command - if(type == 0xFF) return 0; // return of command for (almost) all commands switch(type)