Skip to main content

No project description provided

Project description

pfeiffer-turbo

Python versions on PyPI pfeiffer-turbo version on PyPI Code style: black
Python interface RS485 connections for Pfeiffer HiPace turbo drive units. Currently only the TM700 is implemented. Also supports connecting through a TCPIP socket, e.g. when using a serial to TCPIP converter for the turbo controller.

Example

RS485 connection example

from pfeiffer_turbo import TM700

pump = TM700(resource_name = "COM9", address = 1)

# get the rotation speed in Hz
pump.actual_spd

# start the pump
pump.start()

# stop the pump
pump.stop()

TCPIP connection example

from pfeiffer_turbo import TM700

pump = TM700(
    resource_name="10.10.222.8:12345", address=1, connection_type=ConnectionType.TCPIP
)

# get the rotation speed in Hz
pump.actual_spd

# start the pump
pump.start()

# stop the pump
pump.stop()

Implementation

A baseclass DriveUnit:

class DriveUnit:
    def __init__(
        self,
        resource_name: str,
        address: int,
        connection_type: ConnectionType,
        supported_parameters: Sequence[int],
    ):

takes in a set of integers that correspond to pfeiffer vacuum parameters supported by the particular drive unit. Implemented vacuum parameters are seen in parameters.py. The getters and setters are then dynamically generated based on the supported_parameters and info in parameters.py; the enum Parameters contains all implemented pfeiffer vacuum parameters, and the dictionary parameters contains key, value pairs of Parameters and ParameterInfo, where ParameterInfo is a dataclass containing the implemenation information for a particular parameter:

@dataclass
class Parameter:
    designation: str
    data_type: DataType
    access: StopIteration
    min: Optional[int] = None
    max: Optional[int] = None
    unit: Optional[str] = None
    default: Optional[Union[int, float, str]] = None
    options: Optional[dict[int, str]] = None

Implementing new drive units is be done by inheriting from DriveUnit and specifying which pfeiffer parameters are supported by the specific model. New parameters can be implemented by extending the Parameters enum and parameters dictionary. The class attributes are named similarly to the Pfeiffer vacuum parameters, with underscores inserted between uppercase - lowercase transitions and all lowercase letters. E.g. GasMode -> gas_mode.

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

pfeiffer-turbo-0.1.2.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

pfeiffer_turbo-0.1.2-py3-none-any.whl (10.1 kB view details)

Uploaded Python 3

File details

Details for the file pfeiffer-turbo-0.1.2.tar.gz.

File metadata

  • Download URL: pfeiffer-turbo-0.1.2.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.1 CPython/3.9.7 Windows/10

File hashes

Hashes for pfeiffer-turbo-0.1.2.tar.gz
Algorithm Hash digest
SHA256 394550e785cf6bce6f18cff0b28849c0dfec14f35d46cb386293ffd753a6c4ca
MD5 952ea35bd9d243cbf1b263dbdee9f56b
BLAKE2b-256 b2d96ee777ed12b81e3b4876c41c6f7472da20b2b8527b03f585c1a8a285aefc

See more details on using hashes here.

File details

Details for the file pfeiffer_turbo-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: pfeiffer_turbo-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 10.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.2.1 CPython/3.9.7 Windows/10

File hashes

Hashes for pfeiffer_turbo-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 19ca97dee8dcada7a99dd2439de848b7381bddc9a4edc14308c960bed7ccd765
MD5 ed638a1e10ccbf507fb6308a127de98a
BLAKE2b-256 64608dcdd89ed82d78143c2d39dc03802d231433e67176eea96c8a7899bc1fee

See more details on using hashes here.

Supported by

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