云题海 - 专业文章范例文档资料分享平台

当前位置:首页 > 2013-生物传感器实验1-第九组-论文

2013-生物传感器实验1-第九组-论文

  • 62 次阅读
  • 3 次下载
  • 2026/4/27 9:21:46

2013-生物传感器实验1-第九组-论文

Dim DataValue As Integer

Dim HighResEngUnits As Double Dim EngUnits As Single

' Collect the data with cbAIn()

' Parameters:

' BoardNum :the number used by CB.CFG to describe this board ' Chan :the input channel number ' CBRange :the Range for the board.

' DataValue :the name for the value collected

Chan = Val(TxtNumChan.Text) ' set input channel If (Chan > MaxChan) Then Chan = MaxChan TxtNumChan.Text = Format(Chan, \ Options = 0 ' this is ignored

If ADResolution > 16 Then

ULStat = cbAIn32(BoardNum, Chan, CBRange, DataValue32, Options) If ULStat <> 0 Then Stop

ULStat = cbToEngUnits32(BoardNum, CBRange, DataValue32, HighResEngUnits) If ULStat <> 0 Then Stop

lblShowData.Caption = Format$(DataValue32, \

lblShowVolts.Caption = Format$(HighResEngUnits#, \voltage

Else

ULStat = cbAIn(BoardNum, Chan, CBRange, DataValue) If ULStat <> 0 Then Stop

ULStat = cbToEngUnits(BoardNum, CBRange, DataValue, EngUnits) If ULStat <> 0 Then Stop

lblShowData.Caption = Format$(DataValue, \

lblShowVolts.Caption = Format$(EngUnits!, \ End If

data(i) = Format$(EngUnits!, \采集y轴的数据

Print #1, i, \将采集到的数据存储到csv文件中 If (i > 0) Then '绘制曲线 Pic.DrawStyle = 0 Pic.DrawWidth = 1

Pic.Line (TimeCount - 1 - mult * 100, data(i - 1))-(TimeCount - mult * 100, data(i)) End If i = i + 1

TimeCount = TimeCount + 1

If i - 1 = m Then '曲线绘制到最右端时,往左移动横轴1/5的距离

m = m + 100 mult = mult + 1

lcall (m) '调用lcall子程序 End If

End Sub

Private Sub lcall(m As Integer) '定义lcall子程序 Pic.Cls '清屏

第 9 页 共 9 页

2013-生物传感器实验1-第九组-论文

Pic.DrawWidth = 1

For X = 0 To 500 Step 100 '画x轴

Pic.DrawStyle = 3 '设置曲线宽度 Pic.Line (X, -4)-(X, 4) Next X

For Y = -4 To 4 '画y轴 Pic.Line (500, Y)-(0, Y) Next Y

x1.Caption = 10 + mult * 10 '定义各坐标显示的数字 x2.Caption = 20 + mult * 10 x3.Caption = 30 + mult * 10 x4.Caption = 40 + mult * 10 x5.Caption = 50 + mult * 10

a0 = 0

For a = i - 400 To i '清屏之后重新绘制横轴4/5的曲线

Pic.Line (a0, data(a))-(a0 + 1, data(a + 1)) a0 = a0 + 1 Next a End Sub

Private Sub CmdSave_Click() '改变的线条的颜色 CommonDialog1.ShowColor

Pic.ForeColor = CommonDialog1.Color End Sub

Private Sub pic_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single) '显示鼠标指针的坐标

If X > 0 And X < 500 And Y > -4 And Y < 4 Then

frmDataDisplay.Caption = \细菌生长曲线( X=\秒 Y=\+ Str(Y) + \伏 )\

End If End Sub

Private Sub Compause_Click() '使能端,控制数据采集的开断 If tmrConvert.Enabled = True Then tmrConvert.Enabled = False Compause.Caption = \继续\ Else

tmrConvert.Enabled = True Compause.Caption = \暂停\ End If End Sub

Private Sub cmdStopConvert_Click() '数据采集结束 tmrConvert.Enabled = False End End Sub

第 10 页 共 10 页

搜索更多关于: 2013-生物传感器实验1-第九组-论文 的文档
  • 收藏
  • 违规举报
  • 版权认领
下载文档10.00 元 加入VIP免费下载
推荐下载
本文作者:...

共分享92篇相关文档

文档简介:

2013-生物传感器实验1-第九组-论文 Dim DataValue As Integer Dim HighResEngUnits As Double Dim EngUnits As Single ' Collect the data with cbAIn() ' Parameters: ' BoardNum :the number used by CB.CFG to describe this board ' Chan :the input channel number ' CBRange :the Range for the board. ' DataValue :th

× 游客快捷下载通道(下载后可以自由复制和排版)
单篇付费下载
限时特价:10 元/份 原价:20元
VIP包月下载
特价:29 元/月 原价:99元
低至 0.3 元/份 每月下载150
全站内容免费自由复制
VIP包月下载
特价:29 元/月 原价:99元
低至 0.3 元/份 每月下载150
全站内容免费自由复制
注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信:fanwen365 QQ:370150219
Copyright © 云题海 All Rights Reserved. 苏ICP备16052595号-3 网站地图 客服QQ:370150219 邮箱:370150219@qq.com