Skip to main content

Python library for piezosystem NV200 device

Project description

nv200

Python library for piezosystem NV200 device control

PyPI version Python Version Docs Monthly Downloads


📦 Installation

Install from PyPI:

pip install nv200

🚀 Quick Start

import asyncio
from nv200.nv200_device import NV200Device
from nv200.shared_types import PidLoopMode
from nv200.connection_utils import connect_to_single_device


async def main_async():
    """
    Moves the device to a specified position using closed-loop control.
    """
    dev = await connect_to_single_device(NV200Device)
    print(f"Connected to device: {dev.device_info}")

    await dev.move_to_position(20)
    await asyncio.sleep(0.2)
    print(f"Current position: {await dev.get_current_position()}")

    # instead of using move_to_position, you can also use two separate commands
    # to set the PID mode and the setpoint
    await dev.set_pid_mode(PidLoopMode.CLOSED_LOOP)
    await dev.set_setpoint(0)
    await asyncio.sleep(0.2)
    print(f"Current position: {await dev.get_current_position()}")


if __name__ == "__main__":
    asyncio.run(main_async())

For more advanced usage and async control, see the full API documentation.


📚 Documentation

📖 Full documentation is available at
👉 https://piezosystemjena.github.io/nv200-python-lib/

It includes:

  • Setup & Installation
  • Device Communication Protocols
  • Full API Reference
  • Examples and Tutorials

🛠 Features

  • ✅ Asynchronous communication via aioserial and telnetlib3
  • ✅ Simple Pythonic interface for device control
  • ✅ Query & set device position
  • ✅ Supports NV200 data recorder functionality
  • ✅ Easy interface for NV200 waveform generator

📁 Examples

See the examples/ folder in the repository for:

  • Basic device connection
  • Position control scripts
  • Integration with GUI frameworks (via PySide6)

🧪 Development & Testing

Git Repository

The Git repository is available at: https://github.com/piezosystemjena/nv200-python-lib

Install dependencies

poetry install

Build documentation locally

poetry run build-doc
open doc/_build/index.html

🤝 Contributing

Contributions are welcome! If you encounter bugs or have suggestions:

  • Open an issue
  • Submit a pull request
  • Or contact us directly

For major changes, please open a discussion first.


📜 License

This project is licensed under the MIT License.
See the LICENSE file for details.


👤 Authors

piezosystemjena GmbH
Visit us at https://www.piezosystem.com


🔗 Related

Project details


Download files

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

Source Distribution

nv200-1.4.0.tar.gz (58.9 kB view details)

Uploaded Source

Built Distribution

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

nv200-1.4.0-py3-none-any.whl (65.8 kB view details)

Uploaded Python 3

File details

Details for the file nv200-1.4.0.tar.gz.

File metadata

  • Download URL: nv200-1.4.0.tar.gz
  • Upload date:
  • Size: 58.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.11 Linux/6.11.0-1018-azure

File hashes

Hashes for nv200-1.4.0.tar.gz
Algorithm Hash digest
SHA256 affc2c1d2a42623d446bfece7dd4dc49e84bd0610119916ddeb8490897c3c397
MD5 28f3fa9863bb3160b7c0234045375d3f
BLAKE2b-256 76e3fd7998fb4f32cada9240345110a3eb53ed1a8f7668b2d2385d3a56e6a30e

See more details on using hashes here.

File details

Details for the file nv200-1.4.0-py3-none-any.whl.

File metadata

  • Download URL: nv200-1.4.0-py3-none-any.whl
  • Upload date:
  • Size: 65.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.11 Linux/6.11.0-1018-azure

File hashes

Hashes for nv200-1.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1ff816aec548cbf597e40213047b9e2fa201ef54b2bf6c99ff30cbb1de46b9dc
MD5 f0bda5c49d04976478fec47c49ccb8e5
BLAKE2b-256 3c747e92f75f4b12f32d552f03b56ec20de5ea3183d67846976cf73ad2ac69ef

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