chenyuanjie лет назад: 2
Родитель
Сommit
aa22f5e01d

+ 24 - 0
Qt/Qt_Test/.qmake.stash

@@ -0,0 +1,24 @@
+QMAKE_CXX.QT_COMPILER_STDCXX = 201402L
+QMAKE_CXX.QMAKE_GCC_MAJOR_VERSION = 7
+QMAKE_CXX.QMAKE_GCC_MINOR_VERSION = 3
+QMAKE_CXX.QMAKE_GCC_PATCH_VERSION = 1
+QMAKE_CXX.COMPILER_MACROS = \
+    QT_COMPILER_STDCXX \
+    QMAKE_GCC_MAJOR_VERSION \
+    QMAKE_GCC_MINOR_VERSION \
+    QMAKE_GCC_PATCH_VERSION
+QMAKE_CXX.INCDIRS = \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/arm-linux-gnueabi/include/c++/7.3.1 \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/arm-linux-gnueabi/include/c++/7.3.1/arm-linux-gnueabi \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/arm-linux-gnueabi/include/c++/7.3.1/backward \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/lib/gcc/arm-linux-gnueabi/7.3.1/include \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/lib/gcc/arm-linux-gnueabi/7.3.1/include-fixed \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/arm-linux-gnueabi/include \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/arm-buildroot-linux-gnueabi/sysroot/usr/include
+QMAKE_CXX.LIBDIRS = \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/lib/gcc/arm-linux-gnueabi/7.3.1 \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/lib/gcc/arm-linux-gnueabi \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/lib/gcc \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/opt/ext-toolchain/arm-linux-gnueabi/lib \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/arm-buildroot-linux-gnueabi/sysroot/lib \
+    /home/tronlong/T113/T113-i_v1.0/out/t113_i/tlt113-evm-emmc/longan/buildroot/host/arm-buildroot-linux-gnueabi/sysroot/usr/lib

Разница между файлами не показана из-за своего большого размера
+ 2482 - 0
Qt/Qt_Test/Makefile


BIN
Qt/Qt_Test/Qt_Test


+ 50 - 0
Qt/Qt_Test/Qt_Test.pro

@@ -0,0 +1,50 @@
+#-------------------------------------------------
+#
+# Project created by QtCreator 2024-04-12T21:54:14
+#
+#-------------------------------------------------
+
+QT       += core gui network sql
+
+greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
+
+TARGET = Qt_Test
+TEMPLATE = app
+
+# The following define makes your compiler emit warnings if you use
+# any feature of Qt which has been marked as deprecated (the exact warnings
+# depend on your compiler). Please consult the documentation of the
+# deprecated API in order to know how to port your code away from it.
+DEFINES += QT_DEPRECATED_WARNINGS
+
+# You can also make your code fail to compile if you use deprecated APIs.
+# In order to do so, uncomment the following line.
+# You can also select to disable deprecated APIs only up to a certain version of Qt.
+#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0
+
+
+SOURCES += \
+        main.cpp \
+    pdu_ctrl.cpp \
+        widget.cpp \
+    volviewform.cpp \
+    udphelper.cpp \
+    dataupdatethread.cpp \
+    buttonclickthread.cpp
+
+HEADERS += \
+    pdu_ctrl.h \
+        widget.h \
+    volviewform.h \
+    udphelper.h \
+    dataupdatethread.h \
+    buttonclickthread.h
+
+FORMS += \
+    volviewform.ui \
+    widget.ui
+
+target.path = /root/web_temp
+INSTALLS += target
+
+LIBS += -lrt

+ 362 - 0
Qt/Qt_Test/Qt_Test.pro.user

@@ -0,0 +1,362 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE QtCreatorProject>
+<!-- Written by QtCreator 4.5.2, 2024-08-29T12:00:12. -->
+<qtcreator>
+ <data>
+  <variable>EnvironmentId</variable>
+  <value type="QByteArray">{3bdf3ea4-d0d2-4897-8224-daaa02f7bea3}</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.ActiveTarget</variable>
+  <value type="int">0</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.EditorSettings</variable>
+  <valuemap type="QVariantMap">
+   <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
+   <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
+   <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
+    <value type="QString" key="language">Cpp</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
+    </valuemap>
+   </valuemap>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
+    <value type="QString" key="language">QmlJS</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
+    </valuemap>
+   </valuemap>
+   <value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
+   <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
+   <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
+   <value type="int" key="EditorConfiguration.IndentSize">4</value>
+   <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
+   <value type="int" key="EditorConfiguration.MarginColumn">80</value>
+   <value type="bool" key="EditorConfiguration.MouseHiding">true</value>
+   <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
+   <value type="int" key="EditorConfiguration.PaddingMode">1</value>
+   <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
+   <value type="bool" key="EditorConfiguration.ShowMargin">false</value>
+   <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
+   <value type="bool" key="EditorConfiguration.SmartSelectionChanging">true</value>
+   <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
+   <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
+   <value type="int" key="EditorConfiguration.TabSize">8</value>
+   <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
+   <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
+   <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
+   <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
+   <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
+   <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.PluginSettings</variable>
+  <valuemap type="QVariantMap"/>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.0</variable>
+  <valuemap type="QVariantMap">
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">T113</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">T113</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{53055201-e8b9-4b93-a88f-c8dd2f1ab176}</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/Desktop/qt/Qt_Test</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Debug</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/Desktop/qt/Qt_Test</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">false</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Release</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/build-Qt_Test-T113-Profile</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">true</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Profile</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Check for free disk space</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.CheckForFreeDiskSpaceStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedTimes"/>
+      <value type="QString" key="RemoteLinux.CheckForFreeDiskSpaceStep.PathToCheck">/</value>
+      <value type="qulonglong" key="RemoteLinux.CheckForFreeDiskSpaceStep.RequiredSpace">5242880</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Upload files via SFTP</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.DirectUploadStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedTimes"/>
+      <value type="bool" key="RemoteLinux.GenericDirectUploadStep.IgnoreMissingFiles">false</value>
+      <value type="bool" key="RemoteLinux.GenericDirectUploadStep.Incremental">true</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy to Remote Linux Host</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">DeployToGenericLinux</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
+    <value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
+    <value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
+    <value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
+    <value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
+    <value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
+    <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
+    <value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
+    <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
+    <value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
+    <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
+    <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
+    <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
+     <value type="int">0</value>
+     <value type="int">1</value>
+     <value type="int">2</value>
+     <value type="int">3</value>
+     <value type="int">4</value>
+     <value type="int">5</value>
+     <value type="int">6</value>
+     <value type="int">7</value>
+     <value type="int">8</value>
+     <value type="int">9</value>
+     <value type="int">10</value>
+     <value type="int">11</value>
+     <value type="int">12</value>
+     <value type="int">13</value>
+     <value type="int">14</value>
+    </valuelist>
+    <value type="int" key="PE.EnvironmentAspect.Base">1</value>
+    <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Qt_Test (on Remote Device)</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinuxRunConfiguration:Qt_Test</value>
+    <value type="QString" key="Qt4ProjectManager.MaemoRunConfiguration.Arguments"></value>
+    <value type="QString" key="Qt4ProjectManager.MaemoRunConfiguration.TargetName">Qt_Test</value>
+    <value type="int" key="RemoteLinux.EnvironmentAspect.Version">1</value>
+    <value type="QString" key="RemoteLinux.RunConfig.AlternateRemoteExecutable"></value>
+    <value type="bool" key="RemoteLinux.RunConfig.UseAlternateRemoteExecutable">false</value>
+    <value type="QString" key="RemoteLinux.RunConfig.WorkingDirectory"></value>
+    <value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
+    <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.TargetCount</variable>
+  <value type="int">1</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
+  <value type="int">18</value>
+ </data>
+ <data>
+  <variable>Version</variable>
+  <value type="int">18</value>
+ </data>
+</qtcreator>

+ 619 - 0
Qt/Qt_Test/Qt_Test.pro.user.121e105.22

@@ -0,0 +1,619 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE QtCreatorProject>
+<!-- Written by QtCreator 4.12.2, 2024-06-18T15:26:25. -->
+<qtcreator>
+ <data>
+  <variable>EnvironmentId</variable>
+  <value type="QByteArray">{121e1058-5f3e-4863-93b5-ed9ce6b2f524}</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.ActiveTarget</variable>
+  <value type="int">0</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.EditorSettings</variable>
+  <valuemap type="QVariantMap">
+   <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
+   <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
+   <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
+    <value type="QString" key="language">Cpp</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
+    </valuemap>
+   </valuemap>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
+    <value type="QString" key="language">QmlJS</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
+    </valuemap>
+   </valuemap>
+   <value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
+   <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
+   <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
+   <value type="int" key="EditorConfiguration.IndentSize">4</value>
+   <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
+   <value type="int" key="EditorConfiguration.MarginColumn">80</value>
+   <value type="bool" key="EditorConfiguration.MouseHiding">true</value>
+   <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
+   <value type="int" key="EditorConfiguration.PaddingMode">1</value>
+   <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
+   <value type="bool" key="EditorConfiguration.ShowMargin">false</value>
+   <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
+   <value type="bool" key="EditorConfiguration.SmartSelectionChanging">true</value>
+   <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
+   <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
+   <value type="int" key="EditorConfiguration.TabSize">8</value>
+   <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
+   <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
+   <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
+   <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
+   <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
+   <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.PluginSettings</variable>
+  <valuemap type="QVariantMap">
+   <valuelist type="QVariantList" key="ClangCodeModel.CustomCommandLineKey"/>
+   <value type="bool" key="ClangCodeModel.UseGlobalConfig">true</value>
+   <value type="QString" key="ClangCodeModel.WarningConfigId">Builtin.Questionable</value>
+   <valuemap type="QVariantMap" key="ClangTools">
+    <value type="bool" key="ClangTools.BuildBeforeAnalysis">true</value>
+    <value type="QString" key="ClangTools.DiagnosticConfig">Builtin.DefaultTidyAndClazy</value>
+    <value type="int" key="ClangTools.ParallelJobs">8</value>
+    <valuelist type="QVariantList" key="ClangTools.SelectedDirs"/>
+    <valuelist type="QVariantList" key="ClangTools.SelectedFiles"/>
+    <valuelist type="QVariantList" key="ClangTools.SuppressedDiagnostics"/>
+    <value type="bool" key="ClangTools.UseGlobalSettings">true</value>
+   </valuemap>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.0</variable>
+  <valuemap type="QVariantMap">
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">TINA_QT5.12.9</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">TINA_QT5.12.9</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{03cd55e0-a7b6-46da-a668-17354f3bdbdf}</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/Qt_Test/Output</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/Qt_Test/Output</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
+    <value type="int" key="QtQuickCompiler">2</value>
+    <value type="int" key="SeparateDebugInfo">2</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">2</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/build-Qt_Test-TINA_QT5_12_9-Release</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/build-Qt_Test-TINA_QT5_12_9-Release</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+    <value type="int" key="SeparateDebugInfo">2</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/build-Qt_Test-TINA_QT5_12_9-Profile</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/build-Qt_Test-TINA_QT5_12_9-Profile</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Profile</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+    <value type="int" key="SeparateDebugInfo">0</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.CheckForFreeDiskSpaceStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <value type="QString" key="RemoteLinux.CheckForFreeDiskSpaceStep.PathToCheck">/</value>
+      <value type="qlonglong" key="RemoteLinux.CheckForFreeDiskSpaceStep.RequiredSpace">5242880</value>
+      <valuelist type="QVariantList" key="RemoteLinux.LastDeployedLocalTimes"/>
+      <valuelist type="QVariantList" key="RemoteLinux.LastDeployedRemoteTimes"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.KillAppStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <valuelist type="QVariantList" key="RemoteLinux.LastDeployedLocalTimes"/>
+      <valuelist type="QVariantList" key="RemoteLinux.LastDeployedRemoteTimes"/>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.DeployConfiguration.CustomData"/>
+    <value type="bool" key="ProjectExplorer.DeployConfiguration.CustomDataEnabled">false</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">DeployToGenericLinux</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
+    <value type="QString" key="Analyzer.Perf.CallgraphMode">dwarf</value>
+    <valuelist type="QVariantList" key="Analyzer.Perf.Events">
+     <value type="QString">cpu-cycles</value>
+    </valuelist>
+    <valuelist type="QVariantList" key="Analyzer.Perf.ExtraArguments"/>
+    <value type="int" key="Analyzer.Perf.Frequency">250</value>
+    <valuelist type="QVariantList" key="Analyzer.Perf.RecordArguments">
+     <value type="QString">-e</value>
+     <value type="QString">cpu-cycles</value>
+     <value type="QString">--call-graph</value>
+     <value type="QString">dwarf,4096</value>
+     <value type="QString">-F</value>
+     <value type="QString">250</value>
+    </valuelist>
+    <value type="QString" key="Analyzer.Perf.SampleMode">-F</value>
+    <value type="bool" key="Analyzer.Perf.Settings.UseGlobalSettings">true</value>
+    <value type="int" key="Analyzer.Perf.StackSize">4096</value>
+    <value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
+    <value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
+    <value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
+    <value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
+    <value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
+    <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
+    <value type="QString" key="Analyzer.Valgrind.KCachegrindExecutable">kcachegrind</value>
+    <value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
+    <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
+    <value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
+    <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
+    <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
+    <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
+     <value type="int">0</value>
+     <value type="int">1</value>
+     <value type="int">2</value>
+     <value type="int">3</value>
+     <value type="int">4</value>
+     <value type="int">5</value>
+     <value type="int">6</value>
+     <value type="int">7</value>
+     <value type="int">8</value>
+     <value type="int">9</value>
+     <value type="int">10</value>
+     <value type="int">11</value>
+     <value type="int">12</value>
+     <value type="int">13</value>
+     <value type="int">14</value>
+    </valuelist>
+    <value type="int" key="PE.EnvironmentAspect.Base">1</value>
+    <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Qt_Test</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinuxRunConfiguration:/home/liyi/Desktop/qt/Qt_Test/Qt_Test.pro</value>
+    <value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey">/home/liyi/Desktop/qt/Qt_Test/Qt_Test.pro</value>
+    <value type="int" key="RemoteLinux.EnvironmentAspect.Version">1</value>
+    <value type="QString" key="RemoteLinux.RunConfig.AlternateRemoteExecutable"></value>
+    <value type="bool" key="RemoteLinux.RunConfig.UseAlternateRemoteExecutable">false</value>
+    <value type="QString" key="RunConfiguration.Arguments"></value>
+    <value type="bool" key="RunConfiguration.Arguments.multi">false</value>
+    <value type="QString" key="RunConfiguration.OverrideDebuggerStartup"></value>
+    <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseX11Forwarding">false</value>
+    <value type="QString" key="RunConfiguration.WorkingDirectory"></value>
+    <value type="QString" key="RunConfiguration.WorkingDirectory.default"></value>
+    <value type="QString" key="RunConfiguration.X11Forwarding">:0</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.1</variable>
+  <valuemap type="QVariantMap">
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop Qt 5.12.9 GCC 64bit</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop Qt 5.12.9 GCC 64bit</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">qt.qt5.5129.gcc_64_kit</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Debug</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Debug</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Debug</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
+    <value type="int" key="QtQuickCompiler">2</value>
+    <value type="int" key="SeparateDebugInfo">2</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">2</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Release</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Release</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Release</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+    <value type="int" key="SeparateDebugInfo">2</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
+    <value type="bool">true</value>
+    <value type="int" key="EnableQmlDebugging">0</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Profile</value>
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory.shadowDir">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Profile</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <valuelist type="QVariantList" key="QtProjectManager.QMakeBuildStep.SelectedAbis"/>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.BuildTargets"/>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.OverrideMakeflags">false</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Profile</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="int" key="QtQuickCompiler">0</value>
+    <value type="int" key="SeparateDebugInfo">0</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.DeployConfiguration.CustomData"/>
+    <value type="bool" key="ProjectExplorer.DeployConfiguration.CustomDataEnabled">false</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
+    <value type="QString" key="Analyzer.Perf.CallgraphMode">dwarf</value>
+    <valuelist type="QVariantList" key="Analyzer.Perf.Events">
+     <value type="QString">cpu-cycles</value>
+    </valuelist>
+    <valuelist type="QVariantList" key="Analyzer.Perf.ExtraArguments"/>
+    <value type="int" key="Analyzer.Perf.Frequency">250</value>
+    <valuelist type="QVariantList" key="Analyzer.Perf.RecordArguments">
+     <value type="QString">-e</value>
+     <value type="QString">cpu-cycles</value>
+     <value type="QString">--call-graph</value>
+     <value type="QString">dwarf,4096</value>
+     <value type="QString">-F</value>
+     <value type="QString">250</value>
+    </valuelist>
+    <value type="QString" key="Analyzer.Perf.SampleMode">-F</value>
+    <value type="bool" key="Analyzer.Perf.Settings.UseGlobalSettings">true</value>
+    <value type="int" key="Analyzer.Perf.StackSize">4096</value>
+    <value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
+    <value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
+    <value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
+    <value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
+    <value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
+    <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
+    <value type="QString" key="Analyzer.Valgrind.KCachegrindExecutable">kcachegrind</value>
+    <value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
+    <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
+    <value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
+    <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
+    <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
+    <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
+     <value type="int">0</value>
+     <value type="int">1</value>
+     <value type="int">2</value>
+     <value type="int">3</value>
+     <value type="int">4</value>
+     <value type="int">5</value>
+     <value type="int">6</value>
+     <value type="int">7</value>
+     <value type="int">8</value>
+     <value type="int">9</value>
+     <value type="int">10</value>
+     <value type="int">11</value>
+     <value type="int">12</value>
+     <value type="int">13</value>
+     <value type="int">14</value>
+    </valuelist>
+    <value type="int" key="PE.EnvironmentAspect.Base">2</value>
+    <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:/home/liyi/Desktop/qt/Qt_Test/Qt_Test.pro</value>
+    <value type="QString" key="ProjectExplorer.RunConfiguration.BuildKey">/home/liyi/Desktop/qt/Qt_Test/Qt_Test.pro</value>
+    <value type="QString" key="RunConfiguration.Arguments"></value>
+    <value type="bool" key="RunConfiguration.Arguments.multi">false</value>
+    <value type="QString" key="RunConfiguration.OverrideDebuggerStartup"></value>
+    <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseLibrarySearchPath">true</value>
+    <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
+    <value type="QString" key="RunConfiguration.WorkingDirectory"></value>
+    <value type="QString" key="RunConfiguration.WorkingDirectory.default">/home/liyi/Desktop/qt/build-Qt_Test-Desktop_Qt_5_12_9_GCC_64bit-Debug</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.TargetCount</variable>
+  <value type="int">2</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
+  <value type="int">22</value>
+ </data>
+ <data>
+  <variable>Version</variable>
+  <value type="int">22</value>
+ </data>
+</qtcreator>

+ 362 - 0
Qt/Qt_Test/Qt_Test.pro.user.3bdf3ea.4.8-pre1

@@ -0,0 +1,362 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE QtCreatorProject>
+<!-- Written by QtCreator 4.5.2, 2024-05-23T20:17:01. -->
+<qtcreator>
+ <data>
+  <variable>EnvironmentId</variable>
+  <value type="QByteArray">{3bdf3ea4-d0d2-4897-8224-daaa02f7bea3}</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.ActiveTarget</variable>
+  <value type="int">0</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.EditorSettings</variable>
+  <valuemap type="QVariantMap">
+   <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
+   <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
+   <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
+    <value type="QString" key="language">Cpp</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
+    </valuemap>
+   </valuemap>
+   <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
+    <value type="QString" key="language">QmlJS</value>
+    <valuemap type="QVariantMap" key="value">
+     <value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
+    </valuemap>
+   </valuemap>
+   <value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
+   <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
+   <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
+   <value type="int" key="EditorConfiguration.IndentSize">4</value>
+   <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
+   <value type="int" key="EditorConfiguration.MarginColumn">80</value>
+   <value type="bool" key="EditorConfiguration.MouseHiding">true</value>
+   <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
+   <value type="int" key="EditorConfiguration.PaddingMode">1</value>
+   <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
+   <value type="bool" key="EditorConfiguration.ShowMargin">false</value>
+   <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
+   <value type="bool" key="EditorConfiguration.SmartSelectionChanging">true</value>
+   <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
+   <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
+   <value type="int" key="EditorConfiguration.TabSize">8</value>
+   <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
+   <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
+   <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
+   <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
+   <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
+   <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.PluginSettings</variable>
+  <valuemap type="QVariantMap"/>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.0</variable>
+  <valuemap type="QVariantMap">
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">T113</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">T113</value>
+   <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{53055201-e8b9-4b93-a88f-c8dd2f1ab176}</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">1</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
+   <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/build-Qt_Test-T113-Debug</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Debug</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">2</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.1">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/Desktop/qt/Qt_Test</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">false</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Release</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.2">
+    <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/tronlong/build-Qt_Test-T113-Profile</value>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">true</value>
+      <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.SeparateDebugInfo">true</value>
+      <value type="bool" key="QtProjectManager.QMakeBuildStep.UseQtQuickCompiler">false</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
+    </valuemap>
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
+      <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
+       <value type="QString">-w</value>
+       <value type="QString">-r</value>
+      </valuelist>
+      <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
+      <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
+    <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
+    <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Profile</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
+    <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">3</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
+    <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Check for free disk space</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.CheckForFreeDiskSpaceStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedTimes"/>
+      <value type="QString" key="RemoteLinux.CheckForFreeDiskSpaceStep.PathToCheck">/</value>
+      <value type="qulonglong" key="RemoteLinux.CheckForFreeDiskSpaceStep.RequiredSpace">5242880</value>
+     </valuemap>
+     <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
+      <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Upload files via SFTP</value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+      <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinux.DirectUploadStep</value>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedFiles"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedHosts"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedRemotePaths"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedSysroots"/>
+      <valuelist type="QVariantList" key="ProjectExplorer.RunConfiguration.LastDeployedTimes"/>
+      <value type="bool" key="RemoteLinux.GenericDirectUploadStep.IgnoreMissingFiles">false</value>
+      <value type="bool" key="RemoteLinux.GenericDirectUploadStep.Incremental">true</value>
+     </valuemap>
+     <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+     <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
+    </valuemap>
+    <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy to Remote Linux Host</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">DeployToGenericLinux</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
+   <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
+    <value type="bool" key="Analyzer.QmlProfiler.AggregateTraces">false</value>
+    <value type="bool" key="Analyzer.QmlProfiler.FlushEnabled">false</value>
+    <value type="uint" key="Analyzer.QmlProfiler.FlushInterval">1000</value>
+    <value type="QString" key="Analyzer.QmlProfiler.LastTraceFile"></value>
+    <value type="bool" key="Analyzer.QmlProfiler.Settings.UseGlobalSettings">true</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
+    <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
+    <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
+    <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
+    <value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
+    <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
+    <value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
+    <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
+    <value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
+    <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
+    <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
+    <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
+     <value type="int">0</value>
+     <value type="int">1</value>
+     <value type="int">2</value>
+     <value type="int">3</value>
+     <value type="int">4</value>
+     <value type="int">5</value>
+     <value type="int">6</value>
+     <value type="int">7</value>
+     <value type="int">8</value>
+     <value type="int">9</value>
+     <value type="int">10</value>
+     <value type="int">11</value>
+     <value type="int">12</value>
+     <value type="int">13</value>
+     <value type="int">14</value>
+    </valuelist>
+    <value type="int" key="PE.EnvironmentAspect.Base">1</value>
+    <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Qt_Test (on Remote Device)</value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
+    <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">RemoteLinuxRunConfiguration:Qt_Test</value>
+    <value type="QString" key="Qt4ProjectManager.MaemoRunConfiguration.Arguments"></value>
+    <value type="QString" key="Qt4ProjectManager.MaemoRunConfiguration.TargetName">Qt_Test</value>
+    <value type="int" key="RemoteLinux.EnvironmentAspect.Version">1</value>
+    <value type="QString" key="RemoteLinux.RunConfig.AlternateRemoteExecutable"></value>
+    <value type="bool" key="RemoteLinux.RunConfig.UseAlternateRemoteExecutable">false</value>
+    <value type="QString" key="RemoteLinux.RunConfig.WorkingDirectory"></value>
+    <value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
+    <value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
+    <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
+    <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
+   </valuemap>
+   <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.TargetCount</variable>
+  <value type="int">1</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
+  <value type="int">18</value>
+ </data>
+ <data>
+  <variable>Version</variable>
+  <value type="int">18</value>
+ </data>
+</qtcreator>

+ 215 - 0
Qt/Qt_Test/buttonclickthread.cpp

@@ -0,0 +1,215 @@
+#include "buttonclickthread.h"
+#include <unistd.h>
+#include <linux/input.h>
+#include "pdu_ctrl.h"
+typedef enum { KEY_CODE_NONE = 0, KEY_CODE_USER0, KEY_CODE_USER1 } KeyCode;
+ButtonClickThread::ButtonClickThread(QObject *parent)
+    :QThread(parent)
+{
+    isRunning=true;
+
+    nButtonSave[0]=0;nButtonSave[1]=0;nButtonSave[2]=0;nButtonSave[3]=0;nButtonSave[4]=0;
+    bButtonSend[0]=0;bButtonSend[1]=0;bButtonSend[2]=0;
+    nButtonTime[0]=0;nButtonTime[1]=0;nButtonTime[2]=0;
+    qDebug()<<"bButtonSend"<<bButtonSend[0]<<bButtonSend[1]<<bButtonSend[2];
+    qDebug()<<"nButtonTime"<<nButtonTime[0]<<nButtonTime[1]<<nButtonTime[2];
+    pTimeAngle=QTime::currentTime();
+}
+
+ButtonClickThread::~ButtonClickThread()
+{
+    isRunning=false;
+}
+
+void ButtonClickThread::InitConnect()
+{
+   bool ret=connect(this,SIGNAL(signal_ButtonClick(int)),pdu_Ctrl::instance(),SLOT(slot_ClickBtn(int)));
+   qDebug()<<"slot_ClickBtn ="<<ret;
+   ret= connect(this,SIGNAL(signal_ButtonDoubleClick(int)),pdu_Ctrl::instance(),SLOT(slot_DClickBtn(int)));
+   qDebug()<<"slot_DClickBtn ="<<ret;
+   ret= connect(this,SIGNAL(signal_ButtonLongPressed(int)),pdu_Ctrl::instance(),SLOT(slot_LClickBtn(int)));
+   qDebug()<<"slot_LClickBtn ="<<ret;
+   ret= connect(this,SIGNAL(signal_ButtonClear(int)),pdu_Ctrl::instance(),SLOT(slot_BtnClear(int)));
+   qDebug()<<"slot_BtnClear ="<<ret;
+   ret= connect(this,SIGNAL(signal_AngleSet(int)),pdu_Ctrl::instance(),SLOT(slot_setAngel(int)));
+   qDebug()<<"slot_setAngel ="<<ret;
+}
+
+void ButtonClickThread::run()
+{
+    qDebug() <<"Start BtnThread";
+    while (isRunning) {
+        checkBtnStatus(GPIO_KEY1);
+        checkBtnStatus(GPIO_KEY2);
+        checkBtnStatus(GPIO_KEY3);
+        checkBtnStatus(GPIO_KEY4);
+#ifdef hightSmartPDU
+        checkBtnStatus(GPIO_X);
+        checkBtnStatus(GPIO_Y);
+#endif
+        if(!nButtonSave[1]&&!nButtonSave[2]&&!nButtonSave[0])
+        {
+            msleep(2000);
+        }else
+        {
+            //qDebug()<<"SaveDAta"<<nButtonSave[1]<<nButtonSave[2]<<nButtonSave[3];
+            for(int i=0;i<5;i++)
+            {
+               ButtonDownTime(i,nButtonSave[i]);
+            }
+        }
+        msleep(100);
+    }
+}
+
+
+void ButtonClickThread::checkBtnStatus(int KeyID)
+{
+    QString gpioPath=QString("/sys/class/gpio/gpio%1/value").arg(KeyID);
+    QFile file(gpioPath);
+    if (file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+        QTextStream in(&file);
+        QString value = in.readLine();
+        switch (KeyID) {
+        case GPIO_KEY1:
+            nButtonSave[0]=value.toInt();
+            break;
+        case GPIO_KEY2:
+            nButtonSave[1]=value.toInt();
+            break;
+        case GPIO_KEY3:
+            nButtonSave[2]=value.toInt();
+            break;
+    #ifdef hightSmartPDU
+        case GPIO_X:
+            nButtonSave[3]=value.toInt();
+            break;
+        case GPIO_Y:
+            nButtonSave[4]=value.toInt();
+            break;
+    #endif
+        default:
+            break;
+        }
+        //ButtonDownTime(KeyID,value.toInt());
+        file.close();
+    }
+}
+
+void ButtonClickThread::ButtonDownTime(int KeyID,int nValue)
+{
+    switch (KeyID) {
+    case 0:
+        TimeSet(GPIO_KEY1,0,nValue);
+        break;
+    case 1:
+        TimeSet(GPIO_KEY2,1,nValue);
+        break;
+    case 2:
+        TimeSet(GPIO_KEY3,2,nValue);
+        break;
+#ifdef hightSmartPDU
+    case 3:
+        SaveSataus(nValue,m_nY);
+        break;
+    case 4:
+        SaveSataus(m_nX,nValue);
+        break;
+#endif
+    default:
+        break;
+    }
+}
+
+void ButtonClickThread::TimeSet(int KeyID,int nIndex, int nValue)
+{
+    //qDebug()<<"TimeSetStart:Key"<<KeyID<<"_Time:"<<nButtonTime[nIndex]<<"Send:"<<bButtonSend[nIndex];
+    int* pTime=nButtonTime;
+    //负数记录松开时长正数记录按下时长
+    if(nValue==0)
+    {//按下
+        if(bButtonSend[nIndex])
+        {//已发送不响应
+            pTime[nIndex]=1;
+            bButtonSend[nIndex]=true;
+        }else
+        {
+            if(pTime[nIndex]<0)
+            {//当前已松开此时判断为双击
+                pTime[nIndex]=1;
+                emit signal_ButtonDoubleClick(KeyID);
+                qDebug()<<"bButtonSend"<<bButtonSend[0]<<bButtonSend[1]<<bButtonSend[2];
+                qDebug()<<"nButtonTime"<<nButtonTime[0]<<nButtonTime[1]<<nButtonTime[2];
+                bButtonSend[nIndex]=true;
+            }else
+            {
+                pTime[nIndex]+=1;
+                if(pTime[nIndex]>20)
+                {
+                    //超过3秒判断为长按
+                    emit signal_ButtonLongPressed(KeyID);
+                    qDebug()<<"bButtonSend"<<bButtonSend[0]<<bButtonSend[1]<<bButtonSend[2];
+                    qDebug()<<"nButtonTime"<<nButtonTime[0]<<nButtonTime[1]<<nButtonTime[2];
+                    bButtonSend[nIndex]=true;
+                }
+            }
+        }
+    }else
+    {//松开
+        if(bButtonSend[nIndex])
+        {   //已发送过了松开重置
+            pTime[nIndex]=0;
+            bButtonSend[nIndex]=false;
+            emit signal_ButtonClear(KeyID);
+            qDebug()<<"bButtonSend"<<bButtonSend[0]<<bButtonSend[1]<<bButtonSend[2];
+            qDebug()<<"nButtonTime"<<nButtonTime[0]<<nButtonTime[1]<<nButtonTime[2];
+        }
+        else
+        {
+            if(pTime[nIndex]>0)
+            {//当前已点击此时松开可能为双击
+                pTime[nIndex]=-1;
+            }else if(pTime[nIndex]<-2)
+            {//超过400毫秒未点击则判断无双击此时为单单击
+                pTime[nIndex]=0;
+                emit signal_ButtonClick(KeyID);
+                qDebug()<<"bButtonSend"<<bButtonSend[0]<<bButtonSend[1]<<bButtonSend[2];
+                qDebug()<<"nButtonTime"<<nButtonTime[0]<<nButtonTime[1]<<nButtonTime[2];
+                bButtonSend[nIndex]=true;
+            }else if(pTime[nIndex]<0)
+            {//松开计时
+                pTime[nIndex]-=1;
+
+            }else
+            {
+                pTime[nIndex]=0;
+            }
+        }
+
+    }
+    //qDebug()<<"TimeSetEnd:Key"<<KeyID<<"_Time:"<<nButtonTime[nIndex]<<"Send:"<<bButtonSend[nIndex];
+}
+
+void ButtonClickThread::SaveSataus(int nX, int nY)
+{
+    int nAngle=0;
+    m_nX=nX;
+    m_nY=nY;
+    if(m_nX&&m_nY)nAngle=90;
+    if(m_nX&&!m_nY)nAngle=0;
+    if(!m_nX&&m_nY)nAngle=270;
+    if(!m_nX&&!m_nY)nAngle=180;
+    if(m_nSaveAngle!=nAngle)
+    {
+        QTime pNew=QTime::currentTime();
+        int nSecTo=pTimeAngle.secsTo(pNew);
+        if(nSecTo>=2)
+        {
+            m_nSaveAngle=nAngle;
+            emit signal_AngleSet(m_nSaveAngle);
+            pTimeAngle=pNew;
+        }
+        qDebug()<<"Check Angle:"<<nAngle<<" X="<<m_nX<<" Y="<<m_nY<<"SecTo:"<<nSecTo;
+    }
+
+}

+ 45 - 0
Qt/Qt_Test/buttonclickthread.h

@@ -0,0 +1,45 @@
+#ifndef BUTTONCLICKTHREAD_H
+#define BUTTONCLICKTHREAD_H
+//#define hightSmartPDU
+#define rs485KEY
+#include <QObject>
+#include <QThread>
+#include <QDebug>
+#include <QTime>
+class ButtonClickThread : public QThread
+{
+    Q_OBJECT
+public:
+    ButtonClickThread(QObject *parent);
+    ~ButtonClickThread();
+    void InitConnect();
+
+    void run();
+
+    void checkBtnStatus(int KeyID);
+
+    void ButtonDownTime(int KeyID,int nValue);
+
+    void TimeSet(int KeyID,int Index,int nValue);
+
+    void SaveSataus(int nX,int nY);
+signals:
+    void signal_ButtonClear(int KeyID);
+    void signal_ButtonClick(int KeyID);
+    void signal_ButtonLongPressed(int KeyID);
+    void signal_ButtonDoubleClick(int KeyID);
+    void signal_AngleSet(int nAngle);
+public:
+    bool isRunning;
+    int nButtonSave[5];
+    int nButtonTime[3];
+    int bButtonSend[3];
+
+    int m_nX=1;
+    int m_nY=1;
+    int m_nSaveAngle=0;
+    QTime pTimeAngle;
+    //11 0,01 90,10 180,00 270
+};
+
+#endif // BUTTONCLICKTHREAD_H

+ 291 - 0
Qt/Qt_Test/dataupdatethread.cpp

@@ -0,0 +1,291 @@
+#include "dataupdatethread.h"
+#include <QSqlQuery>
+#include <QSqlError>
+#include <stdio.h>
+#include <stdlib.h>
+#include <fcntl.h>           /* For O_* constants */
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/mman.h>        /* For shm_open, mmap, ftruncate, etc */
+#include <sys/stat.h>        /* For mode constants */
+#include <errno.h>
+#include <unistd.h>
+#include <QtSql>
+DataUpdateThread::DataUpdateThread(QObject *parent)
+    :QThread(parent)
+{
+    isRunStats=true;
+    nMaxCh=0;
+    nReadType=0;
+    m_shmData=0;
+    bTacStatus=false;
+}
+
+DataUpdateThread::~DataUpdateThread()
+{
+    isRunStats=false;
+    m_db.close();
+}
+
+void DataUpdateThread::InitSql()
+{
+    m_db=QSqlDatabase::addDatabase("QSQLITE");
+    m_db.setDatabaseName(strSqliteAddress);
+    qDebug()<<strSqliteAddress;
+    if (m_db.open())
+    {
+        qDebug()<<"SQL Open Success";
+        isDBOpen=true;
+    }else
+    {
+        qDebug()<<"SQL Open Error";
+        isDBOpen=false;
+    }
+    if(isDBOpen)
+    {
+        ReadMaxCh();
+    }
+    nReadType=0;
+}
+
+void DataUpdateThread::run()
+{
+    qDebug() <<"Start SQLThread";
+    while (isRunStats)
+    {
+
+        if(pwidget)
+        {
+            if(nReadType==0)
+            {
+                int nMode=pwidget->getShowModeIndex();
+                int nPage=pwidget->getShowPagIndex();
+                if(nMode==0&&nPage!=0)
+                {
+                    int nSubPag=pwidget->getShowSubIndex();
+                    ReadSqlData(nSubPag);
+                    pwidget->SetV(strV);
+                    pwidget->SetA(strA);
+                    pwidget->SetW(strW);
+                    pwidget->SetF(strF);
+                    pwidget->SetSUM(strS);
+                    pwidget->setCH(nSubPag);
+                    pwidget->update();
+                    //qDebug() <<"V:"<<strV<<";A"<<strA<<";W:"<<strW;
+                }
+                else if(nMode==0&&nPage==0)
+                {
+                    pwidget->UpdateDate();
+                    pwidget->update();
+                }
+            }else
+            {
+                int nMode=pwidget->getShowModeIndex();
+                int nPage=pwidget->getShowPagIndex();
+                ReadShmMaxch();
+                if(nMode==0&&nPage!=0)
+                {
+                    int nSubPag=pwidget->getShowSubIndex();
+                    int nPHIndex=pwidget->getShowPHIndex();
+                    setShmChRead(nSubPag,nPHIndex);
+                    ReadShmData();
+                    pwidget->SetV(strV);
+                    pwidget->SetA(strA);
+                    pwidget->SetW(strW);
+                    pwidget->SetF(strF);
+                    pwidget->SetSUM(strS);
+                    pwidget->SetStatus(strStatus);
+                    pwidget->setCH(nSubPag);
+                    pwidget->SetT(strT);
+                    pwidget->SetH(strH);
+                    pwidget->update();
+                    //qDebug() <<"V:"<<strV<<";A"<<strA<<";W:"<<strW;
+                }
+                else if(nMode==0&&nPage==0)
+                {
+                    pwidget->UpdateDate();
+                    pwidget->update();
+                }
+            }
+        }
+        sleep(1);
+    }
+}
+
+void DataUpdateThread::ReadSqlData(int nCHID)
+{
+    if(!isDBOpen)
+    {
+        return;
+    }
+    QSqlQuery sql_query(m_db);
+    QString strSql=QString("SELECT * FROM Table_PowerInfo WHERE product_id=1 AND product_ch_id=%1 ORDER BY product_Index DESC LIMIT 1").arg(nCHID);
+    //qDebug()<<strSql;
+    if (sql_query.exec(strSql))
+    {
+        while (sql_query.next())
+        {
+            strV = sql_query.value("product_ch_voltage").toString();
+            strA = sql_query.value("product_ch_current").toString();
+            strW = sql_query.value("product_ch_power").toString();
+            strF = sql_query.value("product_ch_power_freq").toString();
+            strS = sql_query.value("product_ch_consumption").toString();
+            //qDebug() <<"V:"<<strV<<";A"<<strA<<";W:"<<strW;
+        }
+    }else
+    {
+        qDebug()<<sql_query.lastError().text();
+    }
+
+}
+
+void DataUpdateThread::ReadMaxCh()
+{
+    if(!isDBOpen)
+    {
+        return;
+    }
+    QSqlQuery sql_query(m_db);
+    QString strSql=QString("SELECT MAX(product_ch_id) as maxCh FROM Table_PowerManage ");
+    //qDebug()<<strSql;
+    if (sql_query.exec(strSql))
+    {
+        while (sql_query.next())
+        {
+            nMaxCh = sql_query.value("maxCh").toInt();
+            if(pwidget)
+            {
+                pwidget->nMAXChildIndex=nMaxCh;
+            }
+        }
+    }else
+    {
+        qDebug()<<sql_query.lastError().text();
+    }
+}
+
+int DataUpdateThread::initShm()
+{
+    /* 创建共享内存对象 */
+    shm_fd = shm_open(SHM_NAME, O_CREAT | O_RDWR, 0666);
+    if (shm_fd == -1) {
+        perror("shm_open");
+        return 1;
+    }
+
+    /* 设置共享内存对象的大小 */
+
+    if (ftruncate(shm_fd, sizeof(smartPDU_shm_data)) == -1) {
+        perror("ftruncate");
+        return 2;
+    }
+    m_shmData = (smartPDU_shm_data*)mmap(NULL, sizeof(smartPDU_shm_data), PROT_READ|PROT_WRITE, MAP_SHARED, shm_fd, 0);
+    memset(m_shmData,0,sizeof(smartPDU_shm_data));
+    m_shmData->nSelectSensor=10;
+    nReadType=1;
+    return 0;
+}
+
+void DataUpdateThread::deleteShm()
+{
+    m_shmData->bPDUSet=-1;
+    if (munmap(m_shmData, sizeof(smartPDU_shm_data)) == -1) {
+        perror("munmap");
+        return;
+    }
+    if (shm_unlink(SHM_NAME) == -1) {
+        perror("shm_unlink");
+        return;
+    }
+    m_shmData=nullptr;
+}
+
+void DataUpdateThread::setShmChRead(int nCh,int nPhID)
+{
+    if(nReadType!=1&&!m_shmData)
+    {
+        return;
+    }
+    if(m_shmData->bPDUSet>0)
+    {
+        if(m_shmData->nSelectPowerCH!=nCh)
+        {
+            m_shmData->nSelectPowerCH=nCh;
+            bTacStatus=m_shmData->bT_ACType;
+            pdu_Ctrl::instance()->isT_ACType=bTacStatus;
+            if(bTacStatus)
+            {
+                m_shmData->nSelectPh=nPhID;
+            }else
+            {
+                m_shmData->nSelectPh=0;
+            }
+            m_shmData->bPDUSet=0;            
+        }
+
+    }
+}
+
+void DataUpdateThread::ReadShmData()
+{
+    if(nReadType!=1&&!m_shmData)
+    {
+        return;
+    }
+    if(m_shmData->bPDUSet>0)
+    {
+        if(m_shmData->fV>=0.1)
+        {
+            strV = QString::number(m_shmData->fV,'f',2);
+        }else
+        {
+            strV = "0.00";
+        }
+
+        if(m_shmData->fA>=0.01)
+        {
+            strA = QString::number(m_shmData->fA,'f',2);
+        }else
+        {
+            strA="0.00";
+        }
+        strW = QString::number(m_shmData->fW,'f',2);
+        strF = QString::number(m_shmData->fF,'f',2);
+        strS = QString::number(m_shmData->fS,'f',2);
+        if(m_shmData->nStatus==0)
+        {
+            strStatus="OFF";
+        }else
+        {
+            strStatus="ON";
+        }
+        strT = QString::number(m_shmData->fT,'f',2);
+        strH = QString::number(m_shmData->fH,'f',2);
+    }
+}
+
+void DataUpdateThread::ReadShmMaxch()
+{
+    if(nReadType!=1&&!m_shmData)
+    {
+        if(pwidget)
+        {
+            pwidget->nMAXChildIndex=0;
+        }
+        return;
+    }
+    if(pwidget&&m_shmData->bPDUSet>0)
+    {
+        if(pwidget->nMAXChildIndex!=m_shmData->nMaxCh)
+        {
+           pwidget->nMAXChildIndex=m_shmData->nMaxCh;
+        }
+    }
+}
+
+bool DataUpdateThread::isT_ACType()
+{
+    return bTacStatus;
+}
+
+

+ 80 - 0
Qt/Qt_Test/dataupdatethread.h

@@ -0,0 +1,80 @@
+#ifndef DATAUPDATETHREAD_H
+#define DATAUPDATETHREAD_H
+
+#include <QObject>
+#include <QThread>
+#include <QtSql>
+#include "widget.h"
+#include <QDebug>
+
+#define SHM_NAME "/smartPDU_shm"
+#include "pdu_ctrl.h"
+struct smartPDU_shm_data
+{
+    //电源数据
+    int bPDUSet;
+    int nSelectPowerCH;
+    int nMaxCh;
+    float fV;
+    float fA;
+    float fW;
+    float fF;
+    float fS;
+    int nStatus;
+    //传感器数据
+    int nSelectSensor;
+    float fT;//温度
+    float fH;//湿度
+    //三项数据
+    bool bT_ACType;//三相类型
+    int nSelectPh;//当前通道的三相ph参数:0:A相 1:B相 2:C相 -1通道总计
+};
+class DataUpdateThread : public QThread
+{
+    Q_OBJECT
+public:
+    DataUpdateThread(QObject *parent);
+    ~DataUpdateThread();
+    void InitSql();
+
+    void run();
+
+    void ReadSqlData(int nCHID=0);
+    void ReadMaxCh();
+
+    //共享内存初始化
+    int initShm();
+    void deleteShm();
+    void setShmChRead(int nCh,int nPhID);
+    void ReadShmData();
+    void ReadShmMaxch();
+    bool isT_ACType();//三相标志
+public:
+    //窗口
+    Widget* pwidget;
+    //sql地址
+    QString strSqliteAddress;
+
+    QSqlDatabase m_db;
+
+    bool isRunStats;
+    bool isDBOpen;
+
+    QString strV;
+    QString strA;
+    QString strW;
+    QString strF;
+    QString strS;
+    QString strT;
+    QString strH;
+    QString strStatus;
+    int nMaxCh;
+
+    int nReadType;
+    int shm_fd;
+
+    bool bTacStatus;
+    smartPDU_shm_data* m_shmData;
+};
+
+#endif // DATAUPDATETHREAD_H

+ 63 - 0
Qt/Qt_Test/main.cpp

