Pico Communications PicoScope 2104 manual Visual Basic, Delphi, Excel, Agilent VEE, LabVIEW

Page 28

26

PicoScope 2104 & 2105 PC Oscilloscope User Guide

3.6.2Visual Basic

The Win32\ subdirectory contains the following files:

ps2000.vbp - project file ps2000.bas - procedure prototypes ps2000.frm - form and program

Note: The functions that return a TRUE/FALSE value return 0 for FALSE and 1 for TRUE, whereas Visual Basic expects 65 535 for TRUE. To avoid this problem, check for > 0 rather than = TRUE.

3.6.3Delphi

The program ps2000.dpr demonstrates how to operate PicoScope 2000 Series PC Oscilloscopes. The file ps2000.inc contains procedure prototypes that you can include in your own programs. Other required files include ps2000.res, ps2000fm.dfm and ps2000fm.pas. This has been tested with Delphi version 3.

3.6.4Excel

1.Load the spreadsheet ps2000.xls

2.Select Tools Macro

3.Select GetData

4.Select Run

Note: The Excel Macro language is similar to Visual Basic. The functions which return

aTRUE/FALSE value, return 0 for FALSE and 1 for TRUE, whereas Visual Basic expects 65 535 for TRUE. Check for > 0 rather than = TRUE.

3.6.5Agilent VEE

The example function ps2000.vee is in the drivers\ subdirectory. It uses procedures that are defined in ps2000.vh. It was tested using Agilent VEE version 5.

3.6.6LabVIEW

The ps2000.vi example in the Drivers\Win32\ subdirectory shows how to access the driver functions using LabVIEW. It was tested using version 6.1 of LabVIEW for Windows. To use the example, copy these files to your LabVIEW directory:

ps2000.vi

open_unit.vi

set_channel.vi

setup_data_collection.vi

You will also need

ps2000.dll

from the Drivers\ subdirectory.

PS2100044-1.0

Copyright 2006 Pico Technology Limited. All rights reserved.

Image 28
Contents PicoScope 2104 Table of Contents Safety symbols IntroductionOverview IntroductionSafety warning FCC noticeCE notice Licence conditionsWarranty TrademarksCompany details AddressProduct information Minimum system requirementsInstallation instructions Checking the installationInput connector Connectors and controlsSpecifications Technical reference Driver error codesDriver 1 ps2000closeunit Functions2 ps2000flashled 3 ps2000gettimebase 4 ps2000gettimesandvalues 5 ps2000getunitinfo Information returned Example6 ps2000getvalues 7 ps2000lastbuttonpress8 ps2000openunit 9 ps2000readyPs2000runblock 11 ps2000runstreaming Ps2000setchannel Code Enumeration Range13 ps2000setets Ps2000settrigger 15 ps2000stopMore on block mode Advanced featuresSampling modes More on streaming mode TriggeringETS Equivalent Time Sampling Voltage ranges7 AC/DC operation OversamplingScaling Reading VoltageCombining oscilloscopes Using different modes Using block modeUsing streaming mode Using ETS modeProgramming 1 CGUI example Console exampleVisual Basic DelphiExcel Agilent VEETroubleshooting Software error codesGlossary Real-time continuous mode Streaming modeGlossary PicoScope software TimebaseIndex ETSIndex USBInterworld Electronics & Computers Inc