plestylib.traffic.visa
======================

.. py:module:: plestylib.traffic.visa


Classes
-------

.. autoapisummary::

   plestylib.traffic.visa.VisaTrafficManager


Module Contents
---------------

.. py:class:: VisaTrafficManager(address: str, timeout: int = 5000, write_termination='\n', read_termination='\n', baud_rate: int = None)

   Bases: :py:obj:`plestylib.traffic.TrafficManager`


   A TrafficManager implementation for managing VISA communication.

   This class provides methods to open, close, and communicate with VISA instruments.


   Initialize the TrafficManager with the given address and timeout.

   :param address: The address of the resource.
   :type address: str
   :param timeout: The timeout for operations in seconds. Defaults to 5.
   :type timeout: int, optional


   .. py:attribute:: write_termination
      :value: Multiline-String

      .. raw:: html

         <details><summary>Show Value</summary>

      .. code-block:: python

         """
         """

      .. raw:: html

         </details>




   .. py:attribute:: read_termination
      :value: Multiline-String

      .. raw:: html

         <details><summary>Show Value</summary>

      .. code-block:: python

         """
         """

      .. raw:: html

         </details>




   .. py:attribute:: baud_rate
      :value: None



   .. py:attribute:: rm
      :value: None



   .. py:method:: discover_instrument(address: str) -> list[str] | bool

      Discover the VISA instrument at the specified address.

      :param address: The VISA resource address to discover, this address
      :type address: str
      :param will override self.address and update it.:

      :returns: A list of available VISA resources if the specified address is found.
                bool: False if the specified address is not found or if an error occurs during discovery.
      :rtype: list[str]



   .. py:method:: _open()

      Connect to the VISA instrument at the specified address.



   .. py:method:: _close()

      Close the VISA connection.



   .. py:method:: _send_command(command: str, timeout=None, mode=None) -> str | bool

      Send a command to the VISA instrument and return the response.