@@ -0,0 +1,63 @@
+#include "widget.h"
+#include <QApplication>
+#include "dataupdatethread.h"
+#include "buttonclickthread.h"
+#include <QScreen>
+#include <QGraphicsScene>
+#include <QGraphicsView>
+#include "pdu_ctrl.h"
+int main(int argc, char *argv[])
+{
+    QApplication a(argc, argv);
+    //窗口初始化
+    pdu_Ctrl::instance();
+    Widget w;
+    qDebug()<<"widget End";
+    QGraphicsScene *scene   = new QGraphicsScene;
+    QGraphicsView *gview    = new QGraphicsView(scene);
+    QGraphicsProxyWidget *g_proxy_widget;
+    qDebug()<<"x:"<<w.size().width()<<"y:"<<w.size().height();
+    QScreen *desktop        = QApplication::primaryScreen();
+    QRect screen_info       = desktop->geometry();
+    // Rotation 90 degree
+    g_proxy_widget = scene->addWidget((QWidget*)&w);
+    g_proxy_widget->setRotation(0);
+    // Set window size
+    w.resize(screen_info.width(), screen_info.height());
+    qDebug()<<"Rect:x="<<screen_info.width()<<"y="<<screen_info.height();
+
+    pdu_Ctrl::instance()->InitData(&w,g_proxy_widget,gview,screen_info.width(), screen_info.height());
+    gview->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
+    gview->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
+    gview->setStyleSheet("border:none");
+    gview->showFullScreen();
+
+    qDebug()<<"x:"<<w.size().width()<<"y:"<<w.size().height();
+
+    qDebug()<<"Thread start";
+    QString appDirPath = QCoreApplication::applicationDirPath();
+    pdu_Ctrl::instance()->strSqliteAddress=appDirPath+"/pdu_dat.db";
+    pdu_Ctrl::instance()->ReadModbusInit();
+    //============================线程开启====================================
+    //数据更新线程
+    DataUpdateThread thread_Update(nullptr);
+    thread_Update.pwidget=&w;
+    //QString appDirPath = QCoreApplication::applicationDirPath();
+    //thread_Update.strSqliteAddress=appDirPath+"/pdu_dat.db";
+    thread_Update.initShm();
+    thread_Update.start();
+    //GPIO更新线程
+    ButtonClickThread thread_Button(nullptr);
+    thread_Button.InitConnect();
+    thread_Button.start();
+    //thread_Button.InitConnect();
+
+    int ret=a.exec();
+    //析构
+    thread_Update.isRunStats=false;
+    thread_Update.wait();
+    thread_Button.isRunning=false;
+    thread_Button.wait();
+    pdu_Ctrl::distory();
+    return ret;
+}

+ 505 - 0
Qt/Qt_Test/pdu_ctrl.cpp

@@ -0,0 +1,505 @@
+#include "pdu_ctrl.h"
+#include <QtWidgets/QStackedWidget>
+#include <QSettings>
+#include <QProcess>
+#include <QCoreApplication>
+#include <QSql>
+#include <QSqlDatabase>
+#include <QSqlQuery>
+#include <QSqlError>
+#define READ_INI_STR(key, default_value) (settings.contains(key) ? settings.value(key).toString() : default_value)
+#define READ_INI_INT(key, default_value) (settings.contains(key) ? settings.value(key).toInt() : default_value)
+
+pdu_Ctrl* pdu_Ctrl::m_instance = nullptr;
+QMutex pdu_Ctrl::mutex;
+
+pdu_Ctrl::pdu_Ctrl(QObject *parent) : QObject(parent)
+{
+    m_nModbusSelect=0;
+    m_nModbusAddress=0;//从机地址
+    m_nModbusMSType=1;//主从
+    m_nSaveData=0;
+    nViewShowType=widgetType_Main;
+    nSettingType=0;
+    nChidIndex=0;
+    nChidPHIndex=0;
+    m_nAngle=0;
+    isT_ACType=false;
+    memset(nButtonStatus,0,sizeof(nButtonStatus));
+    //
+}
+
+void pdu_Ctrl::slot_setAngel(int nAngle)
+{
+    if(m_pAngleCtrl&&m_pWidget)
+    {
+        //m_pAngleCtrl->setPos(size().width()/2, size().height()/2);
+        //m_pAngleCtrl->transform(width() / 2, height() / 2);
+        m_pAngleCtrl->setRotation(nAngle);
+        m_nAngle=nAngle;
+        if(nAngle==0||nAngle==180)
+        {
+            m_pWidget->resize(m_nWidth, m_nHeight);
+            if(nAngle==0)
+            {
+                m_pAngleCtrl->setPos(0,0);
+            }else
+            {
+                m_pAngleCtrl->setPos(m_pWidget->size().width(),m_pWidget->size().height());
+            }
+            //QRect pRect=size();
+            qDebug()<<"x:"<<m_pWidget->geometry().x()<<"y:"<<m_pWidget->geometry().y()<<"Width:"<<m_pWidget->size().width()<<"Height:"<<m_pWidget->size().height();
+        }else
+        {
+            m_pWidget->resize(m_nHeight,m_nWidth);
+            if(nAngle==90)
+            {
+                m_pAngleCtrl->setPos(m_nWidth,0);
+
+            }else
+            {
+                m_pAngleCtrl->setPos(0,m_nHeight);
+            }
+            qDebug()<<"x:"<<m_pWidget->geometry().x()<<"y:"<<m_pWidget->geometry().y()<<"Width:"<<m_pWidget->size().width()<<"Height:"<<m_pWidget->size().height();
+        }
+        m_pView->update();
+    }
+}
+
+void pdu_Ctrl::slot_ClickBtn(int nButton)
+{
+    ButtonDown(nButton,BtnDown_C);
+}
+
+void pdu_Ctrl::slot_DClickBtn(int nButton)
+{
+    ButtonDown(nButton,BtnDown_C);
+}
+
+void pdu_Ctrl::slot_LClickBtn(int nButton)
+{
+    ButtonDown(nButton,BtnDown_L);
+}
+
+void pdu_Ctrl::slot_BtnClear(int nButton)
+{
+    ButtonDown(nButton,BtnDown_Null);
+}
+
+void pdu_Ctrl::InitData(Widget *pWidget, QGraphicsProxyWidget *pProxy, QGraphicsView *pView,int nWidth, int nHeight)
+{
+    m_pAngleCtrl=pProxy;
+    m_pView=pView;
+    m_pWidget=pWidget;
+    m_nWidth= nWidth;
+    m_nHeight = nHeight;
+}
+
+void pdu_Ctrl::ReadModbusInit()
+{
+    QSettings settings("./AppConfig.ini",QSettings::IniFormat);
+    m_nModbusAddress=READ_INI_INT("MODBUS/address",0);
+    if(m_nModbusAddress>255||m_nModbusAddress<0)
+    {
+        m_nModbusAddress=0;
+    }
+    m_nModbusMSType=READ_INI_INT("MODBUS/MSType",1);//0:主机,1:从机
+    qDebug()<<"modbus Config m_nModbusMSType="<<m_nModbusMSType<<" m_nModbusAddress="<<m_nModbusAddress;
+    QSqlDatabase m_db;
+    m_db=QSqlDatabase::addDatabase("QSQLITE");
+    m_db.setDatabaseName(strSqliteAddress);
+    qDebug()<<"modbus DB="<<strSqliteAddress;
+    bool isDBOpen=false;
+    if (m_db.open())
+    {
+        qDebug()<<"SQL Open Success";
+        isDBOpen=true;
+    }else
+    {
+        qDebug()<<"SQL Open Error";
+        isDBOpen=false;
+    }
+    if(isDBOpen)
+    {
+        QSqlQuery sql_query(m_db);
+        QString strSql=QString("SELECT *  FROM Table_DeviceInfo where product_id==1;");
+        //qDebug()<<strSql;
+        if (sql_query.exec(strSql))
+        {
+            while (sql_query.next())
+            {
+                m_nModbusAddress = sql_query.value("product_modbus_addr").toInt();
+            }
+        }else
+        {
+            qDebug()<<sql_query.lastError().text();
+        }
+    }
+    m_db.close();
+    qDebug()<<"modbus m_nModbusMSType="<<m_nModbusMSType<<" m_nModbusAddress="<<m_nModbusAddress;
+}
+
+void pdu_Ctrl::SaveModbusInit()
+{
+    QSettings settings("./AppConfig.ini",QSettings::IniFormat);
+    settings.setValue("MODBUS/address",m_nModbusAddress);
+    settings.setValue("MODBUS/MSType",m_nModbusMSType);//0:主机,1:从机
+    QSqlDatabase m_db;
+    m_db=QSqlDatabase::addDatabase("QSQLITE");
+    m_db.setDatabaseName(strSqliteAddress);
+    qDebug()<<strSqliteAddress;
+    bool isDBOpen=false;
+    if (m_db.open())
+    {
+        qDebug()<<"SQL Open Success";
+        isDBOpen=true;
+    }else
+    {
+        qDebug()<<"SQL Open Error";
+        isDBOpen=false;
+    }
+    if(isDBOpen)
+    {
+        QSqlQuery sql_query(m_db);
+        QString strSql=QString("UPDATE Table_DeviceInfo SET product_modbus_addr = %1 WHERE product_id==1").arg(m_nModbusAddress);
+        //qDebug()<<strSql;
+        if (!sql_query.exec(strSql))
+        {
+            qDebug()<<sql_query.lastError().text();
+        }
+    }
+    m_db.close();
+
+
+}
+
+void pdu_Ctrl::Main_UPBtnSet(BtnDownType nbtnType)
+{
+    qDebug()<<"Main_UPBtnSet";
+    if(!m_pWidget)
+    {
+        return;
+    }
+    if(nbtnType==BtnDown_C)
+    {
+        qDebug()<<"pageUp";
+        m_pWidget->pageUp();
+    }
+
+}
+
+void pdu_Ctrl::Main_FunBtnSet(BtnDownType nbtnType)
+{
+    //中间按钮
+    qDebug()<<"Main_FunBtnSet";
+    if (nbtnType==BtnDown_C)
+    {
+        //在通道界面是显示三项通道
+        if(m_pWidget)
+        {
+            int nNowIndex=m_pWidget->getShowPagIndex();
+            qDebug()<<"NowIndex="<<nNowIndex;
+            switch (nNowIndex) {
+            case 2://CH通道界面如果是三项则切换至三项子通道界面
+                {
+                    if(isT_ACType)
+                    {
+                        m_pWidget->setShowPHIndex(1);
+                        ChangeView(widgetType_Main,4);
+                    }
+                }
+                break;
+            case 4://PH通道界面返回CH通道界面
+                {
+                    m_pWidget->setShowPHIndex(0);
+                    ChangeView(widgetType_Main,2);
+                }
+                break;
+            default://其他界面
+                //在显示主界面时是旋转窗口
+                m_nAngle+=90;
+                m_nAngle==360?m_nAngle=0:m_nAngle;
+                qDebug()<<"nAngle:"<<m_nAngle;
+                slot_setAngel(m_nAngle);
+                qDebug()<<"slot_setAngel";
+                break;
+            }
+        }
+
+    }
+    else
+    {
+        qDebug()<<"setSelectStatus";
+        if(m_pWidget)
+        {
+            m_nModbusSelect=0;
+            m_pWidget->CtrlBtnSet(0,m_nModbusAddress);
+            m_pWidget->setSelectStatus(m_nModbusSelect);
+            m_nSaveData=0;
+        }
+        //切换到modbus
+        qDebug()<<"ChangeView";
+        //nViewShowType=widgetType_Setting;
+        ChangeView(widgetType_Setting,0);
+    }
+
+}
+
+void pdu_Ctrl::Main_DownBtnSet(BtnDownType nbtnType)
+{
+    qDebug()<<"Main_DownBtnSet";
+    if(!m_pWidget)
+    {
+        return;
+    }
+    if(nbtnType==BtnDown_C)
+    {
+        m_pWidget->pageDown();
+        qDebug()<<"pageDown";
+    }
+
+}
+
+void pdu_Ctrl::Setting_UPBtnSet(BtnDownType nbtnType)
+{
+    switch (nSettingType) {
+    case settingMode_Modbus:
+    {
+        if(nbtnType==BtnDown_C)
+        {//切换select
+            if(m_pWidget)
+            {
+                switch (m_nModbusSelect) {
+                case 0://address
+                {
+                    m_nModbusAddress+=1;
+                    if(m_nModbusAddress>32)m_nModbusAddress=1;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusAddress);
+                }break;
+                case 1://SAVE
+                {
+                    //保存切换
+                    m_nSaveData==0?m_nSaveData=1:m_nSaveData=0;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nSaveData);
+                }break;
+                case 2://主从
+                {
+                    //主从切换
+                    m_nModbusMSType==0?m_nModbusMSType=1:m_nModbusMSType=0;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusMSType);
+                }break;
+                }
+            }
+        }else if(nbtnType==BtnDown_L)
+        {
+            switch (m_nModbusSelect) {
+            case 0://address
+            {
+                m_nModbusAddress+=5;
+                if(m_nModbusAddress>255)m_nModbusAddress=0;
+                if(m_pWidget)m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusAddress);
+            }break;
+            }
+        }
+    }break;
+    case settingMode_IP:
+    {
+
+    }break;
+    default:
+        break;
+    }
+}
+
+void pdu_Ctrl::Setting_FunBtnSet(BtnDownType nbtnType)
+{
+    switch (nSettingType) {
+    case settingMode_Modbus:
+    {
+        if(nbtnType==BtnDown_C)
+        {//切换select
+            if(m_pWidget)
+            {
+                if(m_nModbusSelect==1&&m_nSaveData==1)//短按 FUN 保存YES回到前台。
+                {
+                    SaveModbusInit();
+                    ChangeView(widgetType_Main,0);
+                }else
+                {
+#ifdef RS485Type
+                    m_nModbusSelect==0?m_nModbusSelect=1:m_nModbusSelect=0;
+#endif
+                    m_pWidget->setSelectStatus(m_nModbusSelect);
+                }
+
+            }
+        }else if(nbtnType==BtnDown_L)
+        {
+            ChangeView(widgetType_Main,0);
+        }
+    }break;
+    case settingMode_IP:
+    {
+
+    }break;
+    default:
+        break;
+    }
+}
+
+void pdu_Ctrl::Setting_DownBtnSet(BtnDownType nbtnType)
+{
+    switch (nSettingType) {
+    case settingMode_Modbus:
+    {
+        if(nbtnType==BtnDown_C)
+        {//切换select
+            if(m_pWidget)
+            {
+                switch (m_nModbusSelect) {
+                case 0://address
+                {
+                    m_nModbusAddress-=1;
+                    if(m_nModbusAddress<1)m_nModbusAddress=32;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusAddress);
+                }break;
+                case 1://SAVE
+                {
+                    //保存切换
+                    m_nSaveData==0?m_nSaveData=1:m_nSaveData=0;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nSaveData);
+                }break;
+                case 2://主从
+                {
+                    //主从切换
+                    m_nModbusMSType==0?m_nModbusMSType=1:m_nModbusMSType=0;
+                    m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusMSType);
+                }break;
+                }
+            }
+        }else if(nbtnType==BtnDown_L)
+        {
+            switch (m_nModbusSelect) {
+            case 0://address
+            {
+                m_nModbusAddress-=5;
+                if(m_nModbusAddress<0)m_nModbusAddress=255;
+                if(m_pWidget)m_pWidget->CtrlBtnSet(m_nModbusSelect,m_nModbusAddress);
+            }break;
+            }
+        }
+    }break;
+    case settingMode_IP:
+    {
+
+    }break;
+    default:
+        break;
+    }
+}
+
+void pdu_Ctrl::ChangeView(WidgetType widgetType, int nIndex)
+{
+    if(!m_pWidget)
+    {
+        return;
+    }
+    if(widgetType!=nViewShowType)
+    {
+        qDebug()<<"Widget->ChangeView";
+        m_pWidget->ChangeView(widgetType,0);
+        nViewShowType=widgetType;
+    }else
+    {
+        m_pWidget->ChangeView(widgetType,nIndex);
+    }
+
+}
+
+void pdu_Ctrl::ResetAll()
+{
+#ifdef RS485IpType
+    system("sh /mnt/UDISK/app/recovery.sh");
+#else
+    system("sh /opt/recovery.sh");
+#endif
+}
+
+void pdu_Ctrl::RestartSys()
+{
+    system("reboot");
+}
+
+void pdu_Ctrl::ButtonDown(int nButtonID, BtnDownType nDownType)
+{
+    //规整按钮状态
+    switch (nButtonID) {
+        case GPIO_KEY1://1按钮
+            nButtonStatus[0]=nDownType;
+            break;
+        case GPIO_KEY2:
+            nButtonStatus[1]=nDownType;
+            break;
+        case GPIO_KEY3://3按钮
+             nButtonStatus[2]=nDownType;
+            break;
+        default:
+            break;
+    }
+    qDebug()<<"Key1="<<GPIO_KEY1<<" Type1="<<nButtonStatus[0];
+    qDebug()<<"Key2="<<GPIO_KEY2<<" Type2="<<nButtonStatus[1];
+    qDebug()<<"Key3="<<GPIO_KEY3<<" Type3="<<nButtonStatus[2];
+    qDebug()<<"widgetType="<<nViewShowType;
+    if(nDownType<0)
+    {
+        return;
+    }
+    //判断多键控制
+    if(nButtonStatus[0]==2&&nButtonStatus[2]==2)
+    {//恢复出厂设置
+        ResetAll();
+        return;
+    }
+    if(nButtonStatus[0]==2&&nButtonStatus[1]==2)
+    {//重新启动
+        RestartSys();
+        return;
+    }
+
+    if(nViewShowType==widgetType_Main)
+    {
+        qDebug()<<"widgetType="<<widgetType_Main;
+        qDebug()<<"nButtonID="<<nButtonID;
+        switch (nButtonID) {
+        case GPIO_KEY1://1按钮
+            Main_UPBtnSet(nDownType);
+            break;
+        case GPIO_KEY2:
+            Main_FunBtnSet(nDownType);
+            break;
+        case GPIO_KEY3://3按钮
+            Main_DownBtnSet(nDownType);
+            break;
+        default:
+            break;
+        }
+
+    }else if(nViewShowType==widgetType_Setting)
+    {
+        qDebug()<<"widgetType="<<widgetType_Setting;
+        qDebug()<<"nButtonID="<<nButtonID;
+        switch (nButtonID) {
+        case GPIO_KEY1://1按钮
+            Setting_UPBtnSet(nDownType);
+            break;
+        case GPIO_KEY2:
+            Setting_FunBtnSet(nDownType);
+            break;
+        case GPIO_KEY3://3按钮
+            Setting_DownBtnSet(nDownType);
+            break;
+        default:
+            break;
+        }
+    }
+}

