Browse Source

初始化

jiaxiaoqiang 11 months ago
commit
16902867cd
100 changed files with 11232 additions and 0 deletions
  1. 11 0
      .gitignore
  2. 10 0
      AppScope/app.json5
  3. 8 0
      AppScope/resources/base/element/string.json
  4. BIN
      AppScope/resources/base/media/jg_icon.png
  5. 49 0
      build-profile.json5
  6. 6 0
      entry/.gitignore
  7. 31 0
      entry/build-profile.json5
  8. 6 0
      entry/hvigorfile.ts
  9. 18 0
      entry/obfuscation-rules.txt
  10. 10 0
      entry/oh-package.json5
  11. 259 0
      entry/src/main/commont/component/DeviceDialog.ets
  12. 43 0
      entry/src/main/commont/component/TitleComponent.ets
  13. 70 0
      entry/src/main/ets/entryability/EntryAbility.ets
  14. 886 0
      entry/src/main/ets/pages/BoardTesting/AITest.ets
  15. 987 0
      entry/src/main/ets/pages/BoardTesting/BoardTesting.ets
  16. 1145 0
      entry/src/main/ets/pages/BoardTesting/CanTest.ets
  17. 729 0
      entry/src/main/ets/pages/Device/ElectronicLoad.ets
  18. 236 0
      entry/src/main/ets/pages/Device/ElectronicMultimeter.ets
  19. 256 0
      entry/src/main/ets/pages/Device/PXISwitch.ets
  20. 324 0
      entry/src/main/ets/pages/Device/ProgrammablePower.ets
  21. 182 0
      entry/src/main/ets/pages/Device/SwitchMatrix.ets
  22. 164 0
      entry/src/main/ets/pages/Index.ets
  23. 1604 0
      entry/src/main/ets/pages/PanelMaintenanceInspection.ets
  24. 1792 0
      entry/src/main/ets/pages/PowerDetection.ets
  25. 1680 0
      entry/src/main/ets/pages/RFtesting.ets
  26. 60 0
      entry/src/main/ets/view/DataManagement.ets
  27. 81 0
      entry/src/main/ets/view/DetectingSystem.ets
  28. 177 0
      entry/src/main/ets/view/DeviceManagement.ets
  29. 114 0
      entry/src/main/ets/view/OperationTerminal.ets
  30. 37 0
      entry/src/main/module.json5
  31. 98 0
      entry/src/main/resources/base/element/color.json
  32. 21 0
      entry/src/main/resources/base/element/float.json
  33. 32 0
      entry/src/main/resources/base/element/font_size.json
  34. 17 0
      entry/src/main/resources/base/element/string.json
  35. BIN
      entry/src/main/resources/base/media/BG_two.png
  36. BIN
      entry/src/main/resources/base/media/PXI_switch.png
  37. 3 0
      entry/src/main/resources/base/media/actual_value.svg
  38. 3 0
      entry/src/main/resources/base/media/add.svg
  39. BIN
      entry/src/main/resources/base/media/background.png
  40. BIN
      entry/src/main/resources/base/media/board_testing.png
  41. 3 0
      entry/src/main/resources/base/media/capacitance.svg
  42. 3 0
      entry/src/main/resources/base/media/choice.svg
  43. BIN
      entry/src/main/resources/base/media/click_image.png
  44. 5 0
      entry/src/main/resources/base/media/current.svg
  45. BIN
      entry/src/main/resources/base/media/data_management.png
  46. BIN
      entry/src/main/resources/base/media/data_management_black.png
  47. BIN
      entry/src/main/resources/base/media/delete.png
  48. 6 0
      entry/src/main/resources/base/media/delete1.svg
  49. BIN
      entry/src/main/resources/base/media/detecting_system.png
  50. BIN
      entry/src/main/resources/base/media/detecting_system_black.png
  51. BIN
      entry/src/main/resources/base/media/device_management.png
  52. BIN
      entry/src/main/resources/base/media/device_management_black.png
  53. BIN
      entry/src/main/resources/base/media/electronic_image_file.png
  54. BIN
      entry/src/main/resources/base/media/electronic_load.png
  55. BIN
      entry/src/main/resources/base/media/electronic_universal_meter.png
  56. BIN
      entry/src/main/resources/base/media/enter_background.png
  57. 13 0
      entry/src/main/resources/base/media/home.svg
  58. BIN
      entry/src/main/resources/base/media/homePage.png
  59. BIN
      entry/src/main/resources/base/media/jg_icon.png
  60. BIN
      entry/src/main/resources/base/media/logo.png
  61. BIN
      entry/src/main/resources/base/media/lower.png
  62. BIN
      entry/src/main/resources/base/media/maintenance_execution.png
  63. BIN
      entry/src/main/resources/base/media/maintenance_progress.png
  64. BIN
      entry/src/main/resources/base/media/maintenance_record.png
  65. BIN
      entry/src/main/resources/base/media/maintenance_statistics.png
  66. BIN
      entry/src/main/resources/base/media/midline.png
  67. 3 0
      entry/src/main/resources/base/media/minus.svg
  68. BIN
      entry/src/main/resources/base/media/news.png
  69. 22 0
      entry/src/main/resources/base/media/no_Choice.svg
  70. BIN
      entry/src/main/resources/base/media/number_backbround_gray.png
  71. BIN
      entry/src/main/resources/base/media/number_background_blue.png
  72. BIN
      entry/src/main/resources/base/media/number_background_green.png
  73. BIN
      entry/src/main/resources/base/media/operation_terminal.png
  74. BIN
      entry/src/main/resources/base/media/operation_terminal_black.png
  75. BIN
      entry/src/main/resources/base/media/oscilloscope.png
  76. BIN
      entry/src/main/resources/base/media/panel_detection.png
  77. BIN
      entry/src/main/resources/base/media/personal.png
  78. BIN
      entry/src/main/resources/base/media/post_repair_inspection.png
  79. 3 0
      entry/src/main/resources/base/media/power.svg
  80. BIN
      entry/src/main/resources/base/media/power_detection.png
  81. BIN
      entry/src/main/resources/base/media/radio_frequency_detection.png
  82. 3 0
      entry/src/main/resources/base/media/resistance.svg
  83. 3 0
      entry/src/main/resources/base/media/return.svg
  84. 5 0
      entry/src/main/resources/base/media/sending.svg
  85. BIN
      entry/src/main/resources/base/media/serial1.png
  86. BIN
      entry/src/main/resources/base/media/serial2.png
  87. BIN
      entry/src/main/resources/base/media/serial3.png
  88. BIN
      entry/src/main/resources/base/media/serial4.png
  89. BIN
      entry/src/main/resources/base/media/serial5.png
  90. BIN
      entry/src/main/resources/base/media/serial6.png
  91. BIN
      entry/src/main/resources/base/media/serial7.png
  92. BIN
      entry/src/main/resources/base/media/serial8.png
  93. BIN
      entry/src/main/resources/base/media/source.png
  94. BIN
      entry/src/main/resources/base/media/startIcon.png
  95. 4 0
      entry/src/main/resources/base/media/stop.svg
  96. 10 0
      entry/src/main/resources/base/media/subscript_space.svg
  97. BIN
      entry/src/main/resources/base/media/switch_matrix.png
  98. BIN
      entry/src/main/resources/base/media/system_inspection.png
  99. BIN
      entry/src/main/resources/base/media/trial_application.png
  100. 0 0
      entry/src/main/resources/base/media/upper.png

+ 11 - 0
.gitignore

@@ -0,0 +1,11 @@
+/node_modules
+/oh_modules
+/local.properties
+/.idea
+**/build
+/.hvigor
+.cxx
+/.clangd
+/.clang-format
+/.clang-tidy
+**/.test

+ 10 - 0
AppScope/app.json5

@@ -0,0 +1,10 @@
+{
+  "app": {
+    "bundleName": "com.example.cengfei",
+    "vendor": "example",
+    "versionCode": 1000000,
+    "versionName": "1.0.0",
+    "icon": "$media:jg_icon",
+    "label": "$string:app_name"
+  }
+}

+ 8 - 0
AppScope/resources/base/element/string.json

@@ -0,0 +1,8 @@
+{
+  "string": [
+    {
+      "name": "app_name",
+      "value": "晶格"
+    }
+  ]
+}

BIN
AppScope/resources/base/media/jg_icon.png


+ 49 - 0
build-profile.json5

@@ -0,0 +1,49 @@
+{
+  "app": {
+    "signingConfigs": [
+      {
+        "name": "default",
+        "material": {
+          "certpath": "C:/Users/yxj23/.ohos/config/openharmony/default_CengFei_A9Exw3iMROQ8tU73wpr_29dyhQ1n3x-vgXtkBdheyBI=.cer",
+          "storePassword": "0000001AD851A841260535053383B8CA5B6D013EDD888AAA8BF3B3B2884D7C7A5F2814655C71E26B044F",
+          "keyAlias": "debugKey",
+          "keyPassword": "0000001A2CB47FFA98C9D25C211D1A96A22351B81A69781D44BA8AE684033D2388DB71CA2ECA6F108A53",
+          "profile": "C:/Users/yxj23/.ohos/config/openharmony/default_CengFei_A9Exw3iMROQ8tU73wpr_29dyhQ1n3x-vgXtkBdheyBI=.p7b",
+          "signAlg": "SHA256withECDSA",
+          "storeFile": "C:/Users/yxj23/.ohos/config/openharmony/default_CengFei_A9Exw3iMROQ8tU73wpr_29dyhQ1n3x-vgXtkBdheyBI=.p12"
+        }
+      }
+    ],
+    "products": [
+      {
+        "name": "default",
+        "signingConfig": "default",
+        "compileSdkVersion": 10,
+        "compatibleSdkVersion": 10,
+        "runtimeOS": "OpenHarmony",
+      }
+    ],
+    "buildModeSet": [
+      {
+        "name": "debug",
+      },
+      {
+        "name": "release"
+      }
+    ]
+  },
+  "modules": [
+    {
+      "name": "entry",
+      "srcPath": "./entry",
+      "targets": [
+        {
+          "name": "default",
+          "applyToProducts": [
+            "default"
+          ]
+        }
+      ]
+    }
+  ]
+}

+ 6 - 0
entry/.gitignore

@@ -0,0 +1,6 @@
+/node_modules
+/oh_modules
+/.preview
+/build
+/.cxx
+/.test

+ 31 - 0
entry/build-profile.json5

@@ -0,0 +1,31 @@
+{
+  "apiType": "stageMode",
+  "buildOption": {
+    "arkOptions": {
+      // "apPath": "./modules.ap"  /* Profile used for profile-guided optimization (PGO), a compiler optimization technique to improve app runtime performance. */
+    }
+  },
+  "buildOptionSet": [
+    {
+      "name": "release",
+      "arkOptions": {
+        "obfuscation": {
+          "ruleOptions": {
+            "enable": true,
+            "files": [
+              "./obfuscation-rules.txt"
+            ]
+          }
+        }
+      }
+    },
+  ],
+  "targets": [
+    {
+      "name": "default"
+    },
+    {
+      "name": "ohosTest",
+    }
+  ]
+}

+ 6 - 0
entry/hvigorfile.ts

@@ -0,0 +1,6 @@
+import { hapTasks } from '@ohos/hvigor-ohos-plugin';
+
+export default {
+    system: hapTasks,  /* Built-in plugin of Hvigor. It cannot be modified. */
+    plugins:[]         /* Custom plugin to extend the functionality of Hvigor. */
+}

+ 18 - 0
entry/obfuscation-rules.txt

@@ -0,0 +1,18 @@
+# Define project specific obfuscation rules here.
+# You can include the obfuscation configuration files in the current module's build-profile.json5.
+#
+# For more details, see
+#   https://gitee.com/openharmony/arkcompiler_ets_frontend/blob/master/arkguard/README.md
+
+# Obfuscation options:
+# -disable-obfuscation: disable all obfuscations
+# -enable-property-obfuscation: obfuscate the property names
+# -enable-toplevel-obfuscation: obfuscate the names in the global scope
+# -compact: remove unnecessary blank spaces and all line feeds
+# -remove-log: remove all console.* statements
+# -print-namecache: print the name cache that contains the mapping from the old names to new names
+# -apply-namecache: reuse the given cache file
+
+# Keep options:
+# -keep-property-name: specifies property names that you want to keep
+# -keep-global-name: specifies names that you want to keep in the global scope

+ 10 - 0
entry/oh-package.json5

@@ -0,0 +1,10 @@
+{
+  "name": "entry",
+  "version": "1.0.0",
+  "description": "Please describe the basic information.",
+  "main": "",
+  "author": "",
+  "license": "",
+  "dependencies": {}
+}
+

+ 259 - 0
entry/src/main/commont/component/DeviceDialog.ets

@@ -0,0 +1,259 @@
+import router from '@ohos.router'
+
+@CustomDialog
+export struct DeviceDialog {
+  @Link Number:number[]
+  //0:表示没有,1:表示AI,2:表示串口,3:表示CAN
+  @Link select1:number
+  //todo 删除
+  @Link select2:number
+  @Link select3:number
+  @Link select4:number
+  @State SerialNumber:number=0
+  scroller: Scroller = new Scroller()
+  controller?: CustomDialogController;
+  build() {
+    Column(){
+      Text('槽位选择')
+        .fontSize($r('app.float.fontSize_30'))
+        .fontWeight(FontWeight.Medium)
+        .fontColor($r('app.color.black_100'))
+        .margin({bottom:px2vp(20)})
+      Scroll(this.scroller){
+        Column(){
+          Row(){
+            Text(this.Number[0].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+              Blank()
+            Text(this.select2===0?'-':this.select2===1?'AI':this.select2===2?'串口':'CAN')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+              .textAlign(TextAlign.End)
+          }
+          .width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[0]
+            if (this.select2===2) {
+              router.pushUrl({
+                url:'pages/BoardTesting/BoardTesting',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[1].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select3===0?'-':this.select3===1?'AI':this.select3===2?'串口':'CAN')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[2]
+            if (this.select3===3) {
+              router.pushUrl({
+                url:'pages/BoardTesting/CanTest',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[2].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select3===0?'-':this.select3===1?'AI':this.select3===2?'串口':'CAN')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[2]
+            if (this.select3===3) {
+              router.pushUrl({
+                url:'pages/BoardTesting/CanTest',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+
+          Row(){
+            Text(this.Number[3].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select1===0?'-':this.select1===1?'AI':this.select1===2?'串口':'CAN')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[3]
+            if (this.select1===1) {
+              router.pushUrl({
+                url:'pages/BoardTesting/AITest',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[4].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select1===3?'CAN':this.select1===1?'AI':this.select1===2?'串口':'-')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[4]
+            if (this.select2===2) {
+              router.pushUrl({
+                url:'pages/BoardTesting/BoardTesting',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[5].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select1===3?'CAN':this.select1===1?'AI':this.select1===2?'串口':'-')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[5]
+            if (this.select2===2) {
+              router.pushUrl({
+                url:'pages/BoardTesting/BoardTesting',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[6].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select1===3?'CAN':this.select1===1?'AI':this.select1===2?'串口':'-')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[6]
+            if (this.select2===2) {
+              router.pushUrl({
+                url:'pages/BoardTesting/BoardTesting',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+          Row(){
+            Text(this.Number[7].toString()+'#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Text(this.select1===3?'CAN':this.select1===1?'AI':this.select1===2?'串口':'-')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.blue_100'))
+          }.width(px2vp(528))
+          .height(px2vp(80))
+          .padding({left:px2vp(24),right:px2vp(24)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .margin({bottom:px2vp(20)})
+          .onClick(()=>{
+            this.SerialNumber=this.Number[7]
+            if (this.select2===2) {
+              router.pushUrl({
+                url:'pages/BoardTesting/BoardTesting',
+                params: {
+                  info: this.SerialNumber
+                }
+              })
+            }
+          })
+        }
+        .width(px2vp(528))
+        .height(px2vp(800))
+      }
+      .scrollable(ScrollDirection.Vertical)
+      .width(px2vp(528))
+      .height(px2vp(500))
+      .scrollBar(BarState.Off)
+
+    }.width(px2vp(568))
+    .height(px2vp(600))
+    .backgroundColor($r('app.color.white_f1f3f5'))
+    .borderRadius(px2vp(16))
+    .padding(px2vp(20))
+  }
+
+}

+ 43 - 0
entry/src/main/commont/component/TitleComponent.ets

@@ -0,0 +1,43 @@
+import router from '@ohos.router';
+import process from '@ohos.process'
+@Component
+export struct TitleComponent{
+  build() {
+    Row(){
+      Row(){
+        Image($r('app.media.return'))
+          .width(px2vp(48))
+          .height(px2vp(48))
+          .objectFit(ImageFit.Contain)
+          .margin({left:px2vp(40)})
+
+      }.width(px2vp(500))
+      .onClick(()=>{
+        router.back();
+      })
+      Blank()
+      Row(){
+        Blank()
+        Image($r('app.media.homePage'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+        Image($r('app.media.news'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+        Image($r('app.media.personal'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+          .onClick(()=>{
+            let pro = new process.ProcessManager();
+            pro.exit(0);
+          })
+      }.width(px2vp(500))
+
+    }.width(px2vp(1920))
+    .height(px2vp(80))
+    .alignItems(VerticalAlign.Center)
+  }
+}

+ 70 - 0
entry/src/main/ets/entryability/EntryAbility.ets

@@ -0,0 +1,70 @@
+import AbilityConstant from '@ohos.app.ability.AbilityConstant';
+import hilog from '@ohos.hilog';
+import UIAbility from '@ohos.app.ability.UIAbility';
+import Want from '@ohos.app.ability.Want';
+import window from '@ohos.window';
+
+export default class EntryAbility extends UIAbility {
+  onCreate(want: Want, launchParam: AbilityConstant.LaunchParam): void {
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onCreate');
+  }
+
+  onDestroy(): void {
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onDestroy');
+  }
+
+  onWindowStageCreate(windowStage: window.WindowStage): void {
+    // Main window is created, set main page for this ability
+    console.info(`EntryAbility onWindowStageCreate`)
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onWindowStageCreate');
+    //
+    // 1.获取应用主窗口。
+    let windowClass: window.Window
+    windowStage.getMainWindow((err, data) => {
+
+      if (err.code) {
+        console.error('Failed to obtain the main window. Cause: ' + JSON.stringify(err));
+        return;
+      }
+      windowClass = data;
+      console.info('Succeeded in obtaining the main window. Data: ' + JSON.stringify(data));
+      // 2.实现沉浸式效果:设置导航栏、状态栏不显示。
+      let names:[] = [];
+      windowClass.setWindowSystemBarEnable(names, (err) => {
+        if (err.code) {
+          console.error('Failed to set the system bar to be visible. Cause:' + JSON.stringify(err));
+          return;
+        }
+        console.info('Succeeded in setting the system bar to be visible.');
+      });
+
+      windowClass.setWindowLayoutFullScreen(true)
+    })
+    // let choicePages:class1={}
+    // console.log("获取当前页面"+choicePages.choicePages?.toString())
+    windowStage.loadContent("pages/Index", (err, data) => {
+      // windowStage.loadContent("pages/OutboundStation", (err, data) => {
+      if (err.code) {
+        console.info(`Failed to load the content. Cause: ${JSON.stringify(err)}`)
+        return
+      }
+      console.info( `Succeeded in loading the content. Data: ${JSON.stringify(data)}`)
+    }
+    )
+  }
+
+  onWindowStageDestroy(): void {
+    // Main window is destroyed, release UI related resources
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onWindowStageDestroy');
+  }
+
+  onForeground(): void {
+    // Ability has brought to foreground
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onForeground');
+  }
+
+  onBackground(): void {
+    // Ability has back to background
+    hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onBackground');
+  }
+}

+ 886 - 0
entry/src/main/ets/pages/BoardTesting/AITest.ets

@@ -0,0 +1,886 @@
+import router from '@ohos.router'
+import { DeviceDialog } from '../../../commont/component/DeviceDialog'
+@Entry
+@Component
+struct AITest {
+  //手势放大缩小
+  @State scaleValue: number = 1;
+  @State pinchValue: number = 1;
+  @State pinchX: number = 0;
+  @State pinchY: number = 0;
+ @State Axis:number[][]=[[px2vp(100),px2vp(200)],[px2vp(120),px2vp(220)],
+   [px2vp(300),px2vp(300)],
+   [px2vp(500),px2vp(500)],
+   [px2vp(600),px2vp(300)],
+   [px2vp(800),px2vp(100)],
+ ]
+  //Y坐标
+  @State YAxis:number[]=[10,9,8,7,6,5,4,3,2,1,0,-1,-2,-3,-4,-5,-6,-7,-8,-9,-10]
+  //通道
+  @State number:number=0
+  controller: TextInputController = new TextInputController()
+  //连接状态1有,0没有
+  @State connect:number=0
+  //采样频率
+  @State samplingFrequency:string=''
+  //采样范围
+  @State SampleRange:string=''
+  //实时数据
+
+  @State RealTime:Array<RealTimeClass>=[
+    {data:100,number:1},
+    {data:100,number:2},
+    {data:100,number:3},
+    {data:100,number:4},
+    {data:100,number:5},
+    {data:100,number:6},
+    {data:100,number:7},
+    {data:100,number:8},
+    {data:100,number:9},
+    {data:100,number:10},
+    {data:100,number:11},
+    {data:100,number:12},
+    {data:100,number:13},
+    {data:100,number:14},
+    {data:100,number:15},
+    {data:100,number:16},
+  ]
+  //通道
+  @State thoroughfare:Array<thoroughfareClass>=[
+    {switch:0,number:1},
+    {switch:0,number:2},
+    {switch:0,number:3},
+    {switch:0,number:4},
+    {switch:0,number:5},
+    {switch:0,number:6},
+    {switch:0,number:7},
+    {switch:0,number:8},
+    {switch:0,number:9},
+    {switch:0,number:10},
+    {switch:0,number:11},
+    {switch:0,number:12},
+    {switch:0,number:13},
+    {switch:0,number:14},
+    {switch:0,number:15},
+    {switch:0,number:16},
+  ]
+  @State select:number=0
+  //过采样倍率
+  @State OversamplingRate: string = '';
+  @State private manySendingList:Array<manySendingClass>=[
+    {content:'32845723425345',switch:1},
+    {content:'32845234425345',switch:0},
+    {content:'3282345345',switch:1},
+    {content:'328234234425345',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234524355345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'322423425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234425345',switch:1},
+    {content:'3284523445',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845234425345',switch:0},
+    {content:'3282345345',switch:1},
+    {content:'328234234425345',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234524355345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'322423425345',switch:1},
+
+
+  ]
+  @State private serialPort:Array<serialPortClass>=[
+    {OversamplingRate:'过采样倍率1'},
+    {OversamplingRate:'过采样倍率2'},
+    {OversamplingRate:'过采样倍率3'},
+    {OversamplingRate:'过采样倍率4'},
+    {OversamplingRate:'过采样倍率5'}]
+
+  @State private SampleRangeNameList:Array<SampleRangeClass>=[
+    {SampleRangeName:'采样范围1'},
+    {SampleRangeName:'采样范围2'},
+    {SampleRangeName:'采样范围3'},
+    {SampleRangeName:'采样范围4'},
+    {SampleRangeName:'采样范围5'}]
+  @State private samplingFrequencyList:Array<samplingFrequencyClass>=[
+    {samplingFrequencyName:'采样频率1'},
+    {samplingFrequencyName:'采样频率2'},
+    {samplingFrequencyName:'采样频率3'},
+    {samplingFrequencyName:'采样频率4'},
+    {samplingFrequencyName:'采样频率5'}]
+
+  //0:表示没有,1:表示AI,2:表示串口,3:表示CAN
+  @State select1:number=1
+  //todo 删除
+  @State select2:number=2
+  @State select3:number=3
+  @State select4:number=0
+  @State private Number:number[]=[1,2,3,4,5,6,7,8]
+  private dialogController: CustomDialogController = new CustomDialogController({
+    builder:DeviceDialog({
+      Number:this.Number,
+      select1:this.select1,
+      select2:this.select2,
+      select3:this.select3,
+      select4:this.select4,
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+  serialPortController: CustomDialogController = new CustomDialogController({
+    builder:serialPort({
+      samplingFrequency:this.samplingFrequency,
+      SampleRange:this.SampleRange,
+      select:this.select,
+      serialPort:this.serialPort,
+      OversamplingRate:this.OversamplingRate,
+      SampleRangeNameList:this.SampleRangeNameList,
+      samplingFrequencyList:this.samplingFrequencyList
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+  @State SerialNumber:number=0
+  aboutToAppear(): void {
+    const params = router.getParams() as Record<string, number>; // 获取传递过来的参数对象
+    if (params) {
+      this.SerialNumber = params.info as number; // 获取info属性的值
+      console.log("textTag"+this.SerialNumber)
+    }
+
+  }
+  thoroughfareController: CustomDialogController = new CustomDialogController({
+    builder:thoroughfare({
+      thoroughfare:this.thoroughfare,
+
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+  build() {
+    Column() {
+      Row() {
+        Row() {
+          Image($r('app.media.return'))
+            .width(px2vp(48))
+            .height(px2vp(48))
+            .objectFit(ImageFit.Contain)
+            .margin({ left: px2vp(40) })
+        }.width(px2vp(500))
+        .height(px2vp(80))
+        .onClick(() => {
+          router.back();
+        })
+        Blank()
+        Column(){
+          Text('板卡测试')
+            .fontSize($r('app.float.fontSize_24'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Center)
+            .width(px2vp(608))
+            .height(px2vp(80))
+            .borderRadius($r('app.float.borderRadius_16'))
+        }
+        .justifyContent(FlexAlign.Center)
+        Blank()
+        Row() {
+          Blank()
+          Image($r('app.media.homePage'))
+            .margin({ right: px2vp(40) })
+            .width(px2vp(48))
+            .height(px2vp(48))
+            .onClick(()=>{
+              router.pushUrl({
+                url:'pages/Index'
+              })
+            })
+          Image($r('app.media.news'))
+            .margin({ right: px2vp(40) })
+            .width(px2vp(48))
+            .height(px2vp(48))
+          Image($r('app.media.personal'))
+            .margin({ right: px2vp(40) })
+            .width(px2vp(48))
+            .height(px2vp(48))
+        }.width(px2vp(500))
+
+      }.width(px2vp(1920))
+      .height(px2vp(80))
+      .alignItems(VerticalAlign.Center)
+      .margin({bottom:px2vp(20)})
+      Row(){
+        Column(){
+          Column(){
+            Image(this.SerialNumber===1?$r('app.media.serial1'):this.SerialNumber===2?$r('app.media.serial2'):
+              this.SerialNumber===3?$r('app.media.serial3'):this.SerialNumber===4?$r('app.media.serial4'):
+                this.SerialNumber===5?$r('app.media.serial5'):this.SerialNumber===6?$r('app.media.serial6'):
+                  this.SerialNumber===7?$r('app.media.serial7'):this.SerialNumber===8?$r('app.media.serial8'): '')
+              .width(px2vp(292))
+              .height(px2vp(80))
+              .margin({bottom:px2vp(20)})
+            Row(){
+              Column(){
+                Text(this.SerialNumber.toString()+'#')
+                  .fontSize($r('app.float.fontSize_30'))
+                  .fontWeight(FontWeight.Medium)
+                  .width('100%')
+                  .textAlign(TextAlign.Start)
+                Text('AI测试')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .width('100%')
+                  .fontColor('#666666')
+                  .textAlign(TextAlign.Start)
+              }
+              .width(px2vp(200))
+              Blank()
+              Image($r('app.media.subscript_space'))
+                .height(px2vp(45))
+                .width(px2vp(45))
+
+            }
+            .alignItems(VerticalAlign.Bottom)
+            .width(px2vp(292))
+            .height(px2vp(75))
+          }.width(px2vp(332))
+          .height(px2vp(215))
+          .padding(px2vp(20))
+          .margin({bottom:px2vp(20)})
+          .backgroundColor($r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.dialogController.open()
+          })
+          Column(){
+            Text('配置')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontWeight(FontWeight.Medium)
+              .width('100%')
+              .height(px2vp(60))
+              .textAlign(TextAlign.Start)
+              .margin({bottom:px2vp(10)})
+            Stack(){
+              if (this.OversamplingRate===''){
+                Text('过采样倍率')
+                  .height(px2vp(80))
+                  .width(px2vp(292))
+                  .fontColor($r('app.color.D1D1D1_100'))
+                  .fontSize($r('app.float.fontSize_24'))
+                  .padding({left:px2vp(20)})
+              }
+              Row(){
+                Text(this.OversamplingRate)
+                  .width(px2vp(247))
+                  .height(px2vp(80))
+                  .fontWeight(FontWeight.Medium)
+                  .textAlign(TextAlign.Center)
+                  .fontSize($r('app.float.fontSize_24'))
+                Blank()
+                Column(){
+                  Image($r('app.media.subscript_space'))
+                    .height(px2vp(45))
+                    .width(px2vp(45))
+                }
+                .width(px2vp(45))
+                .height(px2vp(80))
+                .justifyContent(FlexAlign.End)
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+            }.height(px2vp(80))
+            .width(px2vp(292))
+            .borderRadius(px2vp(16))
+            .margin({bottom:px2vp(20)})
+            .border({width:1})
+            .onClick(()=>{
+              this.select=1
+              this.serialPortController.open()
+            })
+
+            Stack(){
+              if (this.SampleRange===''){
+                Text('采样范围')
+                  .height(px2vp(80))
+                  .width(px2vp(292))
+                  .fontColor($r('app.color.D1D1D1_100'))
+                  .fontSize($r('app.float.fontSize_24'))
+                  .padding({left:px2vp(20)})
+              }
+              Row(){
+                Text(this.SampleRange)
+                  .width(px2vp(247))
+                  .height(px2vp(80))
+                  .fontWeight(FontWeight.Medium)
+                  .textAlign(TextAlign.Center)
+                  .fontSize($r('app.float.fontSize_24'))
+                Blank()
+                Column(){
+                  Image($r('app.media.subscript_space'))
+                    .height(px2vp(45))
+                    .width(px2vp(45))
+                }
+                .width(px2vp(45))
+                .height(px2vp(80))
+                .justifyContent(FlexAlign.End)
+              }.height(px2vp(80))
+              .width(px2vp(292))
+
+              .borderRadius(px2vp(16))
+            }.height(px2vp(80))
+            .width(px2vp(292))
+            .borderRadius(px2vp(16))
+            .margin({bottom:px2vp(20)})
+            .border({width:1})
+            .onClick(()=>{
+              this.select=2
+              this.serialPortController.open()
+            })
+
+            Stack(){
+              if (this.samplingFrequency===''){
+                Text('采样频率')
+                  .height(px2vp(80))
+                  .width(px2vp(292))
+                  .fontColor($r('app.color.D1D1D1_100'))
+                  .fontSize($r('app.float.fontSize_24'))
+                  .padding({left:px2vp(20)})
+              }
+              Row(){
+                Text(this.samplingFrequency)
+                  .width(px2vp(247))
+                  .height(px2vp(80))
+                  .fontWeight(FontWeight.Medium)
+                  .textAlign(TextAlign.Center)
+                  .fontSize($r('app.float.fontSize_24'))
+                Blank()
+                Column(){
+                  Image($r('app.media.subscript_space'))
+                    .height(px2vp(45))
+                    .width(px2vp(45))
+                }
+                .width(px2vp(45))
+                .height(px2vp(80))
+                .justifyContent(FlexAlign.End)
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .onClick(()=>{
+                this.select=3
+                this.serialPortController.open()
+              })
+
+            }.height(px2vp(80))
+            .width(px2vp(292))
+            .borderRadius(px2vp(16))
+            .margin({bottom:px2vp(20)})
+            .border({width:1})
+            Button('选择通道')
+              .width(px2vp(292))
+              .height(px2vp(80))
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.white_100'))
+              .backgroundColor($r('app.color.blue_100'))
+              .margin({bottom:px2vp(20)})
+              .onClick(()=>{
+                this.thoroughfareController.open()
+              })
+            List({space:px2vp(5)}){
+              ForEach(this.thoroughfare, (item:thoroughfareClass,index:number) => {
+                if (item.switch===1) {
+                ListItem(){
+                  Row(){
+                      Text(item.number?.toString()+',')
+                        .fontWeight(FontWeight.Medium)
+                        .fontSize($r('app.float.fontSize_24'))
+                        .textAlign(TextAlign.Center)
+                        .borderRadius(px2vp(16))
+                  }
+                  .backgroundColor($r('app.color.white_f1f3f5'))
+                  .borderRadius(px2vp(16))
+                  .justifyContent(FlexAlign.Center)
+                  }
+                }
+
+              })
+            }.lanes(4)
+            .scrollBar(BarState.Off)
+            .width(px2vp(225))
+            .height(px2vp(115))
+            Blank()
+            Button(this.connect===0?'连接':'断开连接')
+              .width(px2vp(292))
+              .height(px2vp(80))
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.white_100'))
+              .backgroundColor(this.connect===0?$r('app.color.green_100'):$r('app.color.red_100'))
+              .margin({bottom:px2vp(20)})
+              .onClick(()=>{
+                if (this.connect===0) {
+                  this.connect=1
+                }else if (this.connect===1){
+                  this.connect=0
+                }
+              })
+            Row(){
+              Text('连接状态')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.gray_6666'))
+                .margin({right:px2vp(20)})
+              Text(this.connect===0?'未连接':'已连接')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.gray_6666'))
+            }
+            .margin({bottom:px2vp(20)})
+
+          }
+          .height(px2vp(725))
+          .borderRadius(px2vp(16))
+          .padding({left:px2vp(20),right:px2vp(20)})
+          .width(px2vp(332))
+          .backgroundColor($r('app.color.white_60'))
+        }.height(px2vp(960))
+        .width(px2vp(332))
+        .borderRadius(px2vp(16))
+        .margin({left:px2vp(60)})
+        .padding({left:px2vp(20),right:px2vp(20)})
+        Column(){
+          Row(){
+            Text('曲线')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .height(px2vp(40))
+              .margin({left:px2vp(24)})
+            .textAlign(TextAlign.Start)
+            Blank()
+            Text('实时数据(V)')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontWeight(FontWeight.Medium)
+              .height(px2vp(40))
+              .margin({right:px2vp(60)})
+              .textAlign(TextAlign.Start)
+          }.width(px2vp(1448))
+          .height(px2vp(60))
+          Row(){
+            Row(){
+              Column(){
+                Text('V')
+                  .fontSize($r('app.float.fontSize_14'))
+                  .fontWeight(FontWeight.Regular)
+                  .fontColor($r('app.color.white_100'))
+                  .height(px2vp(37))
+                  .width(px2vp(60))
+                List(){
+                  ForEach(this.YAxis, (item:number[],index:number) => {
+                    ListItem(){
+                      Text(item.toString())
+                        .fontWeight(FontWeight.Regular)
+                        .fontSize($r('app.float.fontSize_14'))
+                        .fontColor($r('app.color.white_100'))
+                        .height(px2vp(38))
+                    }
+
+                  })
+                }
+                .scrollBar(BarState.Off)
+                .width(px2vp(60))
+                .height(px2vp(800))
+                Text()
+                  .height(px2vp(37))
+
+              }.width(px2vp(60))
+              .margin({left:px2vp(20)})
+              .height(px2vp(872))
+              Column(){
+                Scroll(){
+                  Stack(){
+                    Text()
+                      .borderRadius(px2vp(16))
+                      .width(px2vp(1094))
+                      .height(px2vp(812))
+                      .backgroundColor($r('app.color.black_100'))
+
+                    Polyline({ width: px2vp(10000), height: px2vp(812) })
+                      .points([[0, 0], [30, 100], [120, 120]])
+                      .fillOpacity(0)
+                      .stroke(Color.Blue)
+                      .strokeWidth(2)
+                      .borderRadius(px2vp(16))
+                    Polyline({ width: px2vp(10000), height: px2vp(812) })
+                      .points(this.Axis)
+                      .fillOpacity(0)
+                      .stroke("#F9A01E")
+                      .strokeWidth(3)
+                      .borderRadius(px2vp(16))
+                      .scale({ x: this.scaleValue, y: this.scaleValue, z: 1 })
+                      .gesture(
+                        // 在组件上绑定三指触发的捏合手势
+                        PinchGesture({ fingers: 3 })
+                          .onActionStart((event: GestureEvent|undefined) => {
+                            console.info('Pinch start');
+                          })
+                            // 当捏合手势触发时,可以通过回调函数获取缩放比例,从而修改组件的缩放比例
+                          .onActionUpdate((event: GestureEvent|undefined) => {
+                            if(event){
+                              this.scaleValue = this.pinchValue * event.scale;
+                              this.pinchX = event.pinchCenterX;
+                              this.pinchY = event.pinchCenterY;
+                            }
+                          })
+                          .onActionEnd(() => {
+                            this.pinchValue = this.scaleValue;
+                            console.info('Pinch end');
+                          })
+                      )
+
+                  }
+                  .width(px2vp(10000))
+                  .height(px2vp(812))
+
+
+                } .width(px2vp(1094))
+                .height(px2vp(812))
+                .scrollable(ScrollDirection.Horizontal)
+
+
+
+
+                List(){
+                  ForEach(this.YAxis, (item:number[],index:number) => {
+                    ListItem(){
+                      Text(item.toString())
+                        .fontWeight(FontWeight.Regular)
+                        .fontSize($r('app.float.fontSize_14'))
+                        .fontColor($r('app.color.white_100'))
+                        .width(px2vp(38))
+                    }
+
+                  })
+                }
+                .width(px2vp(1094))
+                .height(px2vp(37))
+                .borderRadius(px2vp(16))
+                .listDirection(Axis.Horizontal)
+
+              }.width(px2vp(1094))
+              .height(px2vp(872))
+
+            }
+            .width(px2vp(1174))
+            .height(px2vp(872))
+            .border({width:1})
+            .margin({right:px2vp(24)})
+            .backgroundColor($r('app.color.black_100'))
+            .borderRadius(px2vp(16))
+            Column(){
+              List({space:px2vp(5)}){
+                ForEach(this.RealTime, (item:RealTimeClass,index:number) => {
+                    ListItem(){
+                      Row(){
+                        Text()
+                          .width(px2vp(20))
+                          .height(px2vp(20))
+                          .borderRadius(px2vp(50))
+                          .backgroundColor(index===0?'#564AF7':index===1?'#8981F7':index===2?'#AC49F5':index===3?'#C386F0':index===4?'#46B1E3'
+                            :index===5?'#61CFBE':index===6?'#64BB5C':index===7?'#BDDB69':index===8?'#A5D61D':index===9?'#F7CE00'
+                              :index===10?'#F9A01E':index===11?'#ED6F21':index===12?'#E87361':index===13?'#E67C92':index===14?'#E64566'
+                                :index===15?'#E84026':'')
+                          .margin({right:px2vp(20)})
+                        Text(item.number?.toString())
+                          .fontWeight(FontWeight.Medium)
+                          .fontSize($r('app.float.fontSize_24'))
+                          .textAlign(TextAlign.Center)
+                          .borderRadius(px2vp(16))
+                          .fontColor(index===0?'#564AF7':index===1?'#8981F7':index===2?'#AC49F5':index===3?'#C386F0':index===4?'#46B1E3'
+                            :index===5?'#61CFBE':index===6?'#64BB5C':index===7?'#BDDB69':index===8?'#A5D61D':index===9?'#F7CE00'
+                              :index===10?'#F9A01E':index===11?'#ED6F21':index===12?'#E87361':index===13?'#E67C92':index===14?'#E64566'
+                                :index===15?'#E84026':'')
+                          .width(px2vp(50))
+                          .margin({right:px2vp(20)})
+                        Text(item.data?.toString())
+                          .fontWeight(FontWeight.Medium)
+                          .fontSize($r('app.float.fontSize_24'))
+                          .textAlign(TextAlign.Center)
+                          .borderRadius(px2vp(16))
+                          .fontColor($r('app.color.white_100'))
+                      }
+                      .height(px2vp(50))
+                      .padding({left:px2vp(20),right:px2vp(20)})
+                      .borderRadius(px2vp(16))
+                      .justifyContent(FlexAlign.Center)
+                    }
+                })
+              }.lanes(1)
+              .scrollBar(BarState.Off)
+              .width(px2vp(194))
+              .height(px2vp(872))
+
+
+
+            }.width(px2vp(194))
+            .height(px2vp(872))
+            .border({width:1})
+            .backgroundColor($r('app.color.black_100'))
+            .borderRadius(px2vp(16))
+          }.width(px2vp(1386))
+          .height(px2vp(872))
+
+        }
+        .width(px2vp(1448))
+        .height(px2vp(960))
+        .borderRadius(px2vp(16))
+        .margin({left:px2vp(24)})
+        .backgroundColor($r('app.color.white_60'))
+
+      }
+      .width(px2vp(1920))
+      .height(px2vp(960))
+      .borderRadius(px2vp(16))
+
+    }
+    .width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.BG_two'))
+  }
+}
+@CustomDialog
+struct serialPort {
+  @Link samplingFrequencyList:samplingFrequencyClass[]
+  @Link samplingFrequency:string
+  @Link SampleRange:string
+  @Link SampleRangeNameList:SampleRangeClass[]
+  @Link select:number
+  @Link OversamplingRate:string
+  @Link serialPort:serialPortClass[]
+  CustomDialogController: CustomDialogController
+  build() {
+    Column(){
+      Text(this.select===1?'过采样倍率':this.select===2?"采样范围":this.select===3?'采样频率':'')
+        .fontSize($r('app.float.fontSize_30'))
+        .fontWeight(FontWeight.Medium)
+        .height(px2vp(60))
+        .margin({bottom:px2vp(20)})
+      if (this.select===1){
+        List({space:px2vp(20)}){
+          ForEach(this.serialPort, (item:serialPortClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.OversamplingRate)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.OversamplingRate=item.OversamplingRate!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }else if (this.select===2){
+        List({space:px2vp(20)}){
+          ForEach(this.SampleRangeNameList, (item:SampleRangeClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.SampleRangeName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.SampleRange=item.SampleRangeName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }else if (this.select===3){
+        List({space:px2vp(20)}){
+          ForEach(this.samplingFrequencyList, (item:samplingFrequencyClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.samplingFrequencyName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.samplingFrequency=item.samplingFrequencyName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }
+
+
+
+
+    }
+    .width(px2vp(700))
+    .height(px2vp(500))
+    .borderRadius(px2vp(16))
+    .backgroundColor($r('app.color.white_100'))
+    .alignItems(HorizontalAlign.Center)
+  }
+
+}
+@CustomDialog
+struct thoroughfare {
+  @Link thoroughfare:thoroughfareClass[]
+  CustomDialogController: CustomDialogController
+  build() {
+    Column(){
+      Text('选择通道')
+        .fontSize($r('app.float.fontSize_30'))
+        .fontWeight(FontWeight.Medium)
+        .height(px2vp(60))
+        .margin({bottom:px2vp(20)})
+      List({space:px2vp(20)}){
+        ForEach(this.thoroughfare, (item:thoroughfareClass,index:number) => {
+          ListItem(){
+            Row(){
+              Toggle({ type: ToggleType.Checkbox,isOn:item.switch===0? false:true })
+                .size({ width: px2vp(40), height: px2vp(40) })
+                .selectedColor('#007DFF')
+                .onClick(() => {
+                  if (item.switch===0) {
+                    this.thoroughfare[index]={
+                      switch:1,
+                      number:this.thoroughfare[index].number
+                    }
+                    console.info('textTag' +JSON.stringify(this.thoroughfare))
+                  }else if (item.switch===1) {
+                    this.thoroughfare[index] = {
+                      switch: 0,
+                      number: this.thoroughfare[index].number
+                    }
+                    console.info('textTag' +JSON.stringify(this.thoroughfare))
+                  }
+                })
+              Text(item.number?.toString())
+                .fontWeight(FontWeight.Medium)
+                .fontSize($r('app.float.fontSize_24'))
+                .width(px2vp(60))
+                .height(px2vp(80))
+                .textAlign(TextAlign.Center)
+                .borderRadius(px2vp(16))
+            }
+            .backgroundColor($r('app.color.white_f1f3f5'))
+            .borderRadius(px2vp(16))
+            .width(px2vp(100))
+            .height(px2vp(80))
+            .justifyContent(FlexAlign.Center)
+            .onClick(() => {
+              if (item.switch===0) {
+                this.thoroughfare[index]={
+                  switch:1,
+                  number:this.thoroughfare[index].number
+                }
+                console.info('textTag' +JSON.stringify(this.thoroughfare))
+              }else if (item.switch===1) {
+                this.thoroughfare[index] = {
+                  switch: 0,
+                  number: this.thoroughfare[index].number
+                }
+                console.info('textTag' +JSON.stringify(this.thoroughfare))
+              }
+            })
+
+          }
+
+        })
+      }.lanes(4)
+      .scrollBar(BarState.Off)
+      .width(px2vp(600))
+      .height(px2vp(400))
+
+
+    } .width(px2vp(700))
+    .height(px2vp(500))
+    .borderRadius(px2vp(16))
+
+    .backgroundColor($r('app.color.white_100'))
+    .alignItems(HorizontalAlign.Center)
+  }
+}
+export class serialPortClass{
+  OversamplingRate?:string
+}
+export class SampleRangeClass{
+  SampleRangeName?:string
+}
+export class samplingFrequencyClass{
+  samplingFrequencyName?:string
+}
+export class stopBitClass{
+  stopBitName?:string
+}
+
+export class checkBitClass{
+  checkBitName?:string
+}
+export class manySendingClass{
+  content?:string
+  switch?:number
+
+}
+export class thoroughfareClass{
+  switch?:number
+  number?:number
+}
+
+export class RealTimeClass{
+  number?:number
+  data?:number
+}
+
+
+
+

+ 987 - 0
entry/src/main/ets/pages/BoardTesting/BoardTesting.ets

@@ -0,0 +1,987 @@
+import router from '@ohos.router'
+import { DeviceDialog } from '../../../commont/component/DeviceDialog'
+@Entry
+@Component
+struct BoardTesting {
+  @State number:number=0
+  controller: TextInputController = new TextInputController()
+  //单条发送
+  @State oneSending:string=''
+  //多条发送选择
+  @State MultipleTransmissions:number=0
+  //连接状态1有,0没有
+  @State connect:number=0
+  //校验位
+  @State checkBit:string=''
+  //数据位
+  @State dataBits:string=''
+  //波特率
+  @State BAUD:string=''
+  @State select:number=0
+  //串口号
+  @State serialPortName: string = '';
+  //停止位
+  @State stopBit:string=''
+  @State private manySendingList:Array<manySendingClass>=[
+    {content:'32845723425345',switch:1},
+    {content:'32845234425345',switch:0},
+    {content:'3282345345',switch:1},
+    {content:'328234234425345',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234524355345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'322423425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234425345',switch:1},
+    {content:'3284523445',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845234425345',switch:0},
+    {content:'3282345345',switch:1},
+    {content:'328234234425345',switch:0},
+    {content:'32845723425345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'3284234524355345',switch:1},
+    {content:'32845723425345',switch:0},
+    {content:'322423425345',switch:1},
+
+
+  ]
+  @State private serialPort:Array<serialPortClass>=[
+    {serialPortName:'串口号1'},
+    {serialPortName:'串口号2'},
+    {serialPortName:'串口号3'},
+    {serialPortName:'串口号4'},
+    {serialPortName:'串口号5'}]
+  @State private checkBitLink:Array<checkBitClass>=[
+    {checkBitName:'校验位1'},
+    {checkBitName:'校验位2'},
+    {checkBitName:'校验位3'},
+    {checkBitName:'校验位4'},
+    {checkBitName:'校验位5'}]
+
+  @State private BAUDNameList:Array<BAUDClass>=[
+    {BAUDName:'波特率1'},
+    {BAUDName:'波特率2'},
+    {BAUDName:'波特率3'},
+    {BAUDName:'波特率4'},
+    {BAUDName:'波特率5'}]
+  @State private dataBitsList:Array<dataBitsClass>=[
+    {dataBitsName:'数据位1'},
+    {dataBitsName:'数据位2'},
+    {dataBitsName:'数据位3'},
+    {dataBitsName:'数据位4'},
+    {dataBitsName:'数据位5'}]
+
+  @State private stopBitList:Array<  stopBitClass>=[
+    {stopBitName:'停止位1'},
+    {stopBitName:'停止位2'},
+    {stopBitName:'停止位3'},
+    {stopBitName:'停止位4'},
+    {stopBitName:'停止位5'}]
+  //0:表示没有,1:表示AI,2:表示串口,3:表示CAN
+  @State select1:number=1
+  //todo 删除
+  @State select2:number=2
+  @State select3:number=3
+  @State select4:number=0
+  @State private Number:number[]=[1,2,3,4,5,6,7,8]
+  private dialogController: CustomDialogController = new CustomDialogController({
+    builder:DeviceDialog({
+      Number:this.Number,
+      select1:this.select1,
+      select2:this.select2,
+      select3:this.select3,
+      select4:this.select4,
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+  serialPortController: CustomDialogController = new CustomDialogController({
+    builder:serialPort({
+      checkBitLink:this.checkBitLink,
+      checkBit:this.checkBit,
+      stopBitList:this.stopBitList,
+      stopBit:this.stopBit,
+      dataBits:this.dataBits,
+      BAUD:this.BAUD,
+      select:this.select,
+      serialPort:this.serialPort,
+      serialPortName:this.serialPortName,
+      BAUDNameList:this.BAUDNameList,
+      dataBitsList:this.dataBitsList
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+  @State SerialNumber:number=0
+  aboutToAppear(): void {
+    const params = router.getParams() as Record<string, number>; // 获取传递过来的参数对象
+    if (params) {
+     this.SerialNumber = params.info as number; // 获取info属性的值
+      console.log("textTag"+this.SerialNumber)
+    }
+
+  }
+  build() {
+      Column() {
+        Row() {
+          Row() {
+            Image($r('app.media.return'))
+              .width(px2vp(48))
+              .height(px2vp(48))
+              .objectFit(ImageFit.Contain)
+              .margin({ left: px2vp(40) })
+          }.width(px2vp(500))
+          .height(px2vp(80))
+          .onClick(() => {
+            router.back();
+          })
+          Blank()
+          Column(){
+            Text('板卡测试')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+              .textAlign(TextAlign.Center)
+              .width(px2vp(608))
+              .height(px2vp(80))
+              .borderRadius($r('app.float.borderRadius_16'))
+          }
+          .justifyContent(FlexAlign.Center)
+          Blank()
+          Row() {
+            Blank()
+            Image($r('app.media.homePage'))
+              .margin({ right: px2vp(40) })
+              .width(px2vp(48))
+              .height(px2vp(48))
+              .onClick(()=>{
+                router.pushUrl({
+                  url:'pages/Index'
+                })
+              })
+            Image($r('app.media.news'))
+              .margin({ right: px2vp(40) })
+              .width(px2vp(48))
+              .height(px2vp(48))
+            Image($r('app.media.personal'))
+              .margin({ right: px2vp(40) })
+              .width(px2vp(48))
+              .height(px2vp(48))
+          }.width(px2vp(500))
+
+        }.width(px2vp(1920))
+        .height(px2vp(80))
+        .alignItems(VerticalAlign.Center)
+        .margin({bottom:px2vp(20)})
+        Row(){
+          Column(){
+            Column(){
+              Image(this.SerialNumber===1?$r('app.media.serial1'):this.SerialNumber===2?$r('app.media.serial2'):
+                this.SerialNumber===3?$r('app.media.serial3'):this.SerialNumber===4?$r('app.media.serial4'):
+                  this.SerialNumber===5?$r('app.media.serial5'):this.SerialNumber===6?$r('app.media.serial6'):
+                    this.SerialNumber===7?$r('app.media.serial7'):this.SerialNumber===8?$r('app.media.serial8'): '')
+                .width(px2vp(292))
+                .height(px2vp(80))
+                .margin({bottom:px2vp(20)})
+              Row(){
+                Column(){
+                  Text(this.SerialNumber.toString()+'#')
+                    .fontSize($r('app.float.fontSize_30'))
+                    .fontWeight(FontWeight.Medium)
+                    .width('100%')
+                    .textAlign(TextAlign.Start)
+                  Text('串口测试')
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Medium)
+                    .width('100%')
+                    .fontColor('#666666')
+                    .textAlign(TextAlign.Start)
+                }
+                .width(px2vp(200))
+                Blank()
+                Image($r('app.media.subscript_space'))
+                  .height(px2vp(45))
+                  .width(px2vp(45))
+
+              }
+              .alignItems(VerticalAlign.Bottom)
+              .width(px2vp(292))
+              .height(px2vp(75))
+            }.width(px2vp(332))
+            .height(px2vp(215))
+            .padding(px2vp(20))
+            .margin({bottom:px2vp(20)})
+            .backgroundColor($r('app.color.white_100'))
+            .borderRadius(px2vp(16))
+            .onClick(()=>{
+              this.dialogController.open()
+            })
+            Column(){
+              Text('配置')
+                .fontSize($r('app.float.fontSize_30'))
+                .fontWeight(FontWeight.Medium)
+                .width('100%')
+                .height(px2vp(60))
+                .textAlign(TextAlign.Start)
+                .margin({bottom:px2vp(10)})
+              Stack(){
+                if (this.serialPortName===''){
+                  Text('选择串口号')
+                    .height(px2vp(80))
+                    .width(px2vp(292))
+                    .fontColor($r('app.color.D1D1D1_100'))
+                    .fontSize($r('app.float.fontSize_24'))
+                    .padding({left:px2vp(20)})
+                }
+                Row(){
+                  Text(this.serialPortName)
+                    .width(px2vp(247))
+                    .height(px2vp(80))
+                    .fontWeight(FontWeight.Medium)
+                    .textAlign(TextAlign.Center)
+                    .fontSize($r('app.float.fontSize_24'))
+                  Blank()
+                  Column(){
+                    Image($r('app.media.subscript_space'))
+                      .height(px2vp(45))
+                      .width(px2vp(45))
+                  }
+                  .width(px2vp(45))
+                  .height(px2vp(80))
+                  .justifyContent(FlexAlign.End)
+                }.height(px2vp(80))
+                .width(px2vp(292))
+                .borderRadius(px2vp(16))
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(20)})
+              .border({width:1})
+              .onClick(()=>{
+                this.select=1
+                this.serialPortController.open()
+              })
+
+              Stack(){
+                if (this.BAUD===''){
+                  Text('选择波特率')
+                    .height(px2vp(80))
+                    .width(px2vp(292))
+                    .fontColor($r('app.color.D1D1D1_100'))
+                    .fontSize($r('app.float.fontSize_24'))
+                    .padding({left:px2vp(20)})
+                }
+                Row(){
+                  Text(this.BAUD)
+                    .width(px2vp(247))
+                    .height(px2vp(80))
+                    .fontWeight(FontWeight.Medium)
+                    .textAlign(TextAlign.Center)
+                    .fontSize($r('app.float.fontSize_24'))
+                  Blank()
+                  Column(){
+                    Image($r('app.media.subscript_space'))
+                      .height(px2vp(45))
+                      .width(px2vp(45))
+                  }
+                  .width(px2vp(45))
+                  .height(px2vp(80))
+                  .justifyContent(FlexAlign.End)
+                }.height(px2vp(80))
+                .width(px2vp(292))
+
+                .borderRadius(px2vp(16))
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(20)})
+              .border({width:1})
+              .onClick(()=>{
+                this.select=2
+                this.serialPortController.open()
+              })
+
+              Stack(){
+                if (this.dataBits===''){
+                  Text('选择数据位')
+                    .height(px2vp(80))
+                    .width(px2vp(292))
+                    .fontColor($r('app.color.D1D1D1_100'))
+                    .fontSize($r('app.float.fontSize_24'))
+                    .padding({left:px2vp(20)})
+                }
+                Row(){
+                  Text(this.dataBits)
+                    .width(px2vp(247))
+                    .height(px2vp(80))
+                    .fontWeight(FontWeight.Medium)
+                    .textAlign(TextAlign.Center)
+                    .fontSize($r('app.float.fontSize_24'))
+                  Blank()
+                  Column(){
+                    Image($r('app.media.subscript_space'))
+                      .height(px2vp(45))
+                      .width(px2vp(45))
+                  }
+                  .width(px2vp(45))
+                  .height(px2vp(80))
+                  .justifyContent(FlexAlign.End)
+                }.height(px2vp(80))
+                .width(px2vp(292))
+                .borderRadius(px2vp(16))
+                .onClick(()=>{
+                  this.select=3
+                  this.serialPortController.open()
+                })
+
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(20)})
+              .border({width:1})
+
+              Stack(){
+                if (this.stopBit===''){
+                  Text('选择停止位')
+                    .height(px2vp(80))
+                    .width(px2vp(292))
+                    .fontColor($r('app.color.D1D1D1_100'))
+                    .fontSize($r('app.float.fontSize_24'))
+                    .padding({left:px2vp(20)})
+                }
+                Row(){
+                  Text(this.stopBit)
+                    .width(px2vp(247))
+                    .height(px2vp(80))
+                    .fontWeight(FontWeight.Medium)
+                    .textAlign(TextAlign.Center)
+                    .fontSize($r('app.float.fontSize_24'))
+                  Blank()
+                  Column(){
+                    Image($r('app.media.subscript_space'))
+                      .height(px2vp(45))
+                      .width(px2vp(45))
+                  }
+                  .width(px2vp(45))
+                  .height(px2vp(80))
+                  .justifyContent(FlexAlign.End)
+                }.height(px2vp(80))
+                .width(px2vp(292))
+
+                .borderRadius(px2vp(16))
+
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(20)})
+              .border({width:1})
+              .onClick(()=>{
+                this.select=4
+                this.serialPortController.open()
+              })
+
+              Stack(){
+                if (this.checkBit===''){
+                  Text('选择校验位')
+                    .height(px2vp(80))
+                    .width(px2vp(292))
+                    .fontColor($r('app.color.D1D1D1_100'))
+                    .fontSize($r('app.float.fontSize_24'))
+                    .padding({left:px2vp(20)})
+                }
+                Row(){
+                  Text(this.checkBit)
+                    .width(px2vp(247))
+                    .height(px2vp(80))
+                    .fontWeight(FontWeight.Medium)
+                    .textAlign(TextAlign.Center)
+                    .fontSize($r('app.float.fontSize_24'))
+                  Blank()
+                  Column(){
+                    Image($r('app.media.subscript_space'))
+                      .height(px2vp(45))
+                      .width(px2vp(45))
+                  }
+                  .width(px2vp(45))
+                  .height(px2vp(80))
+                  .justifyContent(FlexAlign.End)
+                }.height(px2vp(80))
+                .width(px2vp(292))
+
+                .borderRadius(px2vp(16))
+
+              }.height(px2vp(80))
+              .width(px2vp(292))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(20)})
+              .border({width:1})
+              .onClick(()=>{
+                this.select=5
+                this.serialPortController.open()
+              })
+              Blank()
+              Button(this.connect===0?'连接':'断开连接')
+                .width(px2vp(292))
+                .height(px2vp(80))
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.white_100'))
+                .backgroundColor(this.connect===0?$r('app.color.green_100'):$r('app.color.red_100'))
+                .margin({bottom:px2vp(20)})
+                .onClick(()=>{
+                  if (this.connect===0) {
+                    this.connect=1
+                  }else if (this.connect===1){
+                    this.connect=0
+                  }
+                })
+              Row(){
+                Text('连接状态')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.gray_6666'))
+                  .margin({right:px2vp(20)})
+                Text(this.connect===0?'未连接':'已连接')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.gray_6666'))
+              }
+              .margin({bottom:px2vp(20)})
+
+            }
+            .height(px2vp(725))
+            .borderRadius(px2vp(16))
+            .padding({left:px2vp(20),right:px2vp(20)})
+            .width(px2vp(332))
+            .backgroundColor($r('app.color.white_60'))
+
+
+
+
+          }.height(px2vp(960))
+          .width(px2vp(332))
+          .borderRadius(px2vp(16))
+          .margin({left:px2vp(60)})
+          .padding({left:px2vp(20),right:px2vp(20)})
+
+            Column(){
+
+              if (this.MultipleTransmissions===0){
+                Column(){
+                  Row(){
+                    Text('接收区')
+                      .fontSize($r('app.float.fontSize_30'))
+                      .fontWeight(FontWeight.Medium)
+                      .height(px2vp(40))
+                      .textAlign(TextAlign.Start)
+                    Blank()
+                    Text('显示时间')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                    Toggle({ type: ToggleType.Switch, isOn: true })
+                      .width(px2vp(72))
+                      .height(px2vp(40))
+                      .margin({right:px2vp(30)})
+                    Text('HEX显示')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                    Toggle({ type: ToggleType.Switch, isOn: true })
+                      .width(px2vp(72))
+                      .height(px2vp(40))
+                  }.width(px2vp(1398))
+                  .height(px2vp(40))
+                  Column(){
+                    Text('')
+                      .width(px2vp(1398))
+                      .height(px2vp(490))
+                      .textAlign(TextAlign.Start)
+                      .align(Alignment.TopStart)
+                      .padding(px2vp(10))
+                    Row(){
+                      Image($r("app.media.delete1"))
+                        .width(px2vp(48))
+                        .height(px2vp(48))
+                        .margin({right:px2vp(10),bottom:px2vp(10)})
+                    }
+                    .width(px2vp(1398))
+                    .justifyContent(FlexAlign.End)
+
+                  }
+                  .width(px2vp(1398))
+                  .height(px2vp(545))
+                  .backgroundColor($r('app.color.white_100'))
+                  .borderRadius(px2vp(16))
+                  .margin({top:px2vp(20),bottom:px2vp(20)})
+
+                }.width(px2vp(1448))
+                .height(px2vp(648))
+                .padding({left:px2vp(24),right:px2vp(24),top:px2vp(20),bottom:px2vp(20)})
+                .backgroundColor($r('app.color.white_60'))
+                .borderRadius(px2vp(16))
+              }else if (this.MultipleTransmissions===1){
+                Row() {
+                  Column(){
+                    Row(){
+                      Text('接收区')
+                        .fontSize($r('app.float.fontSize_30'))
+                        .fontWeight(FontWeight.Medium)
+                        .height(px2vp(40))
+                        .textAlign(TextAlign.Start)
+                      Blank()
+                      Text('显示时间')
+                        .fontSize($r('app.float.fontSize_24'))
+                        .fontWeight(FontWeight.Medium)
+                        .fontColor($r('app.color.gray_6666'))
+                      Toggle({ type: ToggleType.Switch, isOn: true })
+                        .width(px2vp(72))
+                        .height(px2vp(40))
+                        .margin({right:px2vp(30)})
+                      Text('HEX显示')
+                        .fontSize($r('app.float.fontSize_24'))
+                        .fontWeight(FontWeight.Medium)
+                        .fontColor($r('app.color.gray_6666'))
+                      Toggle({ type: ToggleType.Switch, isOn: true })
+                        .width(px2vp(72))
+                        .height(px2vp(40))
+                    }.width(px2vp(729))
+                    .height(px2vp(40))
+                    Column(){
+                      Text('接收内容')
+                        .width(px2vp(729))
+                        .height(px2vp(490))
+                        .textAlign(TextAlign.Start)
+                        .align(Alignment.TopStart)
+                        .padding(px2vp(10))
+                      Row(){
+                        Image($r("app.media.delete1"))
+                          .width(px2vp(48))
+                          .height(px2vp(48))
+                          .margin({right:px2vp(10),bottom:px2vp(10)})
+                      }
+                      .width(px2vp(729))
+                      .justifyContent(FlexAlign.End)
+
+                    }
+                    .width(px2vp(729))
+                    .height(px2vp(545))
+                    .backgroundColor($r('app.color.white_100'))
+                    .borderRadius(px2vp(16))
+                    .margin({top:px2vp(20),bottom:px2vp(20)})
+
+                  }.width(px2vp(779))
+                  .height(px2vp(648))
+                  .padding({left:px2vp(24),right:px2vp(24),top:px2vp(20),bottom:px2vp(20)})
+                  .backgroundColor($r('app.color.white_60'))
+                  .borderRadius(px2vp(16))
+                  Column(){
+                    Row(){
+                      Text('多条发送区')
+                        .fontSize($r('app.float.fontSize_30'))
+                        .fontWeight(FontWeight.Medium)
+                        .height(px2vp(40))
+                        .textAlign(TextAlign.Start)
+                      Blank()
+                      Text('HEX发送')
+                        .fontSize($r('app.float.fontSize_24'))
+                        .fontWeight(FontWeight.Medium)
+                        .fontColor($r('app.color.gray_6666'))
+                      Toggle({ type: ToggleType.Switch, isOn: true })
+                        .width(px2vp(72))
+                        .height(px2vp(40))
+
+
+                    }
+                    .width(px2vp(602))
+                    .height(px2vp(40))
+                    Column(){
+                      List(){
+                        ForEach(this.manySendingList, (item:manySendingClass,index:number) => {
+                          ListItem(){
+                            Row(){
+                              Row(){
+                                Toggle({ type: ToggleType.Checkbox, isOn: item.switch===1?true:false })
+                                  .size({ width: px2vp(24), height:  px2vp(24) })
+                                  .selectedColor('#007DFF')
+                                  .onChange((isOn: boolean) => {
+                                    console.info('Component status:' + isOn)
+                                  })
+                                  .borderRadius(px2vp(56))
+
+                                Text('命令'+index)
+                                  .fontSize($r('app.float.fontSize_24'))
+                                  .fontWeight(FontWeight.Medium)
+                                  .fontColor($r('app.color.gray_6666'))
+                              }
+                              .backgroundColor($r('app.color.black_10'))
+                              .borderRadius(px2vp(76))
+                              .width(px2vp(130))
+                              .height(px2vp(80))
+                              .onClick(()=>{
+                                if (item.switch===0) {
+                                  this.manySendingList[index]={
+                                    switch:1,
+                                    content:item.content
+                                  }
+
+                                }else if (item.switch===1){
+                                  this.manySendingList[index]={
+                                    switch:0,
+                                    content:item.content
+                                  }
+                                }
+                              })
+                              Blank()
+                              TextInput({ text:item.content ,placeholder:'请输入发送内容', controller: this.controller })
+                                .width(px2vp(469))
+                                .height(px2vp(80))
+                                .border({width:1})
+                                .onChange((value: string) => {
+                                  this.manySendingList[index].content = value
+                                })
+                            }
+                            .borderRadius(px2vp(16))
+                            .width(px2vp(650))
+                            .height(px2vp(80))
+                            .justifyContent(FlexAlign.Center)
+                            .margin({bottom:px2vp(20)})
+                            .padding({left:px2vp(20),right:px2vp(20)})
+                          }
+                        })
+                      }.width(px2vp(650))
+                      .height(px2vp(458))
+                      .scrollBar(BarState.Off)
+                      .margin({left:px2vp(20),right:px2vp(20),bottom:px2vp(10)})
+                      Button('发送')
+                        .width(px2vp(292))
+                        .height(px2vp(80))
+                        .fontSize($r('app.float.fontSize_24'))
+                        .fontWeight(FontWeight.Medium)
+                        .fontColor($r('app.color.white_100'))
+                        .backgroundColor($r('app.color.blue_100'))
+                        .margin({bottom:px2vp(10)})
+                        .onClick(()=>{
+                          for (let index = 0; index < this.manySendingList.length; index++) {
+                            this.manySendingList[index] = {
+                              switch:this.manySendingList[index].switch,
+                              content:this.manySendingList[index].content,
+                            }
+                          }
+                        })
+
+
+                    }
+                    .width(px2vp(650))
+                    .height(px2vp(558))
+                    .margin({top:px2vp(20)})
+
+                  }.width(px2vp(650))
+                  .height(px2vp(648))
+                  .padding({left:px2vp(24),right:px2vp(24),top:px2vp(20),bottom:px2vp(20)})
+                  .backgroundColor($r('app.color.white_60'))
+                  .borderRadius(px2vp(16))
+                  .margin({left:px2vp(20)})
+
+                }.width(px2vp(1448))
+                .height(px2vp(648))
+                .borderRadius(px2vp(16))
+              }
+
+
+              Column(){
+                Row(){
+                  Text('发送区')
+                    .fontSize($r('app.float.fontSize_30'))
+                    .fontWeight(FontWeight.Medium)
+                    .height(px2vp(40))
+                    .textAlign(TextAlign.Start)
+                  Blank()
+                  Text('多条发送')
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Medium)
+                    .fontColor($r('app.color.gray_6666'))
+                  Toggle({ type: ToggleType.Switch, isOn:this.MultipleTransmissions===0?false:true })
+                    .width(px2vp(72))
+                    .height(px2vp(40))
+                    .margin({right:px2vp(30)})
+                    .onChange(()=>{
+                      if (this.MultipleTransmissions===0) {
+                        this.MultipleTransmissions=1
+                      }else if (this.MultipleTransmissions===1) {
+                        this.MultipleTransmissions=0
+                      }
+                    })
+                  Text('HEX发送')
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Medium)
+                    .fontColor($r('app.color.gray_6666'))
+                  Toggle({ type: ToggleType.Switch, isOn: true })
+                    .width(px2vp(72))
+                    .height(px2vp(40))
+                }.width(px2vp(1398))
+                .height(px2vp(40))
+                Row(){
+                  Column(){
+                    TextInput({ text:this.oneSending ,placeholder:'请输入发送内容', controller: this.controller })
+                      .width(px2vp(1299))
+                      .height(px2vp(140))
+                      .textAlign(TextAlign.Start)
+                      .align(Alignment.TopStart)
+                      .padding(px2vp(10))
+                      .borderRadius(px2vp(16))
+                      .backgroundColor($r('app.color.white_100'))
+                    Image($r("app.media.delete1"))
+                      .width(px2vp(48))
+                      .height(px2vp(48))
+                      .margin({right:px2vp(10),bottom:px2vp(10)})
+                  }
+                  .borderRadius(px2vp(16))
+                  .width(px2vp(1299))
+                  .height(px2vp(190))
+                  .alignItems(HorizontalAlign.End)
+                  .backgroundColor($r('app.color.white_100'))
+                  .margin({top:px2vp(20)})
+
+                  Image($r('app.media.sending'))
+                    .width(px2vp(80))
+                    .height(px2vp(80))
+                    .margin({left:px2vp(20),top:px2vp(52)})
+
+
+                }.width(px2vp(1398))
+
+
+
+
+
+              }.width(px2vp(1448))
+              .height(px2vp(292))
+              .borderRadius(px2vp(16))
+              .padding({left:px2vp(24),right:px2vp(24),top:px2vp(20),bottom:px2vp(20)})
+              .backgroundColor($r('app.color.white_60'))
+              .margin({top:px2vp(20)})
+
+            }.width(px2vp(1448))
+            .height(px2vp(960))
+            .borderRadius(px2vp(16))
+            .margin({left:px2vp(24)})
+
+        }
+        .width(px2vp(1920))
+        .height(px2vp(960))
+        .borderRadius(px2vp(16))
+
+      }
+      .width(px2vp(1920))
+      .height(px2vp(1080))
+      .backgroundImage($r('app.media.BG_two'))
+  }
+}
+@CustomDialog
+struct serialPort {
+  @Link checkBit:string
+  @Link checkBitLink:checkBitClass[]
+  @Link stopBit:string
+  @Link stopBitList:stopBitClass[]
+  @Link dataBitsList:dataBitsClass[]
+  @Link dataBits:string
+  @Link BAUD:string
+  @Link BAUDNameList:BAUDClass[]
+  @Link select:number
+  @Link serialPortName:string
+  @Link serialPort:serialPortClass[]
+  CustomDialogController: CustomDialogController
+  build() {
+    Column(){
+      Text(this.select===1?'选择串口号':this.select===2?"选择波特率":this.select===3?'选择数据位':this.select===4?'选择停止位':this.select===5?'选择校验位':'')
+        .fontSize($r('app.float.fontSize_30'))
+        .fontWeight(FontWeight.Medium)
+        .height(px2vp(60))
+        .margin({bottom:px2vp(20)})
+      if (this.select===1){
+        List({space:px2vp(20)}){
+          ForEach(this.serialPort, (item:serialPortClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.serialPortName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.serialPortName=item.serialPortName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }else if (this.select===2){
+        List({space:px2vp(20)}){
+          ForEach(this.BAUDNameList, (item:BAUDClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.BAUDName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.BAUD=item.BAUDName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }else if (this.select===3){
+        List({space:px2vp(20)}){
+          ForEach(this.dataBitsList, (item:dataBitsClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.dataBitsName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.dataBits=item.dataBitsName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }else if (this.select===4){
+        List({space:px2vp(20)}){
+          ForEach(this.stopBitList, (item:stopBitClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.stopBitName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.stopBit=item.stopBitName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }
+      else if (this.select===5){
+        List({space:px2vp(20)}){
+          ForEach(this.checkBitLink, (item:checkBitClass,index:number) => {
+            ListItem(){
+              Row(){
+                Text(item.checkBitName)
+                  .fontWeight(FontWeight.Medium)
+                  .fontSize($r('app.float.fontSize_24'))
+                  .width(px2vp(500))
+                  .height(px2vp(80))
+                  .textAlign(TextAlign.Center)
+                  .borderRadius(px2vp(16))
+                  .onClick(()=>{
+                    this.checkBit=item.checkBitName!
+                    this.CustomDialogController.close()
+                  })
+              }
+              .backgroundColor($r('app.color.white_f1f3f5'))
+              .borderRadius(px2vp(16))
+              .width(px2vp(600))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+
+          })
+        }
+        .scrollBar(BarState.Off)
+        .width(px2vp(600))
+        .height(px2vp(400))
+      }
+
+
+
+
+    }
+    .width(px2vp(700))
+    .height(px2vp(500))
+    .borderRadius(px2vp(16))
+    .backgroundColor($r('app.color.white_100'))
+    .alignItems(HorizontalAlign.Center)
+  }
+}
+export class serialPortClass{
+  serialPortName?:string
+}
+export class BAUDClass{
+  BAUDName?:string
+}
+export class dataBitsClass{
+  dataBitsName?:string
+}
+export class stopBitClass{
+  stopBitName?:string
+}
+
+export class checkBitClass{
+  checkBitName?:string
+}
+export class manySendingClass{
+  content?:string
+  switch?:number
+
+}
+
+

File diff suppressed because it is too large
+ 1145 - 0
entry/src/main/ets/pages/BoardTesting/CanTest.ets


+ 729 - 0
entry/src/main/ets/pages/Device/ElectronicLoad.ets

@@ -0,0 +1,729 @@
+import { TitleComponent } from '../../../commont/component/TitleComponent';
+
+@Entry
+@Component
+struct ElectronicLoad {
+  //端口 1:端口1, 2:端口2, 3:端口3, 4:端口4
+  @State port:number=0
+
+  //   //1:恒压模式,2:恒流 3:恒功率 4:恒电阻
+  @State mode:number=0
+
+  @State resistance:number=0
+  @State power:number=0
+  @State outputState:number=0
+  @State current:number=0
+  @State voltage:number=0
+  controller: TextInputController = new TextInputController()
+  build() {
+    Column() {
+      Stack() {
+        TitleComponent()
+        Text('电子负载')
+          .fontSize($r('app.float.fontSize_30'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.black_100'))
+      }
+
+      Row() {
+        Column({ space: px2vp(20) }) {
+          Text('设备')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(280))
+            .margin({ top: px2vp(20) })
+
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.port===1?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.port=1
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.port===2?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.port=2
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.port===3?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.port=3
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.port===4?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.port=4
+          })
+
+        }
+        .width(px2vp(332))
+        .height(px2vp(960))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+        .margin({ right: px2vp(20) })
+        Column(){
+          Row({space:px2vp(20)}){
+            Row(){
+              Image(this.mode===1?$r('app.media.choice'):$r('app.media.no_Choice'))
+                .width(px2vp(24))
+                .height(px2vp(24))
+                .margin({right:px2vp(10)})
+              Text('恒压模式(CV)')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Start)
+
+            }.width(px2vp(292))
+            .height(px2vp(80))
+            .alignItems(VerticalAlign.Center)
+            .padding({left:px2vp(10),right:px2vp(10)})
+            .borderRadius(px2vp(16))
+            .backgroundColor(this.mode===1?$r('app.color.white_100'):'')
+            .onClick(()=>{
+              this.mode=1
+            })
+            Row(){
+              Image(this.mode===2?$r('app.media.choice'):$r('app.media.no_Choice'))
+                .width(px2vp(24))
+                .height(px2vp(24))
+                .margin({right:px2vp(10)})
+              Text('恒流模式(CC)')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Start)
+
+            }.width(px2vp(292))
+            .height(px2vp(80))
+            .alignItems(VerticalAlign.Center)
+            .backgroundColor(this.mode===2?$r('app.color.white_100'):'')
+            .onClick(()=>{
+              this.mode=2
+            })
+            .padding({left:px2vp(10),right:px2vp(10)})
+            .borderRadius(px2vp(16))
+            Row(){
+              Image(this.mode===3?$r('app.media.choice'):$r('app.media.no_Choice'))
+                .width(px2vp(24))
+                .height(px2vp(24))
+                .margin({right:px2vp(10)})
+              Text('恒功率模式(CW)')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Start)
+
+            }.width(px2vp(292))
+            .height(px2vp(80))
+            .alignItems(VerticalAlign.Center)
+            .backgroundColor(this.mode===3?$r('app.color.white_100'):'')
+            .onClick(()=>{
+              this.mode=3
+            })
+            .padding({left:px2vp(10),right:px2vp(10)})
+            .borderRadius(px2vp(16))
+            Row(){
+              Image(this.mode===4?$r('app.media.choice'):$r('app.media.no_Choice'))
+                .width(px2vp(24))
+                .height(px2vp(24))
+                .margin({right:px2vp(10)})
+              Text('恒电阻模式(CR)')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Start)
+
+            }.width(px2vp(292))
+            .height(px2vp(80))
+
+            .alignItems(VerticalAlign.Center)
+            .padding({left:px2vp(10),right:px2vp(10)})
+            .borderRadius(px2vp(16))
+            .backgroundColor(this.mode===4?$r('app.color.white_100'):'')
+            .onClick(()=>{
+              this.mode=4
+            })
+
+          }
+          .width(px2vp(1448))
+          .height(px2vp(80))
+          .padding({left:px2vp(30),right:px2vp(30)})
+          .margin({bottom:px2vp(20)})
+          Column() {
+            Text('控制')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+              .textAlign(TextAlign.Start)
+              .width(px2vp(1388))
+            Row({space:px2vp(20)}){
+              Column(){
+                Row(){
+                  Image($r('app.media.actual_value'))
+                    .width(px2vp(48))
+                    .height(px2vp(48))
+                  Text('实际值')
+                    .fontSize($r('app.float.fontSize_24'))
+                    .fontWeight(FontWeight.Medium)
+                    .fontColor($r('app.color.black_100'))
+                    .textAlign(TextAlign.Start)
+                    .width(px2vp(280))
+
+                }
+                .width(px2vp(408))
+                .height(px2vp(48))
+                Blank()
+                Column(){
+                  Text('0'+'v')
+                    .fontSize($r('app.float.fontSize_38'))
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.blue_100'))
+                    .textAlign(TextAlign.Start)
+                  Text('实际电压')
+                    .fontSize($r('app.float.fontSize_20'))
+                    .fontWeight(FontWeight.Medium)
+                    .fontColor($r('app.color.blue_20'))
+                    .textAlign(TextAlign.Start)
+
+                }
+                .width(px2vp(408))
+                .height(px2vp(100))
+                Blank()
+                Column(){
+                  Text('0'+'A')
+                    .fontSize($r('app.float.fontSize_38'))
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.blue_100'))
+                    .textAlign(TextAlign.Start)
+                  Text('实际电流')
+                    .fontSize($r('app.float.fontSize_20'))
+                    .fontWeight(FontWeight.Medium)
+                    .fontColor($r('app.color.blue_20'))
+                    .textAlign(TextAlign.Start)
+
+                }
+                .width(px2vp(408))
+                .height(px2vp(100))
+                Blank()
+
+
+              }
+              .width(px2vp(448))
+              .height(px2vp(610))
+              .padding(px2vp(20))
+              .borderRadius(px2vp(16))
+              .backgroundColor($r('app.color.black_10'))
+              Column({space:px2vp(26)}){
+                Column(){
+                  Row(){
+                    Image($r('app.media.voltage'))
+                      .width(px2vp(48))
+                      .height(px2vp(48))
+                    Text('电压')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.black_100'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(280))
+
+                  }
+                  .width(px2vp(408))
+                  .height(px2vp(48))
+                  Blank()
+                  Column(){
+                    Text('设置(v)')
+                      .fontSize($r('app.float.fontSize_20'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(292))
+                    Row(){
+                      Image($r('app.media.add'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          this.voltage++
+                        })
+                      TextInput({ text:this.voltage.toString() , controller: this.controller })
+                        .inputFilter('[(-1)-999]', () => {
+                        })
+                        .type(InputType.Normal)
+                        .enableKeyboardOnFocus(false)
+                        .fontSize($r('app.float.fontSize_38'))
+                        .fontWeight(FontWeight.Bold)
+                        .fontColor($r('app.color.black_100'))
+                        .textAlign(TextAlign.Center)
+                        .width(px2vp(132))
+                        .height(px2vp(80))
+                        .backgroundColor(this.mode===1?$r('app.color.white_100'):'#00000000')
+                        .onChange((value: string) => {
+                          if (Number(value)<999) {
+                            this.voltage=Number(value)
+                          }
+                        })
+                      Image($r('app.media.minus'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          if (this.voltage>0) {
+                            this.voltage--
+                          }
+
+                        })
+                    }.width(px2vp(292))
+                    .height(px2vp(80))
+                    .borderRadius(px2vp(50))
+                    .backgroundColor(this.mode===1?$r('app.color.white_100'):'')
+
+
+
+                  }.width(px2vp(408))
+                  .height(px2vp(100))
+                  .borderRadius(px2vp(16))
+                  .margin({bottom:px2vp(70)})
+                  Blank()
+
+                }
+                .width(px2vp(448))
+                .height(px2vp(292))
+                .padding(px2vp(20))
+                .borderRadius(px2vp(16))
+                .backgroundColor($r('app.color.black_10'))
+
+
+                Column(){
+                  Row(){
+                    Image($r('app.media.power'))
+                      .width(px2vp(48))
+                      .height(px2vp(48))
+                    Text('功率')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.black_100'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(280))
+
+                  }
+                  .width(px2vp(408))
+                  .height(px2vp(48))
+                  Blank()
+                  Column(){
+                    Text('设置(W)')
+                      .fontSize($r('app.float.fontSize_20'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(292))
+                    Row(){
+                      Image($r('app.media.add'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          this.power++
+                        })
+                      TextInput({ text:this.power.toString() , controller: this.controller })
+                        .inputFilter('[(-1)-999]', () => {
+                        })
+                        .type(InputType.Normal)
+                        .enableKeyboardOnFocus(false)
+                        .fontSize($r('app.float.fontSize_38'))
+                        .fontWeight(FontWeight.Bold)
+                        .fontColor($r('app.color.black_100'))
+                        .textAlign(TextAlign.Center)
+                        .width(px2vp(132))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.white_100'))
+                        .onChange((value: string) => {
+                          if (Number(value)<999) {
+                            this.power=Number(value)
+                          }
+                        })
+                      Image($r('app.media.minus'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          if (this.power>0) {
+                            this.power--
+                          }
+
+                        })
+                    }.width(px2vp(292))
+                    .height(px2vp(80))
+                    .borderRadius(px2vp(50))
+                    .backgroundColor($r('app.color.white_100'))
+
+
+
+                  }.width(px2vp(408))
+                  .height(px2vp(100))
+                  .borderRadius(px2vp(16))
+                  .margin({bottom:px2vp(70)})
+                  Blank()
+
+                }
+                .width(px2vp(448))
+                .height(px2vp(292))
+                .padding(px2vp(20))
+                .borderRadius(px2vp(16))
+                .backgroundColor($r('app.color.black_10'))
+
+
+
+              }
+              .width(px2vp(448))
+              .height(px2vp(610))
+              .borderRadius(px2vp(16))
+              Column({space:px2vp(26)}){
+                Column(){
+                  Row(){
+                    Image($r('app.media.current'))
+                      .width(px2vp(48))
+                      .height(px2vp(48))
+                    Text('电流')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.black_100'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(280))
+
+                  }
+                  .width(px2vp(408))
+                  .height(px2vp(48))
+                  Blank()
+                  Column(){
+                    Text('设置(A)')
+                      .fontSize($r('app.float.fontSize_20'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(292))
+                    Row(){
+                      Image($r('app.media.add'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          this.current++
+                        })
+                      TextInput({ text:this.current.toString() , controller: this.controller })
+                        .inputFilter('[(-1)-999]', () => {
+                        })
+                        .type(InputType.Normal)
+                        .enableKeyboardOnFocus(false)
+                        .fontSize($r('app.float.fontSize_38'))
+                        .fontWeight(FontWeight.Bold)
+                        .fontColor($r('app.color.black_100'))
+                        .textAlign(TextAlign.Center)
+                        .width(px2vp(132))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.white_100'))
+                        .onChange((value: string) => {
+                          if (Number(value)<999) {
+                            this.current=Number(value)
+                          }
+                        })
+                      Image($r('app.media.minus'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          if (this.current>0) {
+                            this.current--
+                          }
+
+                        })
+                    }.width(px2vp(292))
+                    .height(px2vp(80))
+                    .borderRadius(px2vp(50))
+                    .backgroundColor($r('app.color.white_100'))
+
+
+
+                  }.width(px2vp(408))
+                  .height(px2vp(100))
+                  .borderRadius(px2vp(16))
+                  .margin({bottom:px2vp(70)})
+                  Blank()
+
+                }
+                .width(px2vp(448))
+                .height(px2vp(292))
+                .padding(px2vp(20))
+                .borderRadius(px2vp(16))
+                .backgroundColor($r('app.color.black_10'))
+                Column(){
+                  Row(){
+                    Image($r('app.media.resistance'))
+                      .width(px2vp(48))
+                      .height(px2vp(48))
+                    Text('电阻')
+                      .fontSize($r('app.float.fontSize_24'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.black_100'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(280))
+
+                  }
+                  .width(px2vp(408))
+                  .height(px2vp(48))
+                  Blank()
+                  Column(){
+                    Text('设置(W)')
+                      .fontSize($r('app.float.fontSize_20'))
+                      .fontWeight(FontWeight.Medium)
+                      .fontColor($r('app.color.gray_6666'))
+                      .textAlign(TextAlign.Start)
+                      .width(px2vp(292))
+                    Row(){
+                      Image($r('app.media.add'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          this.resistance++
+                        })
+                      TextInput({ text:this.resistance.toString() , controller: this.controller })
+                        .inputFilter('[(-1)-999]', () => {
+                        })
+                        .type(InputType.Normal)
+                        .enableKeyboardOnFocus(false)
+                        .fontSize($r('app.float.fontSize_38'))
+                        .fontWeight(FontWeight.Bold)
+                        .fontColor($r('app.color.black_100'))
+                        .textAlign(TextAlign.Center)
+                        .width(px2vp(132))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.white_100'))
+                        .onChange((value: string) => {
+                          if (Number(value)<999) {
+                            this.resistance=Number(value)
+                          }
+                        })
+                      Image($r('app.media.minus'))
+                        .width(px2vp(80))
+                        .height(px2vp(80))
+                        .backgroundColor($r('app.color.black_6'))
+                        .borderRadius(px2vp(100))
+                        .onClick(()=>{
+                          if (this.resistance>0) {
+                            this.resistance--
+                          }
+
+                        })
+                    }.width(px2vp(292))
+                    .height(px2vp(80))
+                    .borderRadius(px2vp(50))
+                    .backgroundColor($r('app.color.white_100'))
+
+
+
+                  }.width(px2vp(408))
+                  .height(px2vp(100))
+                  .borderRadius(px2vp(16))
+                  .margin({bottom:px2vp(70)})
+                  Blank()
+
+                }
+                .width(px2vp(448))
+                .height(px2vp(292))
+                .padding(px2vp(20))
+                .borderRadius(px2vp(16))
+                .backgroundColor($r('app.color.black_10'))
+
+
+
+              }
+              .width(px2vp(448))
+              .height(px2vp(610))
+              .borderRadius(px2vp(16))
+
+
+            }
+            .width(px2vp(1448))
+            .height(px2vp(610))
+            .padding({left:px2vp(30),right:px2vp(30)})
+            Column(){
+              Row(){
+                Text('状态:')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Regular)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Center)
+                  .margin({right:px2vp(5)})
+                Text(this.outputState===1?'开启':this.outputState===2?'关闭':'')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Center)
+              }
+              .width(px2vp(916))
+              .height(px2vp(30))
+              .justifyContent(FlexAlign.Center)
+              Row({space:px2vp(20)}){
+                Button('开启', { type: ButtonType.Normal, stateEffect: true })
+                  .borderRadius(8)
+                  .backgroundColor($r('app.color.green_100'))
+                  .width(px2vp(292))
+                  .borderRadius(px2vp(76))
+                  .height(px2vp(80))
+                  .onClick(()=>{
+                    this.outputState=1
+                  })
+                Button('关闭', { type: ButtonType.Normal, stateEffect: true })
+                  .borderRadius(8)
+                  .backgroundColor($r('app.color.red_100'))
+                  .width(px2vp(292))
+                  .borderRadius(px2vp(76))
+                  .height(px2vp(80))
+                  .onClick(()=>{
+                    this.outputState=2
+                  })
+              } .width(px2vp(650))
+              .height(px2vp(80))
+              .justifyContent(FlexAlign.Center)
+            }
+            .width(px2vp(916))
+            .height(px2vp(110))
+            .margin({top:px2vp(43)})
+          }
+          .width(px2vp(1448))
+          .height(px2vp(862))
+          .padding(px2vp(30))
+          .backgroundColor($r('app.color.white_60'))
+          .borderRadius(px2vp(16))
+        }
+        .width(px2vp(1448))
+        .height(px2vp(960))
+
+
+
+      }.width(px2vp(1920))
+      .height(px2vp(1000))
+      .padding({ top: px2vp(20), bottom: px2vp(20), right: px2vp(60), left: px2vp(60) })
+
+    }.width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.BG_two'))
+  }
+}

+ 236 - 0
entry/src/main/ets/pages/Device/ElectronicMultimeter.ets

@@ -0,0 +1,236 @@
+import { TitleComponent } from '../../../commont/component/TitleComponent';
+
+@Entry
+@Component
+struct ElectronicMultimeter {
+  @State outputState:number=0
+  @State current:number=0
+  @State voltage:number=0
+  controller: TextInputController = new TextInputController()
+  build() {
+    Column() {
+      Stack() {
+        TitleComponent()
+        Text('电子万用表')
+          .fontSize($r('app.float.fontSize_30'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.black_100'))
+      }
+
+      Row() {
+        Column({ space: px2vp(20) }) {
+          Text('设备')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(280))
+            .margin({ top: px2vp(20) })
+
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor('#1a0a59f7')
+          .borderRadius(px2vp(16))
+
+        }
+        .width(px2vp(332))
+        .height(px2vp(960))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+        .margin({ right: px2vp(20) })
+
+        Column() {
+          Text('属性测量')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(1388))
+          Blank()
+          Row({space:px2vp(20)}){
+            Column(){
+              Row(){
+                Image($r('app.media.voltage'))
+                  .width(px2vp(48))
+                  .height(px2vp(48))
+                Text('电压')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(280))
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(48))
+              Blank()
+              Column(){
+                Text('0'+'v')
+                  .fontSize($r('app.float.fontSize_38'))
+                  .fontWeight(FontWeight.Bold)
+                  .fontColor($r('app.color.blue_100'))
+                  .textAlign(TextAlign.Start)
+                Text('实际电压')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.blue_20'))
+                  .textAlign(TextAlign.Start)
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(100))
+              Blank()
+              Button('测量', { type: ButtonType.Normal, stateEffect: true })
+                .borderRadius(8)
+                .backgroundColor($r('app.color.blue_100'))
+                .width(px2vp(292))
+                .borderRadius(px2vp(76))
+                .height(px2vp(80))
+              Blank()
+
+
+            }
+            .width(px2vp(448))
+            .height(px2vp(610))
+            .padding(px2vp(20))
+            .borderRadius(px2vp(16))
+            .backgroundColor($r('app.color.black_10'))
+            Column(){
+              Row(){
+                Image($r('app.media.resistance'))
+                  .width(px2vp(48))
+                  .height(px2vp(48))
+                Text('电阻')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(280))
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(48))
+              Blank()
+              Column(){
+                Text('0'+'Ω')
+                  .fontSize($r('app.float.fontSize_38'))
+                  .fontWeight(FontWeight.Bold)
+                  .fontColor($r('app.color.blue_100'))
+                  .textAlign(TextAlign.Start)
+                Text('实际电阻')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.blue_20'))
+                  .textAlign(TextAlign.Start)
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(100))
+              Blank()
+              Button('测量', { type: ButtonType.Normal, stateEffect: true })
+                .borderRadius(8)
+                .backgroundColor($r('app.color.blue_100'))
+                .width(px2vp(292))
+                .borderRadius(px2vp(76))
+                .height(px2vp(80))
+              Blank()
+            }
+            .width(px2vp(448))
+            .height(px2vp(610))
+            .padding(px2vp(20))
+            .borderRadius(px2vp(16))
+            .backgroundColor($r('app.color.black_10'))
+            Column(){
+              Row(){
+                Image($r('app.media.capacitance'))
+                  .width(px2vp(48))
+                  .height(px2vp(48))
+                Text('电容')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(280))
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(48))
+              Blank()
+              Column(){
+                Text('0'+'μF')
+                  .fontSize($r('app.float.fontSize_38'))
+                  .fontWeight(FontWeight.Bold)
+                  .fontColor($r('app.color.blue_100'))
+                  .textAlign(TextAlign.Start)
+                Text('实际电容')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.blue_20'))
+                  .textAlign(TextAlign.Start)
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(100))
+              Blank()
+              Button('测量', { type: ButtonType.Normal, stateEffect: true })
+                .borderRadius(8)
+                .backgroundColor($r('app.color.blue_100'))
+                .width(px2vp(292))
+                .borderRadius(px2vp(76))
+                .height(px2vp(80))
+              Blank()
+
+            }
+            .width(px2vp(448))
+            .height(px2vp(610))
+            .padding(px2vp(20))
+            .borderRadius(px2vp(16))
+            .backgroundColor($r('app.color.black_10'))
+
+
+          }
+          .width(px2vp(1388))
+          .height(px2vp(610))
+          Blank()
+
+        }
+        .width(px2vp(1448))
+        .height(px2vp(960))
+        .padding(px2vp(30))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+
+      }.width(px2vp(1920))
+      .height(px2vp(1000))
+      .padding({ top: px2vp(20), bottom: px2vp(20), right: px2vp(60), left: px2vp(60) })
+
+    }.width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.BG_two'))
+  }
+}

+ 256 - 0
entry/src/main/ets/pages/Device/PXISwitch.ets

@@ -0,0 +1,256 @@
+import router from '@ohos.router'
+import { TitleComponent } from '../../../commont/component/TitleComponent'
+
+@Entry
+@Component
+struct PXISwitch {
+  @State Thoroughfare1:number=0
+  @State Thoroughfare2:number=0
+  @State Thoroughfare3:number=0
+  @State Thoroughfare4:number=0
+  //点击选择通道变色
+  @State clickBlue:number=-1
+  @State thoroughfare:number[]=[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64]
+  //选择通道1:默认通道1,2:通道2,3:通道3,4:通道四
+  @State selectThoroughfare:number=1
+  @State text: string = "siot2"
+  @State number1: string  ='1'
+  @State index: number = 2
+  @State index1: number = 2
+  @State space: number = 8
+  @State arrowPosition: ArrowPosition = ArrowPosition.END
+  @State arrowPosition1: ArrowPosition = ArrowPosition.END
+  build() {
+    Column(){
+      Stack(){
+        TitleComponent()
+        Text('PXI')
+          .fontSize($r('app.float.fontSize_30'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.black_100'))
+      }
+      Row(){
+        Column({space:px2vp(20)}){
+          Text('板卡')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(280))
+
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Text('1#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Column(){
+              Text(this.Thoroughfare1.toString())
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+              Text('通道')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.selectThoroughfare===1?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.selectThoroughfare=1
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Text('2#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Column(){
+              Text(this.Thoroughfare2.toString())
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+              Text('通道')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.selectThoroughfare===2?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.selectThoroughfare=2
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Text('3#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Column(){
+              Text(this.Thoroughfare3.toString())
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+              Text('通道')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.selectThoroughfare===3?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.selectThoroughfare=3
+          })
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Text('4#')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .fontColor($r('app.color.black_100'))
+            Blank()
+            Column(){
+              Text(this.Thoroughfare4.toString())
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+              Text('通道')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor(this.selectThoroughfare===4?('#1a0a59f7'):$r('app.color.white_100'))
+          .borderRadius(px2vp(16))
+          .onClick(()=>{
+            this.selectThoroughfare=4
+          })
+
+        }
+        .width(px2vp(332))
+        .height(px2vp(960))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+        .margin({right:px2vp(20)})
+        Column(){
+          Text('选择通道')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(1388))
+            .height(px2vp(60))
+          Blank()
+          Column(){
+            Grid() {
+              ForEach(this.thoroughfare, (item:number,index:number) => {
+                GridItem() {
+                  Stack(){
+                    if (this.clickBlue===item) {
+                      Image($r('app.media.number_background_blue'))
+                        .borderRadius(px2vp(50))
+                        .width(px2vp(85))
+                        .height(px2vp(85))
+                    }
+                    Text(item.toString())
+                      .fontWeight(FontWeight.Medium)
+                      .fontSize($r('app.float.fontSize_24'))
+                  }.width(px2vp(85))
+                  .height(px2vp(85))
+                  .borderRadius(px2vp(50))
+                  .onClick(()=>{
+                    this.clickBlue=item
+                    if (this.selectThoroughfare===1) {
+                      this.Thoroughfare1=item
+                    }else if (this.selectThoroughfare===2){
+                      this.Thoroughfare2=item
+                    }else if (this.selectThoroughfare===3){
+                      this.Thoroughfare3=item
+                    }else if (this.selectThoroughfare===4){
+                      this.Thoroughfare4=item
+                    }
+                  })
+
+                }
+              }, (item: string) => item)
+
+            }
+            .width(px2vp(850))
+            .height(px2vp(595))
+          }
+          .width(px2vp(850))
+          .height(px2vp(595))
+          Blank()
+          Button('确认', { type: ButtonType.Capsule, stateEffect: true })
+            .backgroundColor(0x317aff).width(px2vp(292))
+            .height(px2vp(80))
+          Blank()
+
+
+        }
+        .width(px2vp(1448))
+        .height(px2vp(960))
+        .padding(px2vp(30))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+
+
+      }.width(px2vp(1920))
+      .height(px2vp(1000))
+      .padding({top:px2vp(20),bottom:px2vp(20),right:px2vp(60),left:px2vp(60)})
+
+
+    }.width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.BG_two'))
+  }
+}

+ 324 - 0
entry/src/main/ets/pages/Device/ProgrammablePower.ets

@@ -0,0 +1,324 @@
+import { TitleComponent } from '../../../commont/component/TitleComponent';
+
+@Entry
+@Component
+struct ProgrammablePower {
+  @State outputState:number=0
+  @State current:number=0
+  @State voltage:number=0
+  controller: TextInputController = new TextInputController()
+  build() {
+    Column() {
+      Stack() {
+        TitleComponent()
+        Text('程控电源')
+          .fontSize($r('app.float.fontSize_30'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.black_100'))
+      }
+
+      Row() {
+        Column({ space: px2vp(20) }) {
+          Text('设备')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(280))
+            .margin({ top: px2vp(20) })
+
+          Row(){
+            Text()
+              .width(px2vp(20))
+              .height(px2vp(20))
+              .borderRadius(px2vp(200))
+              .backgroundColor($r('app.color.green_100'))
+              .margin({right:px2vp(10)})
+            Column(){
+              Text('192.168.11.123')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(220))
+              Text('端口号')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .width(px2vp(200))
+            }
+            .justifyContent(FlexAlign.Center)
+            .height(px2vp(80))
+            .width(px2vp(220))
+
+
+          }.width(px2vp(292))
+          .height(px2vp(80))
+          .padding({left:px2vp(10),right:px2vp(10)})
+          .backgroundColor('#1a0a59f7')
+          .borderRadius(px2vp(16))
+
+        }
+        .width(px2vp(332))
+        .height(px2vp(960))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+        .margin({ right: px2vp(20) })
+
+        Column() {
+          Text('控制')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .fontColor($r('app.color.black_100'))
+            .textAlign(TextAlign.Start)
+            .width(px2vp(1388))
+          Row({space:px2vp(20)}){
+            Column(){
+              Row(){
+                Image($r('app.media.voltage'))
+                  .width(px2vp(48))
+                  .height(px2vp(48))
+                Text('电压')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(280))
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(48))
+              Blank()
+              Column(){
+                Text('0'+'v')
+                  .fontSize($r('app.float.fontSize_38'))
+                  .fontWeight(FontWeight.Bold)
+                  .fontColor($r('app.color.blue_100'))
+                  .textAlign(TextAlign.Start)
+                Text('实际电压')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.blue_20'))
+                  .textAlign(TextAlign.Start)
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(100))
+              Blank()
+              Column(){
+                Text('设置(v)')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.gray_6666'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(292))
+                Row(){
+                  Image($r('app.media.add'))
+                    .width(px2vp(80))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.black_6'))
+                    .borderRadius(px2vp(100))
+                    .onClick(()=>{
+                      this.voltage++
+                    })
+                  TextInput({ text:this.voltage.toString() , controller: this.controller })
+                    .inputFilter('[(-1)-999]', () => {
+                    })
+                    .type(InputType.Normal)
+                    .enableKeyboardOnFocus(false)
+                    .fontSize($r('app.float.fontSize_38'))
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.black_100'))
+                    .textAlign(TextAlign.Center)
+                    .width(px2vp(132))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.white_100'))
+                    .onChange((value: string) => {
+                      if (Number(value)<999) {
+                        this.voltage=Number(value)
+                      }
+                    })
+                  Image($r('app.media.minus'))
+                    .width(px2vp(80))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.black_6'))
+                    .borderRadius(px2vp(100))
+                    .onClick(()=>{
+                      if (this.voltage>0) {
+                        this.voltage--
+                      }
+
+                    })
+                }.width(px2vp(292))
+                .height(px2vp(80))
+                .borderRadius(px2vp(50))
+                .backgroundColor($r('app.color.white_100'))
+
+
+
+              }.width(px2vp(408))
+              .height(px2vp(100))
+              .borderRadius(px2vp(16))
+             .margin({bottom:px2vp(70)})
+
+            }
+            .width(px2vp(448))
+            .height(px2vp(610))
+            .padding(px2vp(20))
+            .borderRadius(px2vp(16))
+            .backgroundColor($r('app.color.black_10'))
+            Column(){
+              Row(){
+                Image($r('app.media.current'))
+                  .width(px2vp(48))
+                  .height(px2vp(48))
+                Text('电流')
+                  .fontSize($r('app.float.fontSize_24'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.black_100'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(280))
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(48))
+              Blank()
+              Column(){
+                Text('0'+'A')
+                  .fontSize($r('app.float.fontSize_38'))
+                  .fontWeight(FontWeight.Bold)
+                  .fontColor($r('app.color.blue_100'))
+                  .textAlign(TextAlign.Start)
+                Text('实际电流')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.blue_20'))
+                  .textAlign(TextAlign.Start)
+
+              }
+              .width(px2vp(408))
+              .height(px2vp(100))
+              Blank()
+              Column(){
+                Text('设置(A)')
+                  .fontSize($r('app.float.fontSize_20'))
+                  .fontWeight(FontWeight.Medium)
+                  .fontColor($r('app.color.gray_6666'))
+                  .textAlign(TextAlign.Start)
+                  .width(px2vp(292))
+                Row(){
+                  Image($r('app.media.add'))
+                    .width(px2vp(80))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.black_6'))
+                    .borderRadius(px2vp(100))
+                    .onClick(()=>{
+                      this.current++
+                    })
+                  TextInput({ text:this.current.toString() , controller: this.controller })
+                    .inputFilter('[(-1)-999]', () => {
+                    })
+                    .enableKeyboardOnFocus(false)
+                    .fontSize($r('app.float.fontSize_38'))
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.black_100'))
+                    .textAlign(TextAlign.Center)
+                    .width(px2vp(132))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.white_100'))
+                    .onChange((value: string) => {
+                      if (Number(value)<999) {
+                        this.current=Number(value)
+                      }
+                    })
+                  Image($r('app.media.minus'))
+                    .width(px2vp(80))
+                    .height(px2vp(80))
+                    .backgroundColor($r('app.color.black_6'))
+                    .borderRadius(px2vp(100))
+                    .onClick(()=>{
+                      if (this.current>0) {
+                        this.current--
+                      }
+
+                    })
+                }.width(px2vp(292))
+                .height(px2vp(80))
+                .borderRadius(px2vp(50))
+                .backgroundColor($r('app.color.white_100'))
+
+
+
+              }.width(px2vp(408))
+              .height(px2vp(100))
+              .borderRadius(px2vp(16))
+              .margin({bottom:px2vp(70)})
+
+            }
+            .width(px2vp(448))
+            .height(px2vp(610))
+            .padding(px2vp(20))
+            .borderRadius(px2vp(16))
+            .backgroundColor($r('app.color.black_10'))
+
+          }
+          .width(px2vp(916))
+          .height(px2vp(610))
+          Column(){
+            Row(){
+              Text('输入状态:')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontWeight(FontWeight.Regular)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Center)
+                .margin({right:px2vp(5)})
+              Text(this.outputState===1?'正在输出':this.outputState===2?'未输出':'')
+                .fontSize($r('app.float.fontSize_24'))
+                .fontWeight(FontWeight.Medium)
+                .fontColor($r('app.color.black_100'))
+                .textAlign(TextAlign.Center)
+            }
+            .width(px2vp(916))
+            .height(px2vp(30))
+            .justifyContent(FlexAlign.Center)
+            Row({space:px2vp(20)}){
+              Button('输出', { type: ButtonType.Normal, stateEffect: true })
+                .borderRadius(8)
+                .backgroundColor($r('app.color.green_100'))
+                .width(px2vp(292))
+                .borderRadius(px2vp(76))
+                .height(px2vp(80))
+                .onClick(()=>{
+                  this.outputState=1
+                })
+              Button('停止输出', { type: ButtonType.Normal, stateEffect: true })
+                .borderRadius(8)
+                .backgroundColor($r('app.color.red_100'))
+                .width(px2vp(292))
+                .borderRadius(px2vp(76))
+                .height(px2vp(80))
+                .onClick(()=>{
+                  this.outputState=2
+                })
+            } .width(px2vp(650))
+            .height(px2vp(80))
+            .justifyContent(FlexAlign.Center)
+          }
+          .width(px2vp(916))
+          .height(px2vp(110))
+          .margin({top:px2vp(122)})
+        }
+        .width(px2vp(1448))
+        .height(px2vp(960))
+        .padding(px2vp(30))
+        .backgroundColor($r('app.color.white_60'))
+        .borderRadius(px2vp(16))
+
+      }.width(px2vp(1920))
+      .height(px2vp(1000))
+      .padding({ top: px2vp(20), bottom: px2vp(20), right: px2vp(60), left: px2vp(60) })
+
+    }.width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.BG_two'))
+  }
+}

+ 182 - 0
entry/src/main/ets/pages/Device/SwitchMatrix.ets

@@ -0,0 +1,182 @@
+import router from '@ohos.router'
+import { TitleComponent } from '../../../commont/component/TitleComponent'
+
+@Entry
+@Component
+struct SwitchMatrix {
+
+  @State clickGreen:number=1
+  @State clickBlue:number=1
+  private arr: number[] = [1, 2, 3, 4, 5, 6, 7, 8, 9,10,
+    11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27]
+  private oneArr: number[] = [1, 2, 3, 4, 5, 6, 7, 8, 9,10,
+    11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27]
+  build() {
+    Column(){
+      Stack(){
+        TitleComponent()
+        Text('开关矩阵')
+          .fontSize($r('app.float.fontSize_30'))
+          .fontWeight(FontWeight.Medium)
+          .fontColor($r('app.color.black_100'))
+      }
+      Row(){
+        Column(){
+          Text('开关矩阵')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .width('100%')
+            .height(px2vp(30))
+            .textAlign(TextAlign.Start)
+            .margin({bottom:px2vp(24)})
+          Text('输入通道')
+            .fontSize($r('app.float.fontSize_24'))
+            .fontWeight(FontWeight.Medium)
+            .width('100%')
+            .height(px2vp(30))
+            .textAlign(TextAlign.Start)
+            .margin({bottom:px2vp(50)})
+          Row(){
+            Grid() {
+              ForEach(this.arr, (item:number,index:number) => {
+                GridItem() {
+                  Stack(){
+                    if (this.clickGreen===item) {
+                      Image($r('app.media.number_background_green'))
+                    }
+                    Text(item.toString())
+                      .fontSize($r('app.float.fontSize_24'))
+
+                  }.width(px2vp(85))
+                  .height(px2vp(85))
+                  .onClick(()=>{
+                    this.clickGreen=item
+                  })
+                }
+              }, (item: string) => item)
+
+            }
+            .width(px2vp(765))
+            .height(px2vp(255))
+          }.width(px2vp(765))
+          .height(px2vp(255))
+          Text('输出通道')
+            .fontSize($r('app.float.fontSize_24'))
+            .fontWeight(FontWeight.Medium)
+            .width('100%')
+            .height(px2vp(30))
+            .textAlign(TextAlign.Start)
+            .margin({top:px2vp(84)})
+            .margin({bottom:px2vp(33)})
+          Row(){
+            Grid() {
+              ForEach(this.oneArr, (item:number,index:number) => {
+                GridItem() {
+                  Stack(){
+                    if (this.clickBlue===item) {
+                      Image($r('app.media.number_background_blue'))
+                    }
+                    Text(item.toString())
+                      .fontSize($r('app.float.fontSize_24'))
+
+                  }.width(px2vp(85))
+                  .height(px2vp(85))
+                  .onClick(()=>{
+                    this.clickBlue=item
+                  })
+                }
+              }, (item: string) => item)
+
+            }
+            .width(px2vp(765))
+            .height(px2vp(255))
+          }.width(px2vp(765))
+          .height(px2vp(255))
+
+
+        }.width(px2vp(1118))
+        .height(px2vp(900))
+        .padding(px2vp(30))
+        .margin({left:px2vp(60),right:px2vp(40)})
+        .backgroundColor($r('app.color.white_100'))
+        Column(){
+          Text('维修操作终端')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontWeight(FontWeight.Medium)
+            .width('100%')
+            .height(px2vp(35))
+            .textAlign(TextAlign.Start)
+            .margin({bottom:px2vp(60)})
+
+          Column(){
+            Text('当前输入通道')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .width('100%')
+              .height(px2vp(35))
+              .textAlign(TextAlign.Start)
+              .margin({bottom:px2vp(30)})
+            Text(this.clickGreen.toString())
+              .fontSize($r('app.float.fontSize_60'))
+              .fontWeight(FontWeight.Bold)
+              .width('100%')
+              .height(px2vp(60))
+              .textAlign(TextAlign.Center)
+              .margin({bottom:px2vp(24)})
+            Button('设置')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .width(px2vp(292))
+              .height(px2vp(80))
+              .margin({bottom:px2vp(30)})
+          }.width(px2vp(450))
+          .height(px2vp(279))
+          .padding(px2vp(30))
+          .backgroundColor($r('app.color.white_f1f3f5'))
+          .margin({bottom:px2vp(60)})
+          Column(){
+            Text('当前输出通道')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .width('100%')
+              .height(px2vp(35))
+              .textAlign(TextAlign.Start)
+              .margin({bottom:px2vp(30)})
+            Text(this.clickBlue.toString())
+              .fontSize($r('app.float.fontSize_60'))
+              .fontWeight(FontWeight.Bold)
+              .width('100%')
+              .height(px2vp(60))
+              .textAlign(TextAlign.Center)
+              .margin({bottom:px2vp(24)})
+
+            Button('设置')
+              .fontSize($r('app.float.fontSize_24'))
+              .fontWeight(FontWeight.Medium)
+              .width(px2vp(292))
+              .height(px2vp(80))
+              .margin({bottom:px2vp(30)})
+
+          }.width(px2vp(450))
+          .height(px2vp(279))
+          .padding(px2vp(30))
+          .backgroundColor($r('app.color.white_f1f3f5'))
+          .margin({bottom:px2vp(60)})
+
+
+        }
+        .padding(px2vp(30))
+        .width(px2vp(642))
+        .height(px2vp(900))
+        .margin({left:px2vp(60)})
+        .backgroundColor($r('app.color.white_100'))
+        .margin({right:px2vp(60)})
+
+      }.width(px2vp(1920))
+      .height(px2vp(900))
+      .margin({top:px2vp(60),bottom:px2vp(40)})
+    }.width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundColor($r('app.color.white_f1f3f5'))
+  }
+}

+ 164 - 0
entry/src/main/ets/pages/Index.ets

@@ -0,0 +1,164 @@
+import { DataManagement } from '../view/DataManagement'
+import { DetectingSystem } from '../view/DetectingSystem'
+import { DeviceManagement } from '../view/DeviceManagement'
+import { OperationTerminal } from '../view/OperationTerminal'
+import process from '@ohos.process'
+
+@Entry
+@Component
+struct Index {
+  @State clickSelect:number=0
+  build() {
+    Column() {
+      Row(){
+        Image($r('app.media.logo'))
+          .width(px2vp(210))
+          .height(px2vp(50))
+          .objectFit(ImageFit.Contain)
+          .margin({left:px2vp(40)})
+        Blank()
+        Image($r('app.media.homePage'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+        Image($r('app.media.news'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+        Image($r('app.media.personal'))
+          .margin({right:px2vp(40)})
+          .width(px2vp(48))
+          .height(px2vp(48))
+          .onClick(()=>{
+            let pro = new process.ProcessManager();
+            pro.exit(0);
+          })
+      }.width(px2vp(1920))
+      .height(px2vp(80))
+      .alignItems(VerticalAlign.Center)
+      Row(){
+        Column(){
+            Column(){
+              Text('本地设备管理')
+                .fontSize($r('app.float.fontSize_30'))
+                .fontColor(this.clickSelect==0?'#FFFF':'#1a1a1a')
+                .fontWeight(FontWeight.Medium)
+              Text('PAC控制仪器仪表')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontColor(this.clickSelect==0?'#FFFF':'#666666')
+                .fontWeight(FontWeight.Regular)
+            }.width(px2vp(542))
+            .height(px2vp(186))
+            .padding({left:px2vp(30)})
+            .borderRadius(px2vp(8))
+            .alignItems(HorizontalAlign.Start)
+            .justifyContent(FlexAlign.Center)
+            .backgroundImage(this.clickSelect===0?$r('app.media.device_management_black'):$r('app.media.device_management'))
+            .onClick(()=>{
+              this.clickSelect=0
+            })
+            Column(){
+              Text('维修检测系统')
+                .fontSize($r('app.float.fontSize_30'))
+                .fontColor(this.clickSelect==1?$r('app.color.white_100'):'#1a1a1a')
+                .fontWeight(FontWeight.Medium)
+              Text('鸿蒙电子测试系统')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontColor(this.clickSelect==1?$r('app.color.white_100'):'#666666')
+                .fontWeight(FontWeight.Regular)
+
+
+            }.width(px2vp(542))
+            .height(px2vp(186))
+            .alignItems(HorizontalAlign.Start)
+            .justifyContent(FlexAlign.Center)
+            .padding({left:px2vp(30)})
+            .borderRadius(px2vp(8))
+            .margin({top:px2vp(30)})
+            .backgroundImage(this.clickSelect===1?$r('app.media.detecting_system_black'):$r('app.media.detecting_system'))
+            .onClick(()=>{
+              this.clickSelect=1
+            })
+
+            Column(){
+              Text('维修操作终端')
+                .fontSize($r('app.float.fontSize_30'))
+                .fontColor(this.clickSelect==2?$r('app.color.white_100'):'#1a1a1a')
+                .fontWeight(FontWeight.Medium)
+              Text('维修功能子系统')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontColor(this.clickSelect==2?$r('app.color.white_100'):'#666666')
+                .fontWeight(FontWeight.Regular)
+            }.width(px2vp(542))
+            .height(px2vp(186))
+            .margin({top:px2vp(30)})
+            .alignItems(HorizontalAlign.Start)
+            .justifyContent(FlexAlign.Center)
+            .padding({left:px2vp(30)})
+            .borderRadius(px2vp(8))
+            .backgroundImage(this.clickSelect===2?$r('app.media.operation_terminal_black'):$r('app.media.operation_terminal'))
+            .onClick(()=>{
+              this.clickSelect=2
+            })
+
+            Column(){
+              Text('维修数据管理')
+                .fontSize($r('app.float.fontSize_30'))
+                .fontColor(this.clickSelect==3?$r('app.color.white_100'):'#1a1a1a')
+                .fontWeight(FontWeight.Medium)
+              Text('维修进度与结果查询')
+                .fontSize($r('app.float.fontSize_20'))
+                .fontColor(this.clickSelect==3?$r('app.color.white_100'):'#666666')
+                .fontWeight(FontWeight.Regular)
+
+
+            }.width(px2vp(542))
+            .height(px2vp(186))
+            .alignItems(HorizontalAlign.Start)
+            .justifyContent(FlexAlign.Center)
+            .padding({left:px2vp(30)})
+            .borderRadius(px2vp(8))
+            .margin({top:px2vp(30)})
+            .backgroundImage(this.clickSelect===3?$r('app.media.data_management_black'):$r('app.media.data_management'))
+            .onClick(()=>{
+              this.clickSelect=3
+            })
+
+
+
+
+        }.width(px2vp(542))
+        .height(px2vp(900))
+        .margin({left:px2vp(60),right:px2vp(40)})
+
+        Image($r('app.media.midline')).width(px2vp(40))
+        .height(px2vp(900))
+
+        if (this.clickSelect===0){
+          //本地设备管理
+
+          DeviceManagement()
+        }else if(this.clickSelect===1){
+          //维修检测系统
+          DetectingSystem()
+        }
+        else if(this.clickSelect===2){
+          //维修操作终端
+          OperationTerminal()
+        }
+        else if(this.clickSelect===3){
+          //维修数据管理
+          DataManagement()
+        }
+
+
+      }.width(px2vp(1920))
+      .height(px2vp(900))
+      .margin({top:px2vp(60),bottom:$r('app.float.topMargins_20')})
+    }
+    .padding({bottom:$r('app.float.topMargins_20')})
+    .width(px2vp(1920))
+    .height(px2vp(1080))
+    .backgroundImage($r('app.media.background'))
+  }
+}

File diff suppressed because it is too large
+ 1604 - 0
entry/src/main/ets/pages/PanelMaintenanceInspection.ets


File diff suppressed because it is too large
+ 1792 - 0
entry/src/main/ets/pages/PowerDetection.ets


File diff suppressed because it is too large
+ 1680 - 0
entry/src/main/ets/pages/RFtesting.ets


+ 60 - 0
entry/src/main/ets/view/DataManagement.ets

@@ -0,0 +1,60 @@
+//维修数据管理
+@Component
+export struct DataManagement {
+  @State clickSelect:number=0
+  build() {
+    Column(){
+      Row(){
+        Column(){
+          Text('维修总体进度')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r('app.media.maintenance_progress'))
+        .margin({right:px2vp(40),left:px2vp(30)})
+        Column(){
+          Text('维修过程统计')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40)})
+        .backgroundImage($r('app.media.maintenance_statistics'))
+        Column(){
+          Text('维修详细履历')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r('app.media.maintenance_record'))
+
+      }.width(px2vp(1178))
+      .height(px2vp(900))
+      .margin({right:px2vp(60),left:px2vp(30)})
+      .margin({bottom:px2vp(40)})
+    }
+    .width(px2vp(1178))
+    .height(px2vp(900))
+
+  }
+}

+ 81 - 0
entry/src/main/ets/view/DetectingSystem.ets

@@ -0,0 +1,81 @@
+//维修检测系统
+import router from '@ohos.router'
+
+@Component
+export struct DetectingSystem {
+  @State clickSelect:number=0
+  build() {
+    Column(){
+      Row(){
+        Column(){
+          Text('射频类维修检测系统')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40),left:px2vp(30)})
+        .backgroundImage($r('app.media.radio_frequency_detection'))
+        .onClick(()=>{
+          router.pushUrl({
+            url:'pages/RFtesting'
+          })
+        })
+        Column(){
+          Text('电源类维修检测系统')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r('app.media.power_detection'))
+        .margin({right:px2vp(40)})
+        .onClick(()=>{
+          router.pushUrl({
+            url:'pages/PowerDetection'
+          })
+        })
+
+
+        Column(){
+          Text('面板类维修检测系统')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r('app.media.panel_detection'))
+        .onClick(()=>{
+          router.pushUrl({
+            url:'pages/PanelMaintenanceInspection'
+          })
+        })
+
+      }.width(px2vp(1178))
+      .height(px2vp(900))
+      .margin({right:px2vp(60),left:px2vp(30)})
+      .margin({bottom:px2vp(40)})
+    }
+    .width(px2vp(1178))
+    .height(px2vp(900))
+
+  }
+}

+ 177 - 0
entry/src/main/ets/view/DeviceManagement.ets

@@ -0,0 +1,177 @@
+//本地设备管理
+import { DeviceDialog } from '../../commont/component/DeviceDialog'
+import router from '@ohos.router'
+@Component
+export struct DeviceManagement {
+  //0:表示没有,1:表示AI,2:表示串口,3:表示CAN
+  @State select1:number=1
+  //todo 删除
+  @State select2:number=2
+  @State select3:number=3
+  @State select4:number=0
+  @State private Number:number[]=[1,2,3,4,5,6,7,8]
+  scroller: Scroller = new Scroller()
+  @State clickStatus:number=0
+  private dialogController: CustomDialogController = new CustomDialogController({
+    builder:DeviceDialog({
+      Number:this.Number,
+      select1:this.select1,
+      select2:this.select2,
+      select3:this.select3,
+      select4:this.select4,
+    }),
+    alignment: DialogAlignment.Center,
+    customStyle:true,
+    autoCancel:true,
+  })
+
+  build() {
+    Scroll(this.scroller){
+      Column(){
+        Row(){
+          Column(){
+            Text('开关矩阵')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+
+
+          }.width(this.clickStatus===1?px2vp(335):px2vp(356))
+          .height(this.clickStatus===1?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .backgroundColor(Color.White)
+          .margin({right:px2vp(40),left:px2vp(30)})
+          .backgroundImage($r('app.media.switch_matrix'))
+          .onClick(()=>{
+            this.clickStatus=1
+            router.pushUrl({
+              url:'pages/Device/SwitchMatrix'
+            })
+          })
+          Column(){
+            Text('程控电源')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+
+
+          }.width(this.clickStatus===2?px2vp(335):px2vp(356))
+          .height(this.clickStatus===2?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .backgroundColor(Color.White)
+          .margin({right:px2vp(40)})
+          .backgroundImage($r('app.media.source'))
+          .onClick(()=>{
+            this.clickStatus=2
+            router.pushUrl({
+              url:'pages/Device/ProgrammablePower'
+            })
+          })
+          Column(){
+            Text('电子负载')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+
+
+          }.width(this.clickStatus===3?px2vp(335):px2vp(356))
+          .height(this.clickStatus===3?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .backgroundImage($r('app.media.electronic_load'))
+          .onClick(()=>{
+            this.clickStatus=3
+            router.pushUrl({
+              url:'pages/Device/ElectronicLoad'
+            })
+          })
+
+        }.width(px2vp(1178))
+        .height(px2vp(356))
+        .margin({right:px2vp(60),left:px2vp(30)})
+        .margin({bottom:px2vp(40)})
+        Row(){
+          Column(){
+            Text('板卡测试')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+          }.width(this.clickStatus===7?px2vp(335):px2vp(356))
+          .height(this.clickStatus===7?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .backgroundImage($r('app.media.board_testing'))
+          .margin({right:px2vp(40),left:px2vp(30)})
+          .onClick(()=>{
+            this.clickStatus=7
+            this.dialogController.open()
+          })
+          Column(){
+            Text('电子万用表')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+
+
+          }.width(this.clickStatus===5?px2vp(335):px2vp(356))
+          .height(this.clickStatus===5?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .margin({right:px2vp(40)})
+          .backgroundImage($r('app.media.electronic_universal_meter'))
+          .onClick(()=>{
+            this.clickStatus=5
+            router.pushUrl({
+              url:'pages/Device/ElectronicMultimeter'
+            })
+          })
+          Column(){
+            Text('PXI开关')
+              .fontSize($r('app.float.fontSize_30'))
+              .fontColor('#1a1a1a')
+              .fontWeight(FontWeight.Medium)
+              .textAlign(TextAlign.Start)
+              .width('100%')
+
+
+          }.width(this.clickStatus===6?px2vp(335):px2vp(356))
+          .height(this.clickStatus===6?px2vp(335):px2vp(356))
+          .padding(px2vp(30))
+          .borderRadius($r('app.float.borderRadius_16'))
+          .backgroundImage($r('app.media.PXI_switch'))
+          .onClick(()=>{
+            this.clickStatus=6
+            router.pushUrl({
+              url:'pages/Device/PXISwitch'
+            })
+          })
+
+        }.width(px2vp(1178))
+        .height(px2vp(356))
+        .margin({right:px2vp(60),left:px2vp(30)})
+        .margin({bottom:px2vp(40)})
+
+      }
+      .width(px2vp(1178))
+      .height(px2vp(1256))
+    }
+    .scrollable(ScrollDirection.Vertical)
+    .width(px2vp(1178))
+    .height(px2vp(900))
+    .scrollBar(BarState.Off)
+
+
+  }
+}

+ 114 - 0
entry/src/main/ets/view/OperationTerminal.ets

@@ -0,0 +1,114 @@
+//维修操作终端
+@Component
+export struct OperationTerminal {
+  @State clickSelect:number=0
+  build() {
+    Column(){
+      Row(){
+        Column(){
+          Text('系统勘验')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40),left:px2vp(30)})
+        .backgroundImage($r('app.media.system_inspection'))
+        Column(){
+          Text('维修执行')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40)})
+        .backgroundImage($r('app.media.maintenance_execution'))
+        Column(){
+          Text('修后检验')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r("app.media.post_repair_inspection"))
+
+      }.width(px2vp(1178))
+      .height(px2vp(356))
+      .margin({right:px2vp(60),left:px2vp(30)})
+      .margin({bottom:px2vp(40)})
+      Row(){
+        Column(){
+          Text('物料申领')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40),left:px2vp(30)})
+        .backgroundImage($r("app.media.post_repair_inspection"))
+        Column(){
+          Text('试验申请')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .margin({right:px2vp(40)})
+        .backgroundImage($r('app.media.trial_application'))
+        Column(){
+          Text('电子图档')
+            .fontSize($r('app.float.fontSize_30'))
+            .fontColor('#1a1a1a')
+            .fontWeight(FontWeight.Medium)
+            .textAlign(TextAlign.Start)
+            .width('100%')
+
+
+        }.width(px2vp(356))
+        .height(px2vp(356))
+        .padding(px2vp(30))
+        .borderRadius($r('app.float.borderRadius_16'))
+        .backgroundImage($r('app.media.electronic_image_file'))
+
+      }.width(px2vp(1178))
+      .height(px2vp(356))
+      .margin({right:px2vp(60),left:px2vp(30)})
+      .margin({bottom:px2vp(40)})
+    }
+    .width(px2vp(1178))
+    .height(px2vp(900))
+
+  }
+}

+ 37 - 0
entry/src/main/module.json5

@@ -0,0 +1,37 @@
+{
+  "module": {
+    "name": "entry",
+    "type": "entry",
+    "description": "$string:module_desc",
+    "mainElement": "EntryAbility",
+    "deviceTypes": [
+      "default",
+      "tablet"
+    ],
+    "deliveryWithInstall": true,
+    "installationFree": false,
+    "pages": "$profile:main_pages",
+    "abilities": [
+      {
+        "name": "EntryAbility",
+        "srcEntry": "./ets/entryability/EntryAbility.ets",
+        "description": "$string:EntryAbility_desc",
+        "icon": "$media:jg_icon",
+        "label": "$string:EntryAbility_label",
+        "startWindowIcon": "$media:jg_icon",
+        "startWindowBackground": "$color:start_window_background",
+        "exported": true,
+        "skills": [
+          {
+            "entities": [
+              "entity.system.home"
+            ],
+            "actions": [
+              "action.system.home"
+            ]
+          }
+        ]
+      }
+    ]
+  }
+}

+ 98 - 0
entry/src/main/resources/base/element/color.json

@@ -0,0 +1,98 @@
+{
+  "color": [
+    {
+      "name": "start_window_background",
+      "value": "#FFFFFF"
+    },
+    {
+      "name": "black_100",
+      "value": "#000000"
+    },
+    {
+      "name": "black_10",
+      "value": "#1a000000"
+    },
+    {
+      "name": "black_90",
+      "value": "#e6000000"
+    },
+    {
+      "name": "black_60",
+      "value": "#99000000"
+    },
+    {
+      "name": "grey_100",
+      "value": "#D9DBDD"
+    },
+    {
+      "name": "green_100",
+      "value": "#64BB5C"
+    },
+    {
+      "name": "brown_100",
+      "value": "#E84026"
+    },
+    {
+      "name": "blue_100",
+      "value": "#0A59F7"
+    },
+    {
+      "name": "blue_20",
+      "value": "#330a59f7"
+    },
+    {
+      "name": "white_E3E5E7",
+      "value": "#E3E5E7"
+    },
+    {
+      "name": "white_f1f3f5",
+      "value": "#F1F3F5"
+    },
+    {
+      "name": "Green_64BB5C",
+      "value": "#64BB5C"
+    },
+    {
+      "name": "black_6",
+      "value": "#0f000000"
+    },
+    {
+      "name": "Green_20",
+      "value": "#3364BB5C"
+    },
+    {
+      "name": "pale_blue_background_color",
+      "value": "#D5E7D6"
+    },
+    {
+      "name": "disable_grey_background_color",
+      "value": "#D9DBDD"
+    },
+    {
+      "name": "white_100",
+      "value": "#FFFFFF"
+    },
+    {
+      "name": "gray_6666",
+      "value": "#666666"
+    },
+    {
+      "name": "red_100",
+      "value": "#E84026"
+    }
+   ,
+    {
+      "name": "gray_979797",
+      "value": "#979797"
+    },
+    {
+      "name": "white_60",
+      "value": "#99ffffff"
+    },
+    {
+      "name": "D1D1D1_100",
+      "value": "#D1D1D1"
+    }
+
+  ]
+}

+ 21 - 0
entry/src/main/resources/base/element/float.json

@@ -0,0 +1,21 @@
+{
+  "float": [
+    {
+      "name": "borderRadius_16",
+      "value": "6.4vp"
+    },
+    {
+      "name": "topMargins_20",
+      "value": "13.3vp"
+    },
+    {
+      "name": "leftMargins_30",
+      "value": "20vp"
+    },
+    {
+      "name": "Margins_24",
+      "value": "13.3vp"
+    }
+
+  ]
+}

+ 32 - 0
entry/src/main/resources/base/element/font_size.json

@@ -0,0 +1,32 @@
+{
+  "float": [
+    {
+      "name": "fontSize_24",
+      "value": "16fp"
+    },
+    {
+      "name": "fontSize_38",
+      "value": "25.3fp"
+    },
+    {
+      "name": "fontSize_20",
+      "value": "13.3fp"
+    },
+    {
+      "name": "fontSize_30",
+      "value": "20fp"
+    },
+    {
+      "name": "fontSize_14",
+      "value": "9.3fp"
+    },
+    {
+      "name": "fontSize_50",
+      "value": "33fp"
+    },
+    {
+      "name": "fontSize_60",
+      "value": "40fp"
+    }
+  ]
+}

+ 17 - 0
entry/src/main/resources/base/element/string.json

@@ -0,0 +1,17 @@
+{
+  "string": [
+    {
+      "name": "module_desc",
+      "value": "module description"
+    },
+    {
+      "name": "EntryAbility_desc",
+      "value": "description"
+    },
+    {
+      "name": "EntryAbility_label",
+      "value": "晶格"
+    }
+
+  ]
+}

BIN
entry/src/main/resources/base/media/BG_two.png


BIN
entry/src/main/resources/base/media/PXI_switch.png


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/actual_value.svg


+ 3 - 0
entry/src/main/resources/base/media/add.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M15.9993 2.6665C16.7357 2.6665 17.3327 3.26346 17.3327 3.99984V27.9998C17.3327 28.7362 16.7357 29.3332 15.9993 29.3332C15.263 29.3332 14.666 28.7362 14.666 27.9998V17.3332H3.99935C3.26297 17.3332 2.66602 16.7362 2.66602 15.9998C2.66602 15.2635 3.26297 14.6665 3.99935 14.6665H14.666V3.99984C14.666 3.26346 15.263 2.6665 15.9993 2.6665ZM27.9993 14.6665C28.7357 14.6665 29.3327 15.2635 29.3327 15.9998C29.3327 16.7362 28.7357 17.3332 27.9993 17.3332H18.6647V14.6665H27.9993Z" fill="black"/>
+</svg>

BIN
entry/src/main/resources/base/media/background.png


BIN
entry/src/main/resources/base/media/board_testing.png


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/capacitance.svg


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/choice.svg


BIN
entry/src/main/resources/base/media/click_image.png


File diff suppressed because it is too large
+ 5 - 0
entry/src/main/resources/base/media/current.svg


BIN
entry/src/main/resources/base/media/data_management.png


BIN
entry/src/main/resources/base/media/data_management_black.png


BIN
entry/src/main/resources/base/media/delete.png


+ 6 - 0
entry/src/main/resources/base/media/delete1.svg

@@ -0,0 +1,6 @@
+<svg width="48" height="48" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg">
+<circle cx="24" cy="24" r="24" fill="#1A1A1A" fill-opacity="0.1"/>
+<path d="M34.6654 24H13.332V36H34.6654V24Z" stroke="#666666" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M10.668 16.6667H20.0013V12H28.0013V16.6667H37.3346V24H10.668V16.6667Z" stroke="#666666" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
+<path d="M18.668 29.334V36.0007" stroke="#666666" stroke-width="2.66667" stroke-linecap="round"/>
+</svg>

BIN
entry/src/main/resources/base/media/detecting_system.png


BIN
entry/src/main/resources/base/media/detecting_system_black.png


BIN
entry/src/main/resources/base/media/device_management.png


BIN
entry/src/main/resources/base/media/device_management_black.png


BIN
entry/src/main/resources/base/media/electronic_image_file.png


BIN
entry/src/main/resources/base/media/electronic_load.png


BIN
entry/src/main/resources/base/media/electronic_universal_meter.png


BIN
entry/src/main/resources/base/media/enter_background.png


File diff suppressed because it is too large
+ 13 - 0
entry/src/main/resources/base/media/home.svg


BIN
entry/src/main/resources/base/media/homePage.png


BIN
entry/src/main/resources/base/media/jg_icon.png


BIN
entry/src/main/resources/base/media/logo.png


BIN
entry/src/main/resources/base/media/lower.png


BIN
entry/src/main/resources/base/media/maintenance_execution.png


BIN
entry/src/main/resources/base/media/maintenance_progress.png


BIN
entry/src/main/resources/base/media/maintenance_record.png


BIN
entry/src/main/resources/base/media/maintenance_statistics.png


BIN
entry/src/main/resources/base/media/midline.png


+ 3 - 0
entry/src/main/resources/base/media/minus.svg

@@ -0,0 +1,3 @@
+<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
+<path d="M30 16.3333C30 17.0697 29.403 17.6667 28.6667 17.6667L4.66667 17.6667C3.93029 17.6667 3.33333 17.0697 3.33333 16.3333C3.33333 15.597 3.93029 15 4.66667 15L28.6667 15C29.403 15 30 15.597 30 16.3333Z" fill="black"/>
+</svg>

BIN
entry/src/main/resources/base/media/news.png


+ 22 - 0
entry/src/main/resources/base/media/no_Choice.svg

@@ -0,0 +1,22 @@
+<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g filter="url(#filter0_b_244_699)">
+<path d="M24 12C24 18.6274 18.6274 24 12 24C5.37258 24 0 18.6274 0 12C0 5.37258 5.37258 0 12 0C18.6274 0 24 5.37258 24 12Z" fill="white"/>
+</g>
+<g filter="url(#filter1_b_244_699)">
+<path fill-rule="evenodd" clip-rule="evenodd" d="M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22ZM12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z" fill="#979797"/>
+</g>
+<defs>
+<filter id="filter0_b_244_699" x="-13.5914" y="-13.5914" width="51.1828" height="51.1828" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
+<feFlood flood-opacity="0" result="BackgroundImageFix"/>
+<feGaussianBlur in="BackgroundImageFix" stdDeviation="6.7957"/>
+<feComposite in2="SourceAlpha" operator="in" result="effect1_backgroundBlur_244_699"/>
+<feBlend mode="normal" in="SourceGraphic" in2="effect1_backgroundBlur_244_699" result="shape"/>
+</filter>
+<filter id="filter1_b_244_699" x="-13.5914" y="-13.5914" width="51.1828" height="51.1828" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
+<feFlood flood-opacity="0" result="BackgroundImageFix"/>
+<feGaussianBlur in="BackgroundImageFix" stdDeviation="6.7957"/>
+<feComposite in2="SourceAlpha" operator="in" result="effect1_backgroundBlur_244_699"/>
+<feBlend mode="normal" in="SourceGraphic" in2="effect1_backgroundBlur_244_699" result="shape"/>
+</filter>
+</defs>
+</svg>

BIN
entry/src/main/resources/base/media/number_backbround_gray.png


BIN
entry/src/main/resources/base/media/number_background_blue.png


BIN
entry/src/main/resources/base/media/number_background_green.png


BIN
entry/src/main/resources/base/media/operation_terminal.png


BIN
entry/src/main/resources/base/media/operation_terminal_black.png


BIN
entry/src/main/resources/base/media/oscilloscope.png


BIN
entry/src/main/resources/base/media/panel_detection.png


BIN
entry/src/main/resources/base/media/personal.png


BIN
entry/src/main/resources/base/media/post_repair_inspection.png


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/power.svg


BIN
entry/src/main/resources/base/media/power_detection.png


BIN
entry/src/main/resources/base/media/radio_frequency_detection.png


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/resistance.svg


File diff suppressed because it is too large
+ 3 - 0
entry/src/main/resources/base/media/return.svg


+ 5 - 0
entry/src/main/resources/base/media/sending.svg

@@ -0,0 +1,5 @@
+<svg width="80" height="80" viewBox="0 0 80 80" fill="none" xmlns="http://www.w3.org/2000/svg">
+<circle cx="40" cy="40" r="40" fill="#0A59F7"/>
+<path d="M58 22L20 36.1383L40 40.0083L45.0052 60L58 22Z" stroke="white" stroke-width="2.75" stroke-linejoin="round"/>
+<path d="M40.0078 40.0084L45.6646 34.3516" stroke="white" stroke-width="2.75" stroke-linecap="round" stroke-linejoin="round"/>
+</svg>

BIN
entry/src/main/resources/base/media/serial1.png


BIN
entry/src/main/resources/base/media/serial2.png


BIN
entry/src/main/resources/base/media/serial3.png


BIN
entry/src/main/resources/base/media/serial4.png


BIN
entry/src/main/resources/base/media/serial5.png


BIN
entry/src/main/resources/base/media/serial6.png


BIN
entry/src/main/resources/base/media/serial7.png


BIN
entry/src/main/resources/base/media/serial8.png


BIN
entry/src/main/resources/base/media/source.png


BIN
entry/src/main/resources/base/media/startIcon.png


+ 4 - 0
entry/src/main/resources/base/media/stop.svg

@@ -0,0 +1,4 @@
+<svg width="80" height="80" viewBox="0 0 80 80" fill="none" xmlns="http://www.w3.org/2000/svg">
+<circle cx="40" cy="40" r="40" fill="#0A59F7"/>
+<path d="M24 27C24 25.3431 25.3431 24 27 24H53C54.6569 24 56 25.3431 56 27V53C56 54.6569 54.6569 56 53 56H27C25.3431 56 24 54.6569 24 53V27Z" fill="white"/>
+</svg>

+ 10 - 0
entry/src/main/resources/base/media/subscript_space.svg

@@ -0,0 +1,10 @@
+<svg width="38" height="38" viewBox="0 0 38 38" fill="none" xmlns="http://www.w3.org/2000/svg">
+<g clip-path="url(#clip0_150_424)">
+<path d="M18 16V2.82843C18 1.04662 15.8457 0.154282 14.5858 1.41421L1.41421 14.5858C0.154284 15.8457 1.04662 18 2.82843 18H16C17.1046 18 18 17.1046 18 16Z" fill="black" fill-opacity="0.1"/>
+</g>
+<defs>
+<clipPath id="clip0_150_424">
+<rect width="38" height="38" fill="white"/>
+</clipPath>
+</defs>
+</svg>

BIN
entry/src/main/resources/base/media/switch_matrix.png


BIN
entry/src/main/resources/base/media/system_inspection.png


BIN
entry/src/main/resources/base/media/trial_application.png


+ 0 - 0
entry/src/main/resources/base/media/upper.png


Some files were not shown because too many files changed in this diff