Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🚧 Add some DC devices #105

Merged
merged 1 commit into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions piel/experimental/models/__init__.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
# use experimental/__init__.py to import all the necessary modules and functions.
from .cables import rg164
from .oscilloscope import create_two_port_oscilloscope, DPO73304
from .waveform_generator import create_one_port_square_wave_waveform_generator, AWG70001A
from .multimeter import DMM6500
from .rf_passives import create_power_splitter_1to2
from .rf_calibration import (
open_82052D,
short_82052D,
load_85052D,
through_85052D,
)
from .sourcemeter import SMU2450
from .oscilloscope import create_two_port_oscilloscope, DPO73304
from .waveform_generator import (
create_one_port_square_wave_waveform_generator,
AWG70001A,
)
from .vna import E8364A
38 changes: 38 additions & 0 deletions piel/experimental/models/multimeter.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
from ...types import PhysicalPort
from ..types import Multimeter


def DMM6500() -> Multimeter:
ports = [
PhysicalPort(
name="INPUTHI",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="INPUTLO",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="SENSEHI",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="SENSELO",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="MANIFOLDGND",
domain="DC",
connector="Banana",
),
]

return Multimeter(
name="DMM6500",
ports=ports,
manufacturer="Keithley",
)
21 changes: 19 additions & 2 deletions piel/experimental/models/oscilloscope.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,22 @@ def create_two_port_oscilloscope() -> Oscilloscope:
)


def DPO73304():
pass
def DPO73304() -> Oscilloscope:
ports = [
PhysicalPort(
name="CH1",
domain="RF",
connector="SMA",
),
PhysicalPort(
name="CH2",
domain="RF",
connector="SMA",
),
]

return Oscilloscope(
name="DPO73304",
ports=ports,
manufacturer="Tektronix",
)
38 changes: 38 additions & 0 deletions piel/experimental/models/sourcemeter.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
from ...types import PhysicalPort
from ..types import Sourcemeter


def SMU2450() -> Sourcemeter:
ports = [
PhysicalPort(
name="FORCEHI",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="FORCELO",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="SENSEHI",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="SENSELO",
domain="DC",
connector="Banana",
),
PhysicalPort(
name="MANIFOLDGND",
domain="DC",
connector="Banana",
),
]

return Sourcemeter(
name="SMU2450",
manufacturer="Keithley",
ports=ports,
)
5 changes: 4 additions & 1 deletion piel/experimental/models/vna.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@


def E8364A() -> pe.types.VNA:
return pe.types.VNA(name="E8364A")
return pe.types.VNA(
name="E8364A",
manufacturer="Agilent",
)
1 change: 1 addition & 0 deletions piel/experimental/models/waveform_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ def create_one_port_square_wave_waveform_generator(
name="two_port_oscilloscope",
ports=ports,
configuration=configuration,
manufacturer="Tektronix",
)


Expand Down
15 changes: 9 additions & 6 deletions piel/experimental/types/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
from .frequency import VNA, VNAConfiguration, VNAMeasurement

from .dc import (
Sourcemeter,
SourcemeterConfiguration,
Multimeter,
MultimeterConfiguration,
)

from .device import (
Device,
DeviceConfiguration,
Expand All @@ -13,16 +20,12 @@

from .measurements.propagation import (
PropagationDelayMeasurement,
PropagationDelayMeasurementSweep
)

from .measurements.data.core import (
ExperimentInstance
PropagationDelayMeasurementSweep,
)

from .measurements.data.propagation import (
PropagationDelayMeasurementData,
PropagationDelayMeasurementSweepData
PropagationDelayMeasurementSweepData,
)

from .time import (
Expand Down
31 changes: 31 additions & 0 deletions piel/experimental/types/dc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
from .device import Device, DeviceConfiguration


class SourcemeterConfiguration(DeviceConfiguration):
"""
This class corresponds to the configuration of data which is just inherent to the Sourcemeter connectivity and configuration,
not the experimental setup connectivity.
"""

current_limit_A: float
voltage_limit_V: float


class Sourcemeter(Device):
"""
Represents a sourcemeter.
"""

configuration: SourcemeterConfiguration


class MultimeterConfiguration(DeviceConfiguration):
"""
This class corresponds to the configuration of data which is just inherent to the Multimeter connectivity and configuration,
"""


class Multimeter(Device):
"""
Represents a multimeter.
"""
5 changes: 5 additions & 0 deletions piel/experimental/types/device.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ class Device(PhysicalComponent):

configuration: Optional[DeviceConfiguration] = None

manufacturer: Optional[str] = None
"""
The manufacturer of the device.
"""


class MeasurementDevice(Device):
measurement: Optional[DeviceMeasurement] = None
Expand Down
Loading