From 2108ea53fa14fc467ca52c8179b7b5a45e97a853 Mon Sep 17 00:00:00 2001 From: GullCode Date: Thu, 21 Apr 2022 17:38:49 +0200 Subject: [PATCH] Fix for proc_aprsrx and aprs_packet warnings, they are related --- firmware/baseband/proc_aprsrx.hpp | 10 +++++----- firmware/common/aprs_packet.hpp | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/firmware/baseband/proc_aprsrx.hpp b/firmware/baseband/proc_aprsrx.hpp index 2d3c4568..9bcc4828 100644 --- a/firmware/baseband/proc_aprsrx.hpp +++ b/firmware/baseband/proc_aprsrx.hpp @@ -125,18 +125,18 @@ private: uint32_t sample_bits { 0 }; uint32_t phase { }, phase_inc { }; int32_t sample_mixed { }, prev_mixed { }, sample_filtered { }, prev_filtered { }; - uint8_t last_bit; - uint8_t ones_count = 0; + uint8_t last_bit = 0; + uint8_t ones_count = 0 ; uint8_t current_byte = 0; uint8_t byte_index = 0; uint8_t packet_buffer[256]; size_t packet_buffer_size = 0; bool configured { false }; - bool wait_start { }; - bool bit_value { }; + bool wait_start { 0 }; + bool bit_value { 0 }; - aprs::APRSPacket aprs_packet; + aprs::APRSPacket aprs_packet { }; void configure(const APRSRxConfigureMessage& message); void capture_config(const CaptureConfigMessage& message); diff --git a/firmware/common/aprs_packet.hpp b/firmware/common/aprs_packet.hpp index e521a955..c7e7c1db 100644 --- a/firmware/common/aprs_packet.hpp +++ b/firmware/common/aprs_packet.hpp @@ -259,7 +259,7 @@ private: bool valid_checksum = false; uint8_t payload[256]; char address_buffer[15]; - uint8_t payload_size; + uint8_t payload_size = 0 ; Timestamp timestamp_ { }; float parse_lat_str_cmp(const std::string& lat_str){