PICO picoscope 3204 Скачать руководство пользователя страница 31

Technical reference

30

Copyright 2005 Pico Technology Limited. All rights reserved.

PS3000044 1.4

3.6

Programming

3.6.1

C

There are two C example programs: one is a simple GUI application, and the other is a
more comprehensive console mode program that demonstrates all of the facilities of the
driver.

The GUI example program is a generic Windows application - that is, it does not use
Borland AppExpert or Microsoft AppWizard. To compile the program, create a new project
for an Application containing the following files:

ps3000.c

;

ps3000.rc

; and

ps3000bc.lib

(Borland 32-bit applications); or

ps3000.lib

(Microsoft Visual C 32-bit applications)

The following files must be in the compilation directory:

ps3000.rch

;

ps3000.h

;

and the following file must be in the same directory as the executable.

ps3000.dll

The console example program is a generic windows application - that is, it does not use
Borland AppExpert or Microsoft AppWizard. To compile the program, create a new project
for an Application containing the following files:

ps3000con.c

; and

ps3000bc.lib

(Borland 32-bit applications); or

ps3000.lib

(Microsoft Visual C 32-bit applications).

The following files must be in the compilation directory:

ps3000.h

;

and the following file must be in the same directory as the executable.

ps3000.dll

3.6.2

Visual Basic

The Win32 sub-directory contains the following files:

ps3000.vbp

 - project file

ps3000.bas

 - procedure prototypes

ps3000.frm

 - form and program

Note

:

 The functions which return a TRUE/FALSE value, return 0 for FALSE and 1 for

TRUE, whereas Visual basic expects 65 535 for TRUE. Check for > 0 rather than =TRUE.

Содержание picoscope 3204

Страница 1: ...Copyright 2005 Pico Technology Limited All rights reserved PicoScope 3000 Series User guide PS3000044 1 4 PC Oscilloscopes...

Страница 2: ...mum system requirements 6 2 Installation instructions 8 3 Specifications 9 3 Technical reference 9 1 Driver 9 2 Driver error codes 10 3 Functions 26 4 Advanced features 29 5 Using different modes 30 6...

Страница 3: ...collect and analyse data from the oscilloscope A typical PicoScope 3000 Series PC Oscilloscope is supplied with the following items USB cable for use with USB 1 1 and 2 0 ports Software CD Installatio...

Страница 4: ...ng the ground input to any source other than ground If in doubt use a meter to check that there is no significant AC or DC voltage between the ground input of the oscilloscope and the point to which y...

Страница 5: ...of and retains the rights to all material software documents etc contained in this release You may copy and distribute the entire release in its original state but must not copy individual items withi...

Страница 6: ...and tear wilful damage negligence abnormal working conditions or failure to follow Pico Technology s spoken or written advice on the storage installation commissioning use or maintenance of the Goods...

Страница 7: ...Oscilloscope to the PC until you have installed the software Procedure Follow the instructions in the Quick Start Guide included with your product package Connect your PC Oscilloscope to the PC using...

Страница 8: ...d via the PicoScope software or by API calls The signal generator can also be used to compensate x10 scope probes when set to output a square wave Ground loops If you experience excessive noise or vol...

Страница 9: ...te 2 None External trigger 1 BNC input shared with signal generator Variable trigger threshold 20 V Rising falling 12 2 mV resolution 1 MW impedance None Voltage ranges 100 mV to 20 V in 1 2 5 steps 2...

Страница 10: ...se with the driver A description of the driver error codes is given below If the PicoScope or PicoLog software reports an error refer to the FAQ Code Enumeration Description 0 PS3000_OK The oscillosco...

Страница 11: ...3 3 Functions 3 3 1 ps3000_open_unit short ps3000_open_unit void This function opens a PicoScope 3000 Series PC Oscilloscope The API driver can support up to four oscilloscopes Arguments None Returns...

Страница 12: ...ll of the information only the first string_length characters are returned info is an enumerated type specifying what information is required from the driver Returns The length of the string written t...

Страница 13: ...S3000044 1 4 3 3 3 ps3000_flash_led short ps3000_flash_led short handle Flashes the LED on the front of the oscilloscope three times and returns within one second Arguments handle the handle of the Pi...

Страница 14: ...rights reserved PS3000044 1 4 3 3 4 ps3000_close_unit short ps3000_close_unit short handle Shuts down a PicoScope 3000 Series PC Oscilloscope Arguments handle the handle returned by ps3000_open_unit o...

Страница 15: ...not available on all models enabled specify if the channel is active TRUE active FALSE inactive dc specifies the position of the AC DC switch TRUE DC FALSE AC range a code between 0 and 12 See the tab...

Страница 16: ...to calculate the most suitable time unit to use time_interval_ns a pointer to the time interval in ns between readings at the selected timebase If a null pointer is passed nothing will be written here...

Страница 17: ...ency long stop_frequency float increment short dwell_time short repeat short dual_slope This function is used to enable or disable the signal generator and sweep functions Sweep functions are not avai...

Страница 18: ...start_frequency This is not used in a non sweep mode This argument has no effect if used with the PicoScope 3204 variant dwell_time This is the time in ms to wait before increasing the frequency by i...

Страница 19: ...ata from previously returned cycles PS3000_ETS_SLOW 2 enable ETS and provide fresh data every ets_cycles cycles PS3000_ETS_SLOW takes longer to provide each data set but the data sets are more stable...

Страница 20: ...nal are not available on all models threshold the threshold for the trigger event This is scaled in 16 bit ADC counts at the currently selected range If an external trigger is enabled the range is fix...

Страница 21: ...cts a sample rate half as fast timebase 2 is half as fast again and so on For the maximum sample rate see the specifications Note that the number of channels enabled may affect the availability of the...

Страница 22: ...the required device time_interval_ms the time interval in ms between data points This can be no shorter than 1 ms max_samples the maximum number of samples that the driver is to store This can be no...

Страница 23: ...g if the oscilloscope is in streaming mode Arguments handle the handle to the required device Returns 1 meaning ready is returned when the oscilloscope has collected a complete block of data or the au...

Страница 24: ...13 ps3000_stop void ps3000_stop short handle Call this function to stop the oscilloscope from sampling data If this function is called before a trigger event occurs the oscilloscope may not contain va...

Страница 25: ...the buffers that receive data from the specified channels A B C or D A pointer is unused if the oscilloscope is not collecting data from that channel If a pointer is NULL nothing will be written to it...

Страница 26: ...ers that receive data from the specified channels A B C or D A pointer is unused if the oscilloscope is not collecting data from that channel If a pointer is NULL nothing will be written to it overflo...

Страница 27: ...oscilloscope thus doubling the effective sampling rate of a single channel The driver for a PicoScope 3000 Series PC Oscilloscope normally performs a number of setup operations before collecting each...

Страница 28: ...sample rate when working with repetitive signals It is not possible to use ETS with one shot signals ETS is controlled by the ps3000_set_trigger and ps3000_set_ets functions ETS is available in block...

Страница 29: ...er software control The signal generator output and external trigger input share the same connector so these two functions cannot be used at the same time It is possible however to use the output from...

Страница 30: ...scope using ps3000_get_values or ps3000_get_times_and_values 9 Display the data 10Repeat steps 6 to 9 11Stop the oscilloscope using ps3000_stop 3 5 3 Using streaming mode This is the general procedure...

Страница 31: ...000 rch ps3000 h and the following file must be in the same directory as the executable ps3000 dll The console example program is a generic windows application that is it does not use Borland AppExper...

Страница 32: ...0fm dfm and ps3000fm pas This has been tested with Delphi versions 3 3 6 4 Excel 1 Load the spreadsheet ps3000 xls 2 Select Tools Macro 3 Select GetData 4 Select Run Note The Excel Macro language is s...

Страница 33: ...loscope could not be found on your machine Make sure the software is installed before the oscilloscope is plugged into the USB socket and restart your computer Ensure that mention of the oscilloscope...

Страница 34: ...a mains powered computer and is used to measure a signal on another mains powered device In this case the ground loop is created through mains earth as illustrated below The majority of laptop power...

Страница 35: ...Windows applet that displays the current hardware configuration of your computer On Windows 98 or Windows ME right click on My Computer and choose the Device Manager tab On Windows 2000 or XP right c...

Страница 36: ...nel inputs you can send a signal down one of the channels On some units the signal generator can generate a simple TTL square wave while on others it can generate a sine square or triangle wave that c...

Страница 37: ...sal Serial Bus High Speed This is a standard port that enables you to connect external devices to PCs A typical USB 2 0 port supports a data transfer rate 40 times faster than USB 1 1 and all USB 2 0...

Страница 38: ...31 External trigger 6 8 19 27 28 F Functions 26 27 28 29 ps3000_close_unit 13 ps3000_flash_led 12 ps3000_get_timebase 15 ps3000_get_times_and_values 25 ps3000_get_unit_info 11 ps3000_get_values 24 ps3...

Страница 39: ...ty symbols 2 Safety warning 3 Sampling rate 27 Sampling rate maximum 8 Scope probe 6 Signal generator 6 8 16 27 28 29 Software control 28 Software error codes 32 Specifications 8 Spectrum analyser 2 S...

Страница 40: ...Pico Technology Ltd The Mill House Cambridge Street St Neots PE19 1QB United Kingdom Tel 44 0 1480 396 395 Fax 44 0 1480 396 296 Web www picotech com PS3000044 1 4 17 10 05...

Отзывы: