From: Nathael Pajani Date: Fri, 12 Jun 2020 10:35:55 +0000 (+0200) Subject: Fixes related to dtplug protocol to rc_car app X-Git-Url: http://git.techno-innov.fr/?a=commitdiff_plain;h=1ecc9e07a3fbbc1c4135384fa4a0bb1c8ad997ac;p=soft%2Fperso%2Fcpe Fixes related to dtplug protocol to rc_car app --- diff --git a/cape_rccar/main.c b/cape_rccar/main.c index 97348ee..2cdb275 100644 --- a/cape_rccar/main.c +++ b/cape_rccar/main.c @@ -513,10 +513,10 @@ void quickdata_to_packet(struct packet* pkt) if (head->seq_num & QUICK_DATA_PACKET) { pkt->data[0] = head->quick_data[0]; pkt->data[1] = head->quick_data[1]; - if (head->seq_num & QUICK_DATA_PACKET_ONE_BYTE) { - head->data.size = 1; - } else { + if (head->seq_num & QUICK_DATA_PACKET_TWO_BYTES) { head->data.size = 2; + } else { + head->data.size = 1; } } }