Skip to main content

RPC for Swabian Instruments' Time Tagger

Project description

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 name server.
  --start_ns        Start Pyro5 name server 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.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

TimeTaggerRPC-0.0.6-py3-none-any.whl (9.2 kB view details)

Uploaded Python 3

File details

Details for the file TimeTaggerRPC-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: TimeTaggerRPC-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 9.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.27.1

File hashes

Hashes for TimeTaggerRPC-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 0540cc165317028f8bddd680d69dfee99ca50cc9d26b409193579f87d2783f05
MD5 b5087500c27be375c1e993aa67c32319
BLAKE2b-256 05fd6fda332eccf5f9a8844926b6bd29ef3378801fddf0ce67fe0f14755797fc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page