Skip to content

CONNECTION_FSV

Connect Flojoy to a FSV network analyzer. The connection is made with the VISA address in the Flojoy UI. This block should also work with compatible R&S network analyzers. Params: device : VisaDevice The VISA address to connect to. Returns: out : DataContainer None
Python Code
from flojoy import VisaDevice, flojoy, DataContainer
from flojoy.connection_manager import DeviceConnectionManager
from typing import Optional
from pyvisa import ResourceManager


@flojoy()
def CONNECTION_FSV(
    device: VisaDevice,
    default: Optional[DataContainer] = None,
) -> Optional[DataContainer]:
    """Connect Flojoy to a FSV network analyzer.

    The connection is made with the VISA address in the Flojoy UI.

    This block should also work with compatible R&S network analyzers.

    Parameters
    ----------
    device: VisaDevice
        The VISA address to connect to.

    Returns
    -------
    DataContainer
        None
    """

    rm = ResourceManager("@py")
    rohde = rm.open_resource(device.get_id())
    rohde.read_termination = "\n"
    rohde.write_termination = "\n"

    DeviceConnectionManager.register_connection(device, rohde)

    return None

Find this Flojoy Block on GitHub

Videos

Read FM Radio Signals using Flojoy

Example

Having problems with this example app? Join our Discord community and we will help you out!
React Flow mini map

In this example, the Rohde & Schwarz FSV Signal Analyzer is used to view the FM radio range (86-110 MHz).

First 4 FSV nodes were added: CONNECTION_FSV, SWEEP_SETTINGS_FSV, INIT_SWEEP_FSV, and EXTRACT_SWEEP_FSV. A LINE node was also added. The VISA address was set for the 4 instrument nodes. The range of the signal analyzer sweep was set with SWEEP_SETTINGS_FSV (start = 86, stop = 110 MHz).

The nodes were then connected as shown in the image, and the app was run.