{
 "cells": [
  {
   "cell_type": "raw",
   "metadata": {
    "raw_mimetype": "text/restructuredtext"
   },
   "source": [
    ".. _virtualinstruments::\n",
    "\n",
    "|\n",
    "|\n",
    "\n",
    "Download This Notebook: :download:`VirtualInstruments.ipynb`"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Virtual Instruments\n",
    "    \n",
    "## Introduction"
   ]
  },
  {
   "cell_type": "raw",
   "metadata": {
    "raw_mimetype": "text/restructuredtext"
   },
   "source": [
    ".. warning::\n",
    "\n",
    "    The `vi` module is not well written or tested at this point. Basic support is available for data retrieval. "
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "This tutorial is mostly a stub. \n",
    "\n",
    "The [vi](../api/vi/index.rst) module holds  classes\n",
    "for GPIB/VISA instruments that are intricately related to **skrf**, so take a look there. To use the virtual instrument classes you must have [pyvisa]( http://pyvisa.readthedocs.org/en/latest/)  and [python-ivi]( https://github.com/python-ivi/python-ivi) installed, AND a working VISA installation. A list of VNA's that have been are partially supported.\n",
    "\n",
    "* `PNA`\n",
    "* `ZVA40`    \n",
    "* `HP8510C`\n",
    "* `HP8720`\n",
    "\n",
    "\n",
    "An example usage of the `PNA` class to retrieve some s-parameter data"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "    In [1]: from skrf.vi import vna\n",
    "    \n",
    "    In [2]: my_vna = vna.HP8510C(address =16) \n",
    "    #if an error is thrown at this point there is most likely a problem with your visa setup\n",
    "    \n",
    "    \n",
    "    In [3]: dut_1 = my_vna.s11\n",
    "    \n",
    "    In [4]: dut_2 = my_vna.s21\n",
    "    \n",
    "    In [5]: dut_3 = my_vna.two_port\n",
    "    \n",
    "Unfortunately, the syntax is different for every VNA class, so the\n",
    "above example wont directly translate to other VNA's, but you get the idea, \n",
    "    "
   ]
  }
 ],
 "metadata": {
  "celltoolbar": "Raw Cell Format",
  "kernelspec": {
   "display_name": "Python [conda env:py35]",
   "language": "python",
   "name": "conda-env-py35-py"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.5.2"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
