📄 waveviewer.frm
字号:
Appearance = 0 'Flat
BackColor = &H80000005&
BorderStyle = 1 'Fixed Single
ForeColor = &H80000008&
Height = 255
Left = 3600
TabIndex = 11
Top = 480
Width = 975
End
Begin VB.Label t1_t2
Alignment = 2 'Center
Appearance = 0 'Flat
BackColor = &H80000005&
BorderStyle = 1 'Fixed Single
ForeColor = &H80000008&
Height = 255
Left = 3600
TabIndex = 10
Top = 240
Width = 975
End
End
Begin VB.CommandButton savedata
Caption = "存储数据"
Height = 255
Left = 3720
TabIndex = 8
Top = 3520
Width = 950
End
Begin VB.ListBox scantime1
Height = 240
ItemData = "waveviewer.frx":0CCA
Left = 960
List = "waveviewer.frx":0CEC
TabIndex = 6
Tag = "0"
Top = 3480
Width = 1215
End
Begin VB.Frame Frame2
Caption = "通道2"
Height = 855
Left = 2400
TabIndex = 5
Top = 3720
Width = 2295
Begin VB.ListBox bv
Height = 240
ItemData = "waveviewer.frx":0D2D
Left = 960
List = "waveviewer.frx":0D70
TabIndex = 49
Top = 240
Width = 1215
End
Begin VB.ListBox b_y
Height = 240
ItemData = "waveviewer.frx":0DF5
Left = 960
List = "waveviewer.frx":0E38
TabIndex = 48
Top = 480
Width = 1215
End
Begin VB.Label Label23
Alignment = 2 'Center
Caption = "Y轴漂移量"
Height = 255
Left = 10
TabIndex = 33
Top = 480
Width = 950
End
Begin VB.Label Label22
Alignment = 2 'Center
Caption = "档位调节"
Height = 255
Left = 120
TabIndex = 32
Top = 240
Width = 735
End
End
Begin VB.Frame Frame1
Caption = "通道1"
Height = 855
Left = 0
TabIndex = 4
Top = 3720
Width = 2175
Begin VB.ListBox a_y
Height = 240
ItemData = "waveviewer.frx":0E87
Left = 960
List = "waveviewer.frx":0ECA
TabIndex = 31
Top = 480
Width = 1215
End
Begin VB.ListBox av
Height = 240
ItemData = "waveviewer.frx":0F19
Left = 960
List = "waveviewer.frx":0F5C
TabIndex = 28
Top = 240
Width = 1215
End
Begin VB.Label Label21
Alignment = 2 'Center
Caption = "Y轴漂移量"
Height = 255
Left = 10
TabIndex = 30
Top = 480
Width = 950
End
Begin VB.Label Label20
Alignment = 2 'Center
Caption = "档位调节"
Height = 255
Left = 120
TabIndex = 29
Top = 240
Width = 735
End
End
Begin VB.CommandButton setup
Caption = ">>配置示波器>>"
Height = 2415
Left = 4440
TabIndex = 3
Top = 0
Width = 255
End
Begin VB.Timer Timer1
Enabled = 0 'False
Interval = 50
Left = 3480
Tag = "0"
Top = 3600
End
Begin VB.HScrollBar HScroll1
Enabled = 0 'False
Height = 255
LargeChange = 1000
Left = 0
TabIndex = 2
Top = 2160
Value = 100
Width = 4455
End
Begin VB.PictureBox table
Appearance = 0 'Flat
AutoRedraw = -1 'True
BackColor = &H00FFFFFF&
ForeColor = &H80000008&
Height = 2175
Left = 0
ScaleHeight = 2145
ScaleWidth = 4365
TabIndex = 0
Top = 0
Width = 4400
Begin VB.PictureBox paper
Appearance = 0 'Flat
AutoRedraw = -1 'True
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 2000
Left = 0
ScaleHeight = 1965
ScaleWidth = 2.45715e5
TabIndex = 1
Top = 120
Width = 2.45745e5
Begin VB.Line vline
BorderColor = &H80000004&
Index = 0
X1 = 0
X2 = 0
Y1 = 0
Y2 = 1920
End
Begin VB.Line hline
BorderColor = &H80000004&
Index = 0
X1 = 0
X2 = 4200
Y1 = 0
Y2 = 0
End
Begin VB.Line Line2
BorderColor = &H00FF00FF&
X1 = 840
X2 = 840
Y1 = 0
Y2 = 1920
End
Begin VB.Line Line1
BorderColor = &H00FF0000&
X1 = 1680
X2 = 1680
Y1 = 0
Y2 = 1920
End
End
Begin VB.Image M2
Height = 150
Left = 840
MousePointer = 9 'Size W E
Picture = "waveviewer.frx":0FE1
Stretch = -1 'True
Top = 0
Width = 150
End
Begin VB.Image M1
Height = 150
Left = 1680
MousePointer = 9 'Size W E
Picture = "waveviewer.frx":16E3
Stretch = -1 'True
Top = 0
Width = 150
End
End
Begin VB.Label Label24
Caption = $"waveviewer.frx":1DE5
Height = 1455
Left = 4800
TabIndex = 34
Top = 0
Width = 735
WordWrap = -1 'True
End
Begin VB.Label Label13
Caption = "扫描频率"
Height = 255
Left = 120
TabIndex = 7
Top = 3480
Width = 855
End
End
Attribute VB_Name = "waveviewer"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Declare Function SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal X As Long, ByVal Y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long) As Long
Dim retvalue As Long
Private hMenu As Long
'------------------
Dim oldx As Single
'------------------
Public Tcounts As Integer ''to dedine a variable to memory the circle times
Public dett As Double
Dim operating As Integer
Dim tempvalue As Long
Dim tempvolt() As Single
Dim t0, v01, v02 As Single
Dim scantype As Integer
Dim papercounts As Integer
Dim aroad As wave
Dim broad As wave
Dim ymat(20) As Single
Dim vmat(20) As Single
Dim time_divmat(21) As Single
Dim time_div As Single
Dim flag As Integer
Private Sub a_y_Scroll()
aroad.n_y = ymat(a_y.TopIndex)
If operating = 1 Then
Call drawwave(1)
End If
End Sub
Public Sub a0_Change()
If CInt(a0.Text) < nodecounts And CInt(a0.Text) >= 0 Then
aroad.n0 = CInt(a0.Text)
Else
MsgBox ("请准确输入节点号!N<=" + Str(nodecounts - 1))
a0.Text = aroad.n0
End If
End Sub
Public Sub a1_Change()
If CInt(a1.Text) < nodecounts And CInt(a1.Text) >= 0 Then
aroad.n1 = CInt(a1.Text)
Else
MsgBox ("请准确输入节点号!N<=" + Str(nodecounts - 1))
a1.Text = aroad.n1
End If
End Sub
Private Sub av_Scroll()
aroad.n_v = vmat(av.TopIndex)
If operating = 1 Then
Call drawwave(1)
End If
End Sub
Private Sub b_y_Scroll()
broad.n_y = ymat(b_y.TopIndex)
If operating = 1 Then
Call drawwave(1)
End If
End Sub
Public Sub b0_Change()
If CInt(b0.Text) < nodecounts And CInt(b0.Text) >= 0 Then
broad.n0 = CInt(b0.Text)
Else
MsgBox ("请准确输入节点号!N<=" + Str(nodecounts - 1))
b0.Text = broad.n0
End If
End Sub
Public Sub b1_Change()
If CInt(b1.Text) < nodecounts And CInt(b1.Text) >= 0 Then
broad.n1 = CInt(b1.Text)
Else
MsgBox ("请准确输入节点号!N<=" + Str(nodecounts - 1))
b1.Text = broad.n1
End If
End Sub
Private Sub bv_Scroll()
broad.n_v = vmat(bv.TopIndex)
If operating = 1 Then
Call drawwave(1)
End If
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -