GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - picotech/picosdk-python-examples: DEPRECATED - An example Python application and examples for PicoScope® oscilloscope products.

This repository was archived by the owner on Sep 14, 2018. It is now read-only.
BranchesTags
Open more actions menu

Latest commit

 

History

54 Commits
54 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
examples
examples
 
 
picosdk
picosdk
 
 
.gitignore
.gitignore
 
 
LICENSE.md
LICENSE.md
 
 
README.md
README.md
 
 
setup.py
setup.py
 
 

Repository files navigation

DEPRECATED

This repository is no longer supported, please consider using picosdk-python-wrappers instead.

This repository contains an example Python module for PicoScope oscilloscopes.

Getting started

Prerequisites

  • A PicoScope oscilloscope using one of the following PicoScope drivers:
    • ps2000
    • ps2000a
    • ps3000
    • ps3000a
    • ps4000
    • ps4000a
    • ps5000a
    • ps6000
  • Python 2.7

Microsoft Windows

  • For best experience on Microsoft Windows Python(x,y) suite is recommended. Note that this will require the 32-bit PicoSDK to be installed (see Installing drivers)

Linux and Mac OS X

  • For Streaming mode data collection, the pytables module is required.
  • The block_capture and streaming_capture examples require matplotlib and signal.
  • PicoPyScope example has been written for use with PyQtGraph.

Notes: The code is not much different from Python3 and can be easily converted with the 2to3 utility. The module has been tested and proved working on Linux (including ARM derivatives), Microsoft Windows and Mac OS X.

Installing drivers

Drivers are available for the following platforms. Refer to the subsections below for further information.

Microsoft Windows

  • Download the PicoSDK (32-bit or 64-bit) driver package installer from our Downloads page.

Linux

  • Follow the instructions from our Linux Software & Drivers for Oscilloscopes and Data Loggers page to install the required driver packages for your product.

Mac OS X

  • Visit our Downloads page and download the PicoScope Beta for Mac OS X application.

Installing the python driver bindings

A distutils installer is provided. After you have installed the PicoSDK driver package (see above), the Python installer can be used as follows:

python setup.py install

On macOS and Linux you will either need to use sudo with this command, to install into the system folders, or to install for the current user only you can use:

python setup.py install --user

Within python, the library for import is called picosdk.

Scripts

python-picoscope

  • block_capture.py - comprehensive suite for testing block collection (-h to see all options)
  • stream_capture.py - streaming testing utility, including some performance tests (-h to see all options)
  • picopyscope.py - simple PC oscilloscope UI

Note: A basic script requires just a few lines as below. Most functions have been decorated with docstrings.

from picosdk import ps2000

if __name__ == "__main__":
    ps = ps2000.Device()
    status = ps.open_unit()
    if status == ps.m.pico_num("PICO_OK"):
        s, state = ps.get_channel_state(channel=ps.m.Channels.A)
        state.enabled = True
        state.range = ps.m.Ranges.r5v
        status = ps.set_channel(channel=ps.m.Channels.A, state=state)
        if status == ps.m.pico_num("PICO_OK"):
            s, index = ps.locate_buffer(channel=ps.m.Channels.A,
                                        samples=1000,
                                        segment=0,
                                        mode=ps.m.RatioModes.raw,
                                        downsample=0)
            status = ps.collect_segment(segment=0, interval=1000)
            if status == ps.m.pico_num("PICO_OK"):
                status, data = ps.get_buffer_volts(index=index)
                print data
                exit(0)
    print ps.m.pico_tag(status)

Programmer's Guides

You can download Programmer's Guides providing a description of the API functions for the relevant PicoScope or PicoLog driver from our Documentation page.

Obtaining support

Please visit our Support page to contact us directly or visit our Test and Measurement Forum to post questions.

Contributing

Contributions are welcome. Please refer to our guidelines for contributing for further information.

Applications written by our customers

The following are Python examples written by our customers:

  • pico-python
  • PicoPy
  • picotools
  • TC08-Command-Line
  • usbtc08
  • picostream

The following is a fork of this repository:

  • Lorac/picosdk-python-examples

Copyright and licensing

See LICENSE.md for license terms.

PicoScope and PicoLog are registered trademarks of Pico Technology Ltd.

Windows is a registered trademark of Microsoft Corporation.

Mac and OS X are registered trademarks of Apple, Inc.

Linux is the registered trademark of Linus Torvalds in the U.S. and other countries.

Copyright © 2014-2018 Pico Technology Ltd. All rights reserved.

About

DEPRECATED - An example Python application and examples for PicoScope® oscilloscope products.

Topics

archiveddeprecatedlinuxmacosobseletepicoscopepicoscope-oscilloscopepythonpython-2python2-7windows

Resources

Readme
ISC license

Code of conduct

Code of conduct

Contributing

Contributing
Activity
Custom properties

Stars

23 stars

Watchers

0 watching

Forks

11 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.