From 9f19001fdbe2a6740483b2622f9be2e659d63aa3 Mon Sep 17 00:00:00 2001 From: c-my Date: Sun, 21 Oct 2018 20:42:36 +0800 Subject: [PATCH] update --- Radar.pro.user | 301 +++++++++++++++++++++++++++++++++--- Radar.pro.user.022bc4f | 339 +++++++++++++++++++++++++++++++++++++++++ radar.cpp | 4 +- serialcontroller.cpp | 6 +- 4 files changed, 626 insertions(+), 24 deletions(-) create mode 100644 Radar.pro.user.022bc4f diff --git a/Radar.pro.user b/Radar.pro.user index f2863cb..f22807d 100644 --- a/Radar.pro.user +++ b/Radar.pro.user @@ -1,10 +1,10 @@ - + EnvironmentId - {022bc4f8-bda1-4795-81ea-8a5cd54ff33c} + {2c3e6c03-a454-4a53-bc1b-c224563b9344} ProjectExplorer.Project.ActiveTarget @@ -62,14 +62,14 @@ ProjectExplorer.Project.Target.0 - Desktop Qt 5.11.1 GCC 64bit - Desktop Qt 5.11.1 GCC 64bit - qt.qt5.5111.gcc_64_kit + Desktop Qt 5.11.2 GCC 64bit + Desktop Qt 5.11.2 GCC 64bit + qt.qt5.5112.gcc_64_kit 0 0 0 - /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Debug + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit-Debug true @@ -123,13 +123,13 @@ false Debug - + Debug Qt4ProjectManager.Qt4BuildConfiguration 2 true - /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Release + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit-Release true @@ -140,7 +140,7 @@ false false - false + true true @@ -183,13 +183,13 @@ false Release - + Release Qt4ProjectManager.Qt4BuildConfiguration 0 true - /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Profile + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit-Profile true @@ -200,7 +200,7 @@ false true - false + true true @@ -243,7 +243,7 @@ false Profile - + Profile Qt4ProjectManager.Qt4BuildConfiguration 0 true @@ -252,12 +252,12 @@ 0 - Deploy + 部署 ProjectExplorer.BuildSteps.Deploy 1 - Deploy locally + Deploy Configuration ProjectExplorer.DefaultDeployConfiguration @@ -307,13 +307,276 @@ Radar - Qt4ProjectManager.Qt4RunConfiguration:/home/wmj/Arduino/Radar/Radar.pro + Qt4ProjectManager.Qt4RunConfiguration:/home/cmy/Projects/Radar/Radar.pro true Radar.pro - false - /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Debug + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit-Debug + 3768 + false + true + false + false + true + + 1 + + + + ProjectExplorer.Project.Target.1 + + Desktop Qt 5.11.2 GCC 64bit_static + Desktop Qt 5.11.2 GCC 64bit_static + {e0a85e13-9414-41c1-b1e3-1b96941c2dc8} + 2 + 0 + 0 + + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit_static-Debug + + + true + qmake + + QtProjectManager.QMakeBuildStep + true + + false + false + false + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Debug + Debug + Qt4ProjectManager.Qt4BuildConfiguration + 2 + true + + + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit_static-Release + + + true + qmake + + QtProjectManager.QMakeBuildStep + false + + false + false + true + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release + Release + Qt4ProjectManager.Qt4BuildConfiguration + 0 + true + + + /home/cmy/Projects/build-Radar-Desktop_Qt_5_11_2_GCC_64bit_static-Profile + + + true + qmake + + QtProjectManager.QMakeBuildStep + true + + false + true + true + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Profile + Profile + Qt4ProjectManager.Qt4BuildConfiguration + 0 + true + + 3 + + + 0 + 部署 + + ProjectExplorer.BuildSteps.Deploy + + 1 + Deploy Configuration + + ProjectExplorer.DefaultDeployConfiguration + + 1 + + + false + false + 1000 + + true + + false + false + false + false + true + 0.01 + 10 + true + 1 + 25 + + 1 + true + false + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + + 2 + + Radar + + Qt4ProjectManager.Qt4RunConfiguration:/home/cmy/Projects/Radar/Radar.pro + true + + Radar.pro + + 3768 false true @@ -326,7 +589,7 @@ ProjectExplorer.Project.TargetCount - 1 + 2 ProjectExplorer.Project.Updater.FileVersion diff --git a/Radar.pro.user.022bc4f b/Radar.pro.user.022bc4f new file mode 100644 index 0000000..f2863cb --- /dev/null +++ b/Radar.pro.user.022bc4f @@ -0,0 +1,339 @@ + + + + + + EnvironmentId + {022bc4f8-bda1-4795-81ea-8a5cd54ff33c} + + + ProjectExplorer.Project.ActiveTarget + 0 + + + ProjectExplorer.Project.EditorSettings + + true + false + true + + Cpp + + CppGlobal + + + + QmlJS + + QmlJSGlobal + + + 2 + UTF-8 + false + 4 + false + 80 + true + true + 1 + true + false + 0 + true + true + 0 + 8 + true + 1 + true + true + true + false + + + + ProjectExplorer.Project.PluginSettings + + + true + + + + ProjectExplorer.Project.Target.0 + + Desktop Qt 5.11.1 GCC 64bit + Desktop Qt 5.11.1 GCC 64bit + qt.qt5.5111.gcc_64_kit + 0 + 0 + 0 + + /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Debug + + + true + qmake + + QtProjectManager.QMakeBuildStep + true + + false + false + false + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Debug + + Qt4ProjectManager.Qt4BuildConfiguration + 2 + true + + + /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Release + + + true + qmake + + QtProjectManager.QMakeBuildStep + false + + false + false + false + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release + + Qt4ProjectManager.Qt4BuildConfiguration + 0 + true + + + /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Profile + + + true + qmake + + QtProjectManager.QMakeBuildStep + true + + false + true + false + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + false + + + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + Make + + Qt4ProjectManager.MakeStep + + -w + -r + + true + clean + + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Profile + + Qt4ProjectManager.Qt4BuildConfiguration + 0 + true + + 3 + + + 0 + Deploy + + ProjectExplorer.BuildSteps.Deploy + + 1 + Deploy locally + + ProjectExplorer.DefaultDeployConfiguration + + 1 + + + false + false + 1000 + + true + + false + false + false + false + true + 0.01 + 10 + true + 1 + 25 + + 1 + true + false + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + + 2 + + Radar + + Qt4ProjectManager.Qt4RunConfiguration:/home/wmj/Arduino/Radar/Radar.pro + true + + Radar.pro + false + + /home/wmj/Arduino/build-Radar-Desktop_Qt_5_11_1_GCC_64bit-Debug + 3768 + false + true + false + false + true + + 1 + + + + ProjectExplorer.Project.TargetCount + 1 + + + ProjectExplorer.Project.Updater.FileVersion + 18 + + + Version + 18 + + diff --git a/radar.cpp b/radar.cpp index 740bda0..f088a7e 100644 --- a/radar.cpp +++ b/radar.cpp @@ -23,9 +23,6 @@ Radar::Radar(QWidget *parent) : QWidget(parent) baseRadius = 500; -// serial = new SerialController; -// serial->moveToThread(&SerialThr); -// SerialThr.start(); connect(&scanTimer,&QTimer::timeout, this, [this](){ currentAngle++; this->update(); @@ -73,6 +70,7 @@ void Radar::paintEvent(QPaintEvent *) { double angle = i; double dis = distances[i]; +// qDebug()<readAll(); QString str = data; - double a, d; + int a, d; try { + qDebug()<