+ 147 - 0
Qt/Qt_Test/pdu_ctrl.h

@@ -0,0 +1,147 @@
+#ifndef PDU_CTRL_H
+#define PDU_CTRL_H
+
+#include <QObject>
+#include <QMutex>
+#include <QGraphicsProxyWidget>
+#include <QGraphicsView>
+#include "widget.h"
+#define hightSmartPDU
+//#define RS485Type
+//#define RS485IpType
+enum WidgetType
+{
+    widgetType_Main=0,      //轮询页面
+    widgetType_Setting=1,   //设置页面
+};
+enum WidgetMain_T_AC
+{
+    WidgetMain_CH=0,    //三项总
+    WidgetMain_PHA=1,   //A相
+    WidgetMain_PHB=2,   //B相
+    WidgetMain_PHC=3,   //C相
+};
+enum SettingMode
+{
+    settingMode_Modbus=0,
+    settingMode_LimitV=1,
+    settingMode_LimitA=2,
+    settingMode_IP=3,
+};
+enum BtnDownType
+{
+    BtnDown_C=0,//点击
+    BtnDown_D=1,  //双击
+    BtnDown_L=2,   //长按
+    BtnDown_Null=-1//清空
+};
+
+enum GPIOLED
+{
+    GPIO_LED0=106,
+    GPIO_LED1=105,
+#ifdef RS485Type
+    GPIO_KEY1=160,
+    GPIO_KEY2=161,
+    GPIO_KEY3=162,
+    GPIO_KEY4=103,
+#endif
+#ifdef hightSmartPDU
+    GPIO_KEY1=102,
+    GPIO_KEY2=101,
+    GPIO_KEY3=104,
+    GPIO_KEY4=103,
+
+    GPIO_X=113,//方向传感器
+    GPIO_Y=115//方向传感器
+#endif
+};
+class pdu_Ctrl : public QObject
+{
+    Q_OBJECT
+public:
+    //单例初始化
+    static pdu_Ctrl* instance() {
+        QMutexLocker locker(&mutex);
+        if (!m_instance) {
+            static QMutex mutex;
+            if (!m_instance) {
+                m_instance = new pdu_Ctrl();
+            }
+        }
+        return m_instance;
+    }
+    static void distory()
+    {
+        QMutexLocker locker(&mutex);
+        if (m_instance) {
+            delete m_instance;
+            m_instance = nullptr;
+        }
+    }
+
+    void InitData(Widget* pWidget,QGraphicsProxyWidget* pProxy ,QGraphicsView* pView,int nWidth, int nHeight);
+
+    void ReadModbusInit();
+
+    void SaveModbusInit();
+private:
+    //处理多个点
+    void ButtonDown(int nButtonID, BtnDownType nDownType);
+
+    //===================MAIN界面下按钮控制============================
+    void Main_UPBtnSet(BtnDownType nbtnType);
+    void Main_FunBtnSet(BtnDownType nbtnType);
+    void Main_DownBtnSet(BtnDownType nbtnType);
+    //===================SETTING界面下按钮控制=========================
+    void Setting_UPBtnSet(BtnDownType nbtnType);
+    void Setting_FunBtnSet(BtnDownType nbtnType);
+    void Setting_DownBtnSet(BtnDownType nbtnType);
+    //======切换视图=========
+    void ChangeView(WidgetType widgetType,int nIndex);
+
+    //======恢复出厂设置=========
+    void ResetAll();
+    void RestartSys();
+signals:
+
+public slots:
+    void slot_setAngel(int nAngle);
+    void slot_ClickBtn(int nButton);
+    void slot_DClickBtn(int nButton);
+    void slot_LClickBtn(int nButton);
+    void slot_BtnClear(int nButton);
+private:
+    //单例数据
+    explicit pdu_Ctrl(QObject *parent = nullptr);
+    static pdu_Ctrl* m_instance;
+    static QMutex mutex;
+
+    WidgetType nViewShowType;//
+    int nSettingType;//设置页面
+    //记录三个按钮的状态
+    int nButtonStatus[3];//上中下
+    //当前显示页面ID
+    int nChidIndex;
+    int nChidPHIndex;
+    int m_nAngle;
+    //其他界面指针
+    QGraphicsProxyWidget* m_pAngleCtrl;
+    QGraphicsView* m_pView;
+    Widget* m_pWidget;
+    int m_nWidth;
+    int m_nHeight;
+
+
+    //modbus设置
+public:
+    int m_nModbusSelect;
+    int m_nModbusAddress;//从机地址
+    int m_nModbusMSType;//主从
+    int m_nSaveData;
+    QString strSqliteAddress;
+
+    bool isT_ACType;
+};
+
+#endif // PDU_CTRL_H

+ 64 - 0
Qt/Qt_Test/udphelper.cpp

@@ -0,0 +1,64 @@
+#include "udphelper.h"
+
+#define _GET_DEVICE_TYPE_AND_CHANNEL    0x00
+#define _GET_DEVICE_POWER_INFO          0x01
+#define _GLOBAL_REMOTE_PORT    32768
+UdpHelper::UdpHelper(QObject *parent) : QObject(parent)
+{
+    mSocket = new QUdpSocket(this);
+    mSocket->bind(QHostAddress::Any,this->port);
+}
+
+int UdpHelper::getDeviceTypeAndChannel(int *type, int *channel)
+{
+    //bool status = false ;
+    QByteArray dataArray;
+    dataArray.resize(6);
+    dataArray[0] = 0x55;
+    dataArray[1] = 0x00;
+    dataArray[2] = 0x02;
+    dataArray[3] = _GET_DEVICE_TYPE_AND_CHANNEL;
+    dataArray[4] = 0x00 ;
+    dataArray[5] = 0xFF ;
+    mSocket->writeDatagram(dataArray,QHostAddress::Broadcast,_GLOBAL_REMOTE_PORT);
+    if(mSocket->waitForReadyRead(1000)==false)
+        return -1 ;
+    //recv
+    QByteArray arr;
+    arr.resize(mSocket->bytesAvailable());
+    mSocket->readDatagram(arr.data(),arr.size(),&addr,&port);
+
+    *type = (int)arr.at(0);
+    *channel = (arr.at(1)<<8|arr.at(2));
+
+    return 0;
+}
+
+int UdpHelper::getPowerInfo(bool *sts, float *vol, float *cur, float *power, float *factor, float *consum)
+{
+    //bool status = false ;
+    QByteArray dataArray;
+    dataArray.resize(6);
+    dataArray[0] = 0x55;
+    dataArray[1] = 0x00;
+    dataArray[2] = 0x02;
+    dataArray[3] = _GET_DEVICE_POWER_INFO;
+    dataArray[4] = 0x00 ;
+    dataArray[5] = 0xFF ;
+    mSocket->writeDatagram(dataArray,QHostAddress::Broadcast,_GLOBAL_REMOTE_PORT);
+    if(mSocket->waitForReadyRead(1000)==false)
+        return -1 ;
+    QByteArray arr;
+    char* data_buff;
+    arr.resize(mSocket->bytesAvailable());
+    mSocket->readDatagram(arr.data(),arr.size(),&addr,&port);
+    data_buff = arr.data();
+    *sts = data_buff[0];
+    memcpy(vol,data_buff+1,4);
+    memcpy(cur,data_buff+5,4);
+    memcpy(power,data_buff+9,4);
+    memcpy(factor,data_buff+13,4);
+    memcpy(consum,data_buff+17,4);
+    return 0;
+}
+

+ 23 - 0
Qt/Qt_Test/udphelper.h

@@ -0,0 +1,23 @@
+#ifndef UDPHELPER_H
+#define UDPHELPER_H
+
+#include <QObject>
+#include <QtNetwork/QUdpSocket>
+class UdpHelper : public QObject
+{
+    Q_OBJECT
+public:
+    explicit UdpHelper(QObject *parent = nullptr);
+    int getDeviceTypeAndChannel(int* type,int* channel);
+    int getPowerInfo(bool* sts,float* vol,float* cur,float* power,float* factor,float* consum);
+signals:
+
+public slots:
+
+private:
+    QUdpSocket *mSocket;
+    QHostAddress addr;
+    quint16 port;
+};
+
+#endif // _H

+ 42 - 0
Qt/Qt_Test/volviewform.cpp

@@ -0,0 +1,42 @@
+#include "volviewform.h"
+#include "ui_volviewform.h"
+
+VolViewForm::VolViewForm(QWidget *parent) :
+    QWidget(parent),
+    ui(new Ui::VolViewForm)
+{
+    ui->setupUi(this);
+
+    type = 0 ;
+    chn = 0;
+
+    voltage = 0.0;
+    current = 0.0;
+    power   = 0.0;
+    factor  = 0.0;
+    consum  = 0.0;
+    sts     = false ;
+
+    ui->label_6->setAlignment(Qt::AlignCenter);
+    if(type==0)
+        ui->label_6->setText("Input Vol");
+    else
+    {
+        QString msg ;
+        msg += "Ch"+QString::number(chn)+":";
+        if(sts==true)
+            msg += "on";
+        else
+            msg += "off";
+    }
+    ui->label_8->setText(QString::number(voltage,'f',2));
+    ui->label_13->setText(QString::number(current,'f',2));
+    ui->label_16->setText(QString::number(power,'f',2));
+    ui->label_15->setText(QString::number(factor,'f',2)+"%");
+    ui->label_14->setText(QString::number(consum,'f',2));
+}
+
+VolViewForm::~VolViewForm()
+{
+    delete ui;
+}

+ 33 - 0
Qt/Qt_Test/volviewform.h

@@ -0,0 +1,33 @@
+#ifndef VOLVIEWFORM_H
+#define VOLVIEWFORM_H
+
+#include <QWidget>
+
+namespace Ui {
+class VolViewForm;
+}
+
+class VolViewForm : public QWidget
+{
+    Q_OBJECT
+
+public:
+    explicit VolViewForm(QWidget *parent = 0);
+    ~VolViewForm();
+
+
+
+private:
+    Ui::VolViewForm *ui;
+    bool type ;
+    short chn ;
+    QString title;
+    float   voltage;
+    float   current;
+    float   power ;
+    float   factor;
+    float   consum;
+    bool    sts ;
+};
+
+#endif // VOLVIEWFORM_H

+ 188 - 0
Qt/Qt_Test/volviewform.ui

@@ -0,0 +1,188 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>VolViewForm</class>
+ <widget class="QWidget" name="VolViewForm">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>160</width>
+    <height>128</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Form</string>
+  </property>
+  <property name="styleSheet">
+   <string notr="true">QFrame
+{
+	background-color: rgb(85, 87, 83);
+}
+QLabel
+{
+	color: rgb(115, 210, 22);
+}</string>
+  </property>
+  <widget class="QFrame" name="frame_2">
+   <property name="geometry">
+    <rect>
+     <x>0</x>
+     <y>0</y>
+     <width>160</width>
+     <height>131</height>
+    </rect>
+   </property>
+   <property name="frameShape">
+    <enum>QFrame::StyledPanel</enum>
+   </property>
+   <property name="frameShadow">
+    <enum>QFrame::Raised</enum>
+   </property>
+   <widget class="QLabel" name="label_6">
+    <property name="geometry">
+     <rect>
+      <x>10</x>
+      <y>0</y>
+      <width>131</width>
+      <height>21</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Input Vol</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_7">
+    <property name="geometry">
+     <rect>
+      <x>10</x>
+      <y>21</y>
+      <width>85</width>
+      <height>17</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Volt(V):</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_8">
+    <property name="geometry">
+     <rect>
+      <x>103</x>
+      <y>21</y>
+      <width>47</width>
+      <height>17</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>0</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_9">
+    <property name="geometry">
+     <rect>
+      <x>11</x>
+      <y>45</y>
+      <width>85</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Cur(A):</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_10">
+    <property name="geometry">
+     <rect>
+      <x>11</x>
+      <y>68</y>
+      <width>85</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Power(W):</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_11">
+    <property name="geometry">
+     <rect>
+      <x>11</x>
+      <y>91</y>
+      <width>85</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Factor:</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_12">
+    <property name="geometry">
+     <rect>
+      <x>11</x>
+      <y>114</y>
+      <width>85</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>Sum(Kw):</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_13">
+    <property name="geometry">
+     <rect>
+      <x>103</x>
+      <y>45</y>
+      <width>47</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>0.0</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_14">
+    <property name="geometry">
+     <rect>
+      <x>103</x>
+      <y>114</y>
+      <width>47</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>0</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_15">
+    <property name="geometry">
+     <rect>
+      <x>103</x>
+      <y>91</y>
+      <width>47</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>0%</string>
+    </property>
+   </widget>
+   <widget class="QLabel" name="label_16">
+    <property name="geometry">
+     <rect>
+      <x>103</x>
+      <y>68</y>
+      <width>47</width>
+      <height>16</height>
+     </rect>
+    </property>
+    <property name="text">
+     <string>0.0</string>
+    </property>
+   </widget>
+  </widget>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>

+ 415 - 0
Qt/Qt_Test/widget.cpp

@@ -0,0 +1,415 @@
+#include "widget.h"
+#include "ui_widget.h"
+#include<QNetworkInterface>
+#include<QDateTime>
+#include<QProcess>
+#include "buttonclickthread.h"
+#include <QPainter>
+#include "pdu_ctrl.h"
+
+Widget::Widget(QWidget *parent) :
+    QWidget(parent),
+    ui(new Ui::Widget)
+{
+    ui->setupUi(this);
+    //ui->stackedWidget->setCurrentIndex(1);
+    nChidIndex=0;
+    nChidPHIndex=0;
+    nMAXChildIndex=0;
+    m_nAngle=0;
+    m_nWidth = 160;
+    m_nHeight = 128;
+    m_pAngleCtrl=NULL;
+#ifdef RS485Type
+    ui->label_MSName->hide();
+    ui->label_MSData->hide();
+    ui->label_3->hide();
+    ui->label_4->hide();
+    ui->label_5->hide();
+#else
+    //ui->label_MSName->hide();
+    //ui->label_MSData->hide();
+    //ui->label_3->hide();
+    //ui->label_4->hide();
+    //ui->label_5->hide();
+    ui->label_modbus_type->hide();
+    ui->label_modbus_Addr->hide();
+#endif
+#ifdef hightSmartPDU
+    ui->label_modbus_type->hide();
+    ui->label_modbus_Addr->hide();
+#endif
+}
+
+Widget::~Widget()
+{
+    delete ui;
+}
+
+void Widget::setInitData(QGraphicsProxyWidget *pAngleCtrl, QGraphicsView* pView, int nWidth, int nHeight)
+{
+    m_pAngleCtrl=pAngleCtrl;
+    m_nWidth= nWidth;
+    m_nHeight = nHeight;
+    m_pView=pView;
+}
+
+int Widget::getShowModeIndex()
+{
+    return ui->stackedWidget->currentIndex();
+}
+
+int Widget::getShowPagIndex()
+{
+    return ui->stackedWidget_Main->currentIndex();
+}
+
+int Widget::getShowSubIndex()
+{
+    return nChidIndex;
+}
+int Widget::getShowPHIndex()
+{
+    return nChidPHIndex;
+}
+
+void Widget::setShowPHIndex(int nIndex)
+{
+    nChidPHIndex=nIndex;
+    setPH(nChidIndex,nChidPHIndex);
+}
+
+void Widget::UpdateDate()
+{
+    QDateTime currentTime = QDateTime::currentDateTime();
+    QString strDate="Date:"+currentTime.toString("yyyy.MM.dd");
+    QString strTime="Time:"+currentTime.toString("HH:mm:ss");
+    if(ui)
+    {
+        ui->label_4->setText(strDate);
+        ui->label_5->setText(strTime);
+    }
+    QString strIP="IP:"+ReadIP();
+    ui->label_3->setText(strIP);
+
+    if(pdu_Ctrl::instance()->m_nModbusMSType!=1)
+    {
+        ui->label_modbus_type->setText(QString("ModbusType: %1").arg( "master"));
+    }else
+    {
+        ui->label_modbus_type->setText(QString("ModbusType: %1").arg("slave"));
+    }
+
+    ui->label_modbus_Addr->setText(QString("ModbusAddress: %1").arg(pdu_Ctrl::instance()->m_nModbusAddress));
+}
+
+QString Widget::ReadIP()
+{
+    QProcess process;
+    QString program = "ip"; // 或者 "ifconfig"
+    QStringList arguments;
+    if (program == "ip") {
+        arguments << "addr" << "show" << "eth0";
+    } else if (program == "ifconfig") {
+        arguments << "eth0";
+    }
+    process.start(program, arguments);
+    process.waitForFinished();
+
+    QString output = process.readAllStandardOutput();
+    QRegExp ipRegex("\\binet (\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3})/\\d{1,2}\\b");
+
+    int pos = 0;
+    while ((pos = ipRegex.indexIn(output, pos)) != -1) {
+        return ipRegex.cap(1);
+    }
+    return ""; // 没有找到IP地址
+}
+
+void Widget::SetData(QLabel *pLab, QString strShow)
+{
+    if(pLab)
+    {
+        pLab->setText(strShow);
+    }
+}
+
+void Widget::SetV(QString strShow){SetData(ui->label_8,strShow);SetData(ui->label_phV,strShow);}
+
+void Widget::SetA(QString strShow){SetData(ui->label_13,strShow);SetData(ui->label_A,strShow);SetData(ui->label_phA,strShow);}
+
+void Widget::SetW(QString strShow){SetData(ui->label_16,strShow);SetData(ui->label_W,strShow);SetData(ui->label_phW,strShow);}
+
+void Widget::SetF(QString strShow){SetData(ui->label_15,strShow);SetData(ui->label_F,strShow);SetData(ui->label_phF,strShow);}
+
+void Widget::SetSUM(QString strShow){SetData(ui->label_14,strShow);SetData(ui->label_S,strShow);SetData(ui->label_phKw,strShow);}
+
+void Widget::SetT(QString strShow){SetData(ui->label_Temp,strShow);}
+void Widget::SetH(QString strShow){SetData(ui->label_Humidity,strShow+"%");}
+void Widget::SetStatus(QString strShow){SetData(ui->label_V,strShow);}
+
+void Widget::SetIP(QString strIP)
+{
+    if(ui)
+    {
+        ui->label_3->setText(strIP);
+    }
+}
+
+void Widget::setCH(int nIndex)
+{
+    QString  strShow=QString("Output CH%1").arg(nIndex);
+    SetData(ui->label_chName,strShow);
+
+}
+void Widget::setPH(int nIndex,int nPHType)
+{
+    QString  strShow="";
+    switch (nPHType) {
+    case 1:
+        strShow="-A";
+        break;
+    case 2:
+        strShow="-B";
+        break;
+    case 3:
+        strShow="-C";
+        break;
+    default:
+        break;
+    }
+    QString  strPHShow=QString("Output CH%1%2").arg(nIndex).arg(strShow);
+
+    SetData(ui->label_18,strPHShow);
+}
+/*
+void Widget::BtnDown(int nButtonID, int nDownType)
+{
+    switch (nButtonID) {
+        case GPIO_KEY1:
+            //1按钮
+            if(nDownType==BtnDown_C)
+            {
+                pageUp();
+            }
+            break;
+        case GPIO_KEY2:
+            {
+            }
+            break;
+        case GPIO_KEY3:
+            //3按钮
+            if(nDownType==BtnDown_C)
+            {
+                pageDown();
+            }
+            break;
+        case GPIO_KEY4:
+
+            break;
+        default:
+            break;
+    }
+    qDebug()<<"Key"<<nButtonID<<" Type="<<nDownType;
+}
+*/
+void Widget::pageUp()
+{
+    int nIndex=ui->stackedWidget_Main->currentIndex();
+    switch (nIndex) {
+    case 1://
+    {
+        if(nMAXChildIndex>0)
+        {
+            nChidIndex=1;
+            setCH(nChidIndex);
+            ui->stackedWidget_Main->setCurrentIndex(2);
+        }else
+        {
+            ui->stackedWidget_Main->setCurrentIndex(3);
+        }
+    }
+        break;
+    case 2://通道页面
+    {
+        if(nChidIndex<nMAXChildIndex)
+        {
+            setCH(nChidIndex);
+            nChidIndex+=1;
+            nChidPHIndex=0;
+        }else
+        {
+            ui->stackedWidget_Main->setCurrentIndex(3);
+            nChidIndex=0;
+            nChidPHIndex=0;
+        }
+    }
+        break;
+    case 3://传感器页面
+    {
+        ui->stackedWidget_Main->setCurrentIndex(0);
+    }
+    break;
+    case 4://ph通道页面
+        {
+            if(nChidPHIndex<=2&&nChidPHIndex>=1)
+            {
+                nChidPHIndex+=1;
+                setPH(nChidIndex,nChidPHIndex);
+            }else if(nChidPHIndex=3||nChidPHIndex==0)
+            {
+                nChidPHIndex=1;
+                setPH(nChidIndex,nChidPHIndex);
+            }
+        }
+        break;
+    default:
+    {
+        ui->stackedWidget_Main->setCurrentIndex(nIndex+1);
+    }
+        break;
+    }
+    qDebug()<<"Index:"<<nIndex<<"ChID:"<<nChidIndex;
+}
+
+void Widget::pageDown()
+{
+    int nIndex=ui->stackedWidget_Main->currentIndex();
+    if(nIndex==0)
+    {
+
+        ui->stackedWidget_Main->setCurrentIndex(3);
+    }else if(nIndex==3)
+    {
+        if(nMAXChildIndex>0)
+        {
+            nChidIndex=nMAXChildIndex;
+            setCH(nChidIndex);
+            ui->stackedWidget_Main->setCurrentIndex(2);
+        }else
+        {
+            ui->stackedWidget_Main->setCurrentIndex(1);
+        }
+
+    }
+    else if(nIndex==2)
+    {
+        if(nChidIndex<=1)
+        {
+            ui->stackedWidget_Main->setCurrentIndex(1);
+            nChidIndex=0;
+        }
+        else
+        {
+            setCH(nChidIndex);
+            nChidIndex-=1;
+        }
+    }else if(nIndex==4)
+    {
+        if(nChidPHIndex<=3&&nChidPHIndex>=2)
+        {
+            nChidPHIndex-=1;
+            setPH(nChidIndex,nChidPHIndex);
+        }else if(nChidPHIndex=1||nChidPHIndex==0)
+        {
+            nChidPHIndex=3;
+            setPH(nChidIndex,nChidPHIndex);
+        }
+    }else
+    {
+        ui->stackedWidget_Main->setCurrentIndex(nIndex-1);
+    }
+    qDebug()<<"Index:"<<nIndex<<"ChID:"<<nChidIndex;
+}
+
+void Widget::ChangeView(int widgetType, int nIndex)
+{
+    if(widgetType_Main==widgetType)
+    {
+        qDebug()<<"Widget->ChangeView->widgetType_Main index="<<nIndex;
+        if(nIndex==0)
+        {
+            ui->stackedWidget->setCurrentIndex(0);
+            ui->stackedWidget_Main->setCurrentIndex(0);
+            nChidIndex=0;
+        }else
+        {
+            ui->stackedWidget->setCurrentIndex(0);
+            ui->stackedWidget_Main->setCurrentIndex(nIndex);
+        }
+    }else if(widgetType_Setting==widgetType)
+    {
+        qDebug()<<"Widget->ChangeView->widgetType_Setting index="<<nIndex;
+        ui->stackedWidget->setCurrentIndex(1);
+        switch (nIndex) {
+        case settingMode_Modbus:
+        {
+            ui->stackedWidget_Setting->setCurrentIndex(0);
+            break;
+        }
+        case settingMode_IP:
+        {
+            ui->stackedWidget_Setting->setCurrentIndex(1);
+            break;
+        }
+        }
+    }
+}
+
+void Widget::setSelectStatus(int nIndex)
+{
+    ui->label_addressName->setStyleSheet(LABEL_Defalut);
+    ui->label_addressData->setStyleSheet(LABEL_Defalut);
+    ui->label_MSData->setStyleSheet(LABEL_Defalut);
+    ui->label_MSName->setStyleSheet(LABEL_Defalut);
+    ui->label_SaveName->setStyleSheet(LABEL_Defalut);
+    ui->label_SaveData->setStyleSheet(LABEL_Defalut);
+    switch (nIndex) {
+    case 0://address
+    {
+        ui->label_addressName->setStyleSheet(LABEL_SELECT);
+        ui->label_addressData->setStyleSheet(LABEL_SELECT);
+    }break;
+    case 1://SAVE
+    {
+        ui->label_SaveName->setStyleSheet(LABEL_SELECT);
+        ui->label_SaveData->setStyleSheet(LABEL_SELECT);
+    }break;
+    case 2://主从
+    {
+        ui->label_MSData->setStyleSheet(LABEL_SELECT);
+        ui->label_MSName->setStyleSheet(LABEL_SELECT);
+    }break;
+    }
+}
+
+void Widget::CtrlBtnSet(int nIndex, int nData)
+{
+    switch (nIndex) {
+    case 0://address
+    {
+        ui->label_addressData->setText(QString::number(nData));
+    }break;
+    case 1://SAVE
+    {
+        if(nData==1)
+        {
+            ui->label_SaveData->setText("YES");
+        }else
+        {
+            ui->label_SaveData->setText("NO");
+        }
+
+    }break;
+    case 2://主从
+    {
+        if(nData!=1)
+        {
+            ui->label_MSData->setText("master");
+        }else
+        {
+            ui->label_MSData->setText("slave");
+        }
+    }break;
+    }
+}

+ 95 - 0
Qt/Qt_Test/widget.h

@@ -0,0 +1,95 @@
+#ifndef WIDGET_H
+#define WIDGET_H
+
+#include <QWidget>
+#include "udphelper.h"
+#include "volviewform.h"
+#include <QList>
+#include <QLabel>
+#include <QGraphicsProxyWidget>
+#include <QGraphicsView>
+
+namespace Ui {
+class Widget;
+}
+//ST7735驱动
+#define ST7735_ERROR
+
+#ifdef ST7735_ERROR
+//ST7735 驱动使用GRB红色与蓝色位置相反
+#define LABEL_RED "QLabel{color: blue;}"
+#define LABEL_GREEN "QLabel{color: rgb(115, 210, 22);}"
+
+#define LABEL_SELECT  "background-color:rgb(115, 210, 22);color: white;"
+#define LABEL_Defalut "background-color:rgb(85, 87, 83);color: rgb(115, 210, 22);"
+#else
+#define LABEL_RED "QLabel{color: red;}"
+#define LABEL_GREEN "QLabel{color: rgb(115, 210, 22);}"
+
+#define LABEL_SELECT  "background-color:rgb(115, 210, 22);color: white;"
+#define LABEL_Defalut "background-color:rgb(85, 87, 83);color: rgb(115, 210, 22);"
+#endif
+
+class Widget : public QWidget
+{
+    Q_OBJECT
+
+public:
+    explicit Widget(QWidget *parent = 0);
+    ~Widget();
+    void setInitData(QGraphicsProxyWidget* pAngleCtrl, QGraphicsView* pView, int nWidget,int nHight);
+    //是否显示详细数据
+    int getShowModeIndex();
+    int getShowPagIndex();
+    int getShowSubIndex();
+    int getShowPHIndex();
+    void setShowPHIndex(int nIndex);
+    //更新日期IP
+    void UpdateDate();
+    QString ReadIP();
+
+
+    void SetData(QLabel* pLab,QString strShow);
+    void SetV(QString strShow);
+    void SetA(QString strShow);
+    void SetW(QString strShow);
+    void SetF(QString strShow);
+    void SetSUM(QString strShow);
+    void SetIP(QString strIP);
+    void SetT(QString strShow);
+    void SetH(QString strShow);
+    void setCH(int nIndex);
+    void setPH(int nIndex,int nPhID);
+    void SetStatus(QString strShow);
+    //点击事件
+    //void BtnDown(int nButtonID,int nDownType);
+
+    //上翻页
+    void pageUp();
+    //下翻页
+    void pageDown();
+    //切换页面
+    void ChangeView(int widgetType,int nIndex);
+    //modbus设置
+    void setSelectStatus(int nIndex);
+    void CtrlBtnSet(int nIndex,int nData);
+    int nMAXChildIndex;
+public:
+    Ui::Widget *ui;
+private:
+
+    UdpHelper* udpHelper;
+    int device_type ;
+    int device_chn ;
+    QList<VolViewForm*> volView;
+    //当前显示页面ID
+    int nChidIndex;
+    int nChidPHIndex;
+    int m_nAngle;
+    QGraphicsProxyWidget* m_pAngleCtrl;
+    QGraphicsView* m_pView;
+    int m_nWidth;
+    int m_nHeight;
+};
+
+#endif // WIDGET_H

Разница между файлами не показана из-за своего большого размера
+ 1143 - 0
Qt/Qt_Test/widget.ui