Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cg635-clock-generator

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cg635-clock-generator

Interface with a Stanford Research Systems CG635 Synthesized Clock Generator

  • 1.0.2
  • PyPI
  • Socket score

Maintainers
1

SRS-CG635 Synthesized Clock Generator Interface

Interface with a Stanford Research Systems CG635 Synthesized Clock Generator.

Installation

$ pip install cg635-clock-generator

Supported Features

  • Frequency control
  • Phase control
  • CMOS output levels and standards control
  • Q/*Q outputs levels and standards control
  • R232 communication

Usage

from cg635_clock_generator import CG635ClockGenerator, CG635Communication

clock_generator = CG635ClockGenerator(
        communication_type=CG635Communication.RS232,
        serial_device='/dev/ttyUSB0',
)

print(clock_generator.get_identification())

FREQ = 10e6
PHASE = 90.0

clock_generator.set_frequency(FREQ)

frequency = clock_generator.get_frequency()
print(f"Frequency is {frequency} Hz")

clock_generator.set_phase(PHASE)

phase = clock_generator.get_phase()
print(f"Phase is {phase} degrees")

Running tests on hardware

During normal development and for the CI the unit test suite is executed on a mock device using pyvisa-mock. It is also possible to run tests on real hardware connected to your system. Just set the hil flag when running tox

$ tox -- --hil

By default it will try to connect to /dev/ttyUSB0, but you can specify a different device using the --hil_serial_device option:

$ tox -- --hil --hil_serial_device /dev/ttyUSB1

Status

Currently only the RS232 communication has been tested on the device.

Documentation

For more details of the module API, check the online documentation.

Feeling like contributing?

Great! Check the Contributing Guide to get started.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc