From a47898ae12ee3129727726ee9caf57cbcfc9fdbe Mon Sep 17 00:00:00 2001 From: RooieDirk Date: Wed, 4 Apr 2018 19:35:34 +0200 Subject: [PATCH 1/3] Correct nema in without checksum --- src/NmeaConverter_pi.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/NmeaConverter_pi.cpp b/src/NmeaConverter_pi.cpp index 5798f3b..b46e30f 100644 --- a/src/NmeaConverter_pi.cpp +++ b/src/NmeaConverter_pi.cpp @@ -101,20 +101,26 @@ void NmeaConverter_pi::SetNMEASentence(wxString &sentence) wxString s = sentence; //local copy of sentence s.Trim(); // Removes white-space (space, tabs, form feed, newline and carriage return) if ( b_CheckChecksum ) - { + { if ( nmeaIsValid( s ) ) { //send to all objects - //for( objit = ObjectMap.begin(); objit != ObjectMap.end(); ++objit ) for ( auto const &ent1 : ObjectMap) ent1.second->SetNMEASentence(s); //objit->second->SetNMEASentence(s); } } + else + { + for ( auto const &ent1 : ObjectMap) + ent1.second->SetNMEASentence(s); + } + } void NmeaConverter_pi::SendNMEASentence(wxString sentence) { + sentence.Trim(); wxString Checksum = ComputeChecksum(sentence); sentence = sentence.Append(wxT("*")); sentence = sentence.Append(Checksum); From aa6971e85fae7cb71493d01148eaa0de8205354a Mon Sep 17 00:00:00 2001 From: RooieDirk Date: Tue, 17 Apr 2018 21:34:05 +0200 Subject: [PATCH 2/3] force C11 compiler --- CMakeLists.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8caccae..acc1225 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,11 +1,12 @@ #--------------------------------------------------------------------------- -# Author: Pavel Kalian -# Copyright: 2014 -# License: GPLv2 License +# Author: Dirk Smits +# Copyright: 2018 +# License: GPLv3 License #--------------------------------------------------------------------------- #define minimum cmake version CMAKE_MINIMUM_REQUIRED(VERSION 2.6.2) +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") PROJECT(nmeaconverter_pi) From 49b751b8ad7e1af78a9bfba6fd34877df59e3fc2 Mon Sep 17 00:00:00 2001 From: RooieDirk Date: Tue, 24 Apr 2018 08:28:15 +0200 Subject: [PATCH 3/3] Update version no. to 1.0 --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index acc1225..88a9971 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,8 +15,8 @@ SET(VERBOSE_NAME NmeaConverter) SET(TITLE_NAME NmeaConverter) SET(CPACK_PACKAGE_CONTACT "RooieDirk") -SET(VERSION_MAJOR "0") -SET(VERSION_MINOR "9") +SET(VERSION_MAJOR "1") +SET(VERSION_MINOR "0") #SET(CMAKE_BUILD_TYPE Debug)