LabVIEW MATP

MATP 介绍

  1. 《SplashScreen》MATP 的引导是以 VB6.0 进行编写,VB6.0 开发的引导界面,主要是小巧,可以快速启动
  2. 《LV_Main》LabVIEW 为测试主体语言,LV_Main 中的 MyLib 为个人积累的库文件,界面可缩放,后期可支持多语言!
    MATP 是一个基于 LabVIEW 的多功能自动测试平台,支持 4UUT,10 个测试项目并行运行!
    MATP 的 debug 是一个基于 LabVIEW 的调试平台,完善中
    LabVIEW 的源代码密码为:tosobright@gmail.com
  3. 《WebSite》asp.net(vb.net)为网页 web 查看数据开发语言
  4. 《WebServer_cassinidev-94877》开源 webserver 进行的二次开发 web 服务器,可替代 IIS
  5. 《FlowCollect》B4A 为 android APP 开发语言,有一 Demo,包含数据库连接,规划中
  6. 使用者需使用 SQLSERVER 数据库,如无数据库,可以安装 sqlexpress,数据库可参考本人的数据库连接
  7. 《USER.sql》SQLSERVER User Table 创建 SQL 语句
  8. APP 文件夹为打包后的程序,可直接运行,但需注册 msadodc.ocx、mswinsck.ocx,安装 LabVIEW2016 RunTime,.net4.0.

SplashScreen

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
65
66
67
Select Case Num_TimeSelect
Case 0 '注册信息确认
GetHardwareInfo
GetMachineSN
Lbl_LoadInfo.Caption = "RegInfo Comfirm..."
''''''''''RegForm.Show
On Error Resume Next
Shell "taskkill /f /im " & "MATP.exe"
Shell "taskkill /f /im MATPDebug.exe"
Shell "taskkill /f /im matpwebserver.exe"
Tcpserver

Case 1 '数据库参数确认,并连接数据库
Lbl_LoadInfo.Caption = "Connect Database..."
waitms 200
Timer1.Enabled = False

Dim inipath As String
inipath = App.path + "\data\config.ini"
On Error GoTo inifile
SQL_Server = GetPrivateStringValue("SQLSERVER", "ServerPar.Server", inipath)
SQL_Server = Replace(SQL_Server, "\\", "\")
SQL_DB = GetPrivateStringValue("SQLSERVER", "ServerPar.Database", inipath)
SQL_User = GetPrivateStringValue("SQLSERVER", "ServerPar.User", inipath)
SQL_Pwd = GetPrivateStringValue("SQLSERVER", "ServerPar.Pwd", inipath)
SQL_Port = GetPrivateStringValue("SQLSERVER", "ServerPar.Port", inipath)

If SQL_Server = "" Or SQL_DB = "" Or SQL_User = "" Or SQL_Pwd = "" Then
Database.Show
Exit Sub
End If

Dim SQL_ConnectStr As String
SQL_ConnectStr = "provider=SQLOlEDB.1;persist security info= false;uid=" + SQL_User + ";pwd=" + SQL_Pwd + ";Initial Catalog=" + SQL_DB + ";Data Source=" + SQL_Server

Dim sqlcon As New ADODB.Connection
On Error GoTo sqlerr
sqlcon.Open SQL_ConnectStr

sqlcon.Close

Timer1.Enabled = True

Case 2 '启动主程序
Lbl_LoadInfo.Caption = "MATP Loading..."
Timer1.Enabled = False
APPstart "\MATP.exe"
waitms 500

Case 3 '启动调试程序
Lbl_LoadInfo.Caption = "DebugServer Loading..."
Timer1.Enabled = False
APPstart "\MATPDebug.exe"
waitms 500
TcpClient.Connect

Case 4 '启动webserver
Lbl_LoadInfo.Caption = "MatpWebServer Loading..."
Timer1.Enabled = False
APPstart "\matpwebserver.exe"
Shell "taskkill /f /im MATPDebug.exe"

Case 5 '显示主界面
Lbl_LoadInfo.Caption = "MatpShow"
TcpClient.SendData "S"

End Select

LV_Main

LabVIEW 开发测试主体程序

WebSite

采用的是 asp.net

APP

采用 B4A

优化

不更新

建议

现在最好是采用前后端分离的方式

  • 后端提供 RestfulAPI,可以使用 Python 或者 Java
  • 前端使用 vue.js
  • APP 使用 HTML5 或者 uni-app 这类
坚持原创技术分享,您的支持将鼓励我继续创作!