Giter VIP home page Giter VIP logo

timetaggerrpc's Introduction

PyPI Version PyPI - Downloads

Time Tagger RPC implementation using Pyro5.

Alpha version !

This project is in the alpha stage of the development. This means that the code successfully passed basic testing and is operational. However, some things might be broken and the API may change in the future versions.

Install

> pip install TimeTaggerRPC

Run server

Start the server on a PC with the Time Tagger connected.

> TimeTaggerRPC-server --help
usage: TimeTaggerRPC-server [-h] [--host localhost] [--port 23000] [--use_ns] [--start_ns]

--------------------------------------------
Swabian Instruments Time Tagger RPC Server.
--------------------------------------------

optional arguments:
  -h, --help        show this help message and exit
  --host localhost  Hostname or IP on which the server will listen for connections.
  --port 23000      Server port.
  --use_ns          Use Pyro5 nameserver.
  --start_ns        Start Pyro5 nameserver in a subprocess.

Client example

Control Time Tagger remotely over the network.

import matplotlib.pyplot as plt
from TimeTaggerRPC import client

with client.createProxy(host='localhost', port=23000) as TT:
   tagger = TT.createTimeTagger()
   tagger.setTestSignal(1, True)
   tagger.setTestSignal(2, True)

   hist = TT.Correlation(tagger, 1, 2, binwidth=5, n_bins=2000)
   hist.startFor(int(10e12), clear=True)

   x = hist.getIndex()
   while hist.isRunning():
      plt.pause(0.1)
      y = hist.getData()
      plt.cla()
      plt.plot(x, y)

   TT.freeTimeTagger(tagger)
   

You can find more information about the Time Tagger API in the official documentation.

timetaggerrpc's People

Contributors

igor-shavrin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.