Skip to main content

A Python Package for Interfacing with the Bridge12 MPS

Project description

README

pyB12MPS is a python package for interfacing with Bridge12 MPS.

The complete online documentation for the Bridge12 MPS is available here.

The complete online documentation for pyB12MPS is available here.

Requirements

  • Python3 (>= 3.6)
  • numpy, pySerial

Communicating with the Bridge12 MPS

First make sure the Bridge12 MPS is connected to the computer via a USB cable and the system is powered ON.

In a terminal window, start a python environment

python
import pyB12MPS

mps = pyB12MPS.MPS()

The MPS will reset and the python environment will hang until the MPS has initialized.

To close the MPS serial port:

mps.close()

Sending MPS Commands

Once the connection has been established, you can send commands to the MPS.

mps.freq(9.4) # set frequency to 9.4 GHz

mps.freq() # Query the microwave frequency in GHz

Example Script

import pyB12MPS
import time

mps = pyB12MPS.MPS()

# Number of Rx voltage points to acquire
pts = 10

# Time delay between measurements in seconds
dt = 0.5

rxVoltageList = []

for ix in range(pts):
    # delay
    time.sleep(dt)

    # Read MPS Rx diode voltage
    rxVoltage = mps.rxpowermv()

    # Print Rx voltage reading
    print('Rx Voltage: %0.01f'%rxVoltage)

    rxVoltageList.append(rxVoltage)

print('Rx Voltage Readings:')
print(rxVoltageList)

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

pyB12MPS-2.0.0.tar.gz (9.3 kB view details)

Uploaded Source

Built Distributions

pyB12MPS-2.0.0-py3.8.egg (42.0 kB view details)

Uploaded Source

pyB12MPS-2.0.0-py3-none-any.whl (8.8 kB view details)

Uploaded Python 3

File details

Details for the file pyB12MPS-2.0.0.tar.gz.

File metadata

  • Download URL: pyB12MPS-2.0.0.tar.gz
  • Upload date:
  • Size: 9.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.1

File hashes

Hashes for pyB12MPS-2.0.0.tar.gz
Algorithm Hash digest
SHA256 1540db8df1dd25c92501c36653fceab5a66fa896f5c520af6e8c9ba335a91168
MD5 c2334bd9487c069308679ba374f89e1b
BLAKE2b-256 ef5ed9b04d51f4ae062c248b4f11309a0b768eaf63b270aacc5c0a70d522463a

See more details on using hashes here.

File details

Details for the file pyB12MPS-2.0.0-py3.8.egg.

File metadata

  • Download URL: pyB12MPS-2.0.0-py3.8.egg
  • Upload date:
  • Size: 42.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.1

File hashes

Hashes for pyB12MPS-2.0.0-py3.8.egg
Algorithm Hash digest
SHA256 6c7b2cf63dda5c6e38fed15f6964200366c480d172d3393e145239b9fdd80d03
MD5 ef3efbee13d67930fc0a9bc3b7969149
BLAKE2b-256 9d89570434f924c85801432ab60c2748dbf37616ce2d0c744ce98afbc60a1a18

See more details on using hashes here.

File details

Details for the file pyB12MPS-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: pyB12MPS-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 8.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.1

File hashes

Hashes for pyB12MPS-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f3fa819b111d3ca4914a7627fe29d82b992ec559ce2228aa62053c3f580d671a
MD5 2e3393e969f8689a5c7e3748e0be95ba
BLAKE2b-256 660b46fa873bd3dd4d801713d99e9f058e0875fed67b343b8908a07b040f0d18

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