Add description of export button.
[oscopy.git] / doc / ioscopy / tex / ioscopy-manual.tex
blobf709329d48dc004d9ce5ca320ce65fe1f982c053
1 \documentclass[a4paper,11pt]{report}
3 \usepackage[english]{babel}
4 \usepackage{a4wide}
5 \usepackage{graphicx}
6 \usepackage{wasysym}
7 \usepackage[font=small,labelfont=sf,textfont=sf]{caption}
8 \usepackage{hyperref}
9 \usepackage[sf]{titlesec}
10 \usepackage{lscape}
11 \usepackage{listings}
12 \usepackage{fancybox}
13 \usepackage{mdwlist}
14 \usepackage{fancyhdr}
15 \usepackage{xcolor}
17 \newcommand{\att}[1]{\texttt{#1}}
18 \newcommand{\meth}[1]{\texttt{#1()}}
19 \newcommand{\cls}[1]{\textsf{#1}}
20 \newcommand{\prop}[1]{\texttt{#1}}
22 \newcommand{\ctx}{\cls{Context}}
23 \newcommand{\sig}{\cls{Signal}}
24 \newcommand{\rd}{\cls{Reader}}
25 \newcommand{\rderr}{\cls{ReadError}}
26 \newcommand{\wrt}{\cls{Writer}}
27 \newcommand{\wrterr}{\cls{WriteError}}
28 \newcommand{\module}[1]{\textsc{#1}}
29 \newcommand{\graph}{\cls{Graph}}
30 \newcommand{\fig}{\cls{Figure}}
31 \newcommand{\cursor}{\cls{Cursor}}
32 \title{{\sc ioscopy}\\A viewer for plotting electrical simulation results\\User Manual}
33 \author{Arnaud Gardelein}
35 \hypersetup{
36 colorlinks=true,
37 linkcolor=black,
38 anchorcolor=black,
39 citecolor=black,
40 filecolor=black,
41 menucolor=black,
42 pagecolor=black,
43 urlcolor=black,
46 % From mdwlist
47 \renewenvironment{description}{%
48 \begin{basedescript}{%
49 \renewcommand{\makelabel}[1]{\bfseries##1}%
51 }{%
52 \end{basedescript}%
55 \begin{document}
56 \sf
57 \maketitle
58 \begin{abstract}
59 % data plotter
60 % post-processing
61 % result viewer
62 % primarily targeted for electrical simulation results
63 % can be extended beyond that
64 % update and dependency tracking
65 % which aims to simplify the development workflow
66 % interactive
68 Oscopy is an interactive oscilloscope written in python designed to simplify the electrical design workflow.
69 It allow to read, view and post-process signals with support for automatic dependency tracking.
70 File re-reading (updates) can be triggered by external applications like gEDA suite through D-Bus messaging system, and then Oscopy can call netlist generator and electrical simulator programs automatically.
71 As oscopy is built on top of IPython, post-processing include as well as simple arithmetics operation as complex functions like FFT.
72 Oscopy can be easily extended to a multi-purpose viewer, as adding new data file formats and new types of plots is really easy.
75 This document covers the user interface and command description.
76 % TODO: Update the abstract including short description of ioscopy and GUI
77 \end{abstract}
79 \lstset{basicstyle=\ttfamily,backgroundcolor=\color{gray!10},basewidth=0.5em,fontadjust=true}
80 \pagestyle{fancy}
81 \lhead{}
82 \cfoot{}
83 \rhead{\textsf{\leftmark}}
84 \rfoot{\textsf\thepage}
85 \chapter{Introduction}
86 \label{sec:intro}
87 % > * create a central design document that lists all important
88 % > concepts/classes (Signal, Figure, ...) and explains interactions
89 % > between them; this would really help a lot
90 % This one is more important. When we figure out and specify how various
91 % object interact between themselves, we're practically done. Then all the
92 % code just follows naturally.
93 In the electrical system design workflow, viewing results from analog simulation or experi\-ment is not a trivial task: there exist numerous different program with even more different file formats, the user interface has to be friendly and functional, and the program should be memory efficient due to the number of data points per file that can quickly grow.
95 \section{Rationale}
96 The gEDA suite contains mainly all tools required to design electrical boards, from scheme drawings to PCB routing.
97 There already exist several programs to view analog simulation results: gwave, GSpiceUI, dataplot.
99 Gwave is designed as a waveform viewer, and can read text files as well as binary files generated by Spice2, Spice3, ngspice, CAzM or gnucap.
100 The user interface supports drag and drop signals onto graphs, vertical bar cursors, multiple files and multiple panes.
102 GSpiceUI is more focused on the interaction between the user and the simulation program: it imports the schematic from gschem, allows the user to build the file to be used by the simulation and plot the results, eventually using GWave.
104 Dataplot has support for formats like gnucap, ngspice, hdf5 and touchstone.
105 The user interface has tabs for multiple plots and presents the data in a hierarchical manner.
107 Another way of viewing results is to use Octave (and generally gnuplot).
108 This approach enables one to post-process the results with operations such as FFT, diff.
109 Support for multiple figures is present.
110 Octave support HDF5 file format and tab-separated text-based files such as gnucap output.
111 The user interaction is essentially based on the command line interface.
113 The idea behind Oscopy is to combine the best of these approaches into a single, easily extendable program.
114 In this purpose, it has features such as multiple plots, multiple windows, different plot types (linear, log) and allows the user to do math with data, including basic operations, trigonometry, fft, diff.
115 It supports the gnucap file format for input and output, and has an update mechanism to reread data from files.
116 New file formats and new graph types can be added by following the guidelines presented in this document.
118 \section{Oscopy and IOscopy: the core and the app}
119 To enable reuse and make it flexible, Oscopy has two main components:
120 \begin{description}
121 \item[Oscopy] the core of it which gather all the framework API about file operations, signals management, figures and graph handling
122 \item[IOscopy] the application based on top of IPython which provide the command line interface
123 \end{description}
124 This means that IOscopy is just an application of using Oscopy core.
125 As of today the term \textsl{Oscopy} means either Oscopy or IOscopy and when differentiation is needed \textsl{oscopy-core} for the framework and either \textsl{oscopy-ipython} or \textsl{IOscopy} for the IPython application.
127 The framework API oscopy-core is described in oscopy-api.pdf that is usually installed at the same place of the this manual; typically \texttt{/usr/share/doc/oscopy}.
128 The present document is only about the application IOscopy.
130 \section{Supported input data formats}
131 Reading data files is performed using Oscopy. Supported formats are:
132 \begin{description}
133 \item[Gnucap] Text format from Gnucap
134 \item[Cazm] Text format from CaZM
135 \item[Nsout] NanoSim format from Synopsis; \textit{Independent variable assumed to be \texttt{Time}}
136 \item[Spice2raw] Berkeley Spice2G6 raw format; \textit{Only one dataset per file, \texttt{Date} and \texttt{Time} fields not processed}
137 \item[Spice3raw] Berkeley Spice3 format; \textit{\textbf{ascii} and \textbf{binary} formats supported, real and complex numbers supported. Only one simulation per file.}
138 \item[Hspice] Hspice format; \textit{\textbf{ascii} and \textbf{binary} formats supported. Only one sweep per file. Auto signals are note returned, only probe signals are. Endianness is not managed in binary mode.}
139 \item[Touchstone] Touchstone s2p and co. from IBIS Open Forum; \textit{Version 1 and 2.0 supported. for version 1 uses the file extension to determine the number of ports ('.snp' where n is 1-4). Noise parameter data is read and stored in self.info['noise\_param']. Mixed mode parameters of version 2.0 not supported.}
140 \end{description}
142 \section{Supported output format}
143 Writing data files is performed using Oscopy. Supported formats are:
144 \begin{description}
145 \item[gnucap] Text format from Gnucap
146 \end{description}
148 \section{Supported plots}
149 Available Graphs are:
150 \begin{description}
151 \item[linear] Standard 2D plot with X and Y axis being either linear or logarithmic
152 \end{description}
155 \chapter{IOscopy: Oscopy on top of IPython}
157 %\section{Purpose}
158 % TODO: Why using ipython: CLI already there, oscopy as a python module, power of ipython behind, flexibility
159 \section{First steps}
160 \subsection{Install dependencies}
161 Requested dependencies for building and downloading:
162 \begin{itemize}
163 \item autoconf
164 \item gettext
165 \item intltool $\ge$ 0.41.0
166 \item git
167 \end{itemize}
169 \noindent Requested dependencies for execution:
170 \begin{itemize}
171 \item python
172 \item python--gtk
173 \item ipython $\ge$ 0.13
174 \item python--numpy
175 \item python--matplotlib
176 \item python--dbus
177 \item python--xdg
178 \end{itemize}
180 \noindent Optional dependencies to run demo/demo.oscopy
181 \begin{itemize}
182 \item geda--gaf and more specifically gschem and gnetlist
183 \item gnucap
184 \end{itemize}
186 \subsubsection{Debian}
187 Tested on stable (squeeze) and unstable (sid). Will not install on stable due to default release ipython 0.10.
189 Install git, autotools and related packages:
190 \begin{lstlisting}
191 # apt-get git autoconf gettext intltool python-gtk2-dev
192 \end{lstlisting}
193 Install oscopy dependencies:
194 \begin{lstlisting}
195 # apt-get install ipython python-matplotlib
196 \end{lstlisting}
197 Optional: to execute demo.oscopy script install geda and gnucap:
198 \begin{lstlisting}
199 # apt-get install geda gnucap
200 \end{lstlisting}
202 \subsubsection{Ubuntu}
203 Tested on Ubuntu 12.10 Quantal Quetzal.
205 Install git, autotools and related packages:
206 \begin{lstlisting}
207 $ sudo apt-get install git autoconf gettext intltool python-gtk2-dev
208 \end{lstlisting} %$
209 Install oscopy dependencies:
210 \begin{lstlisting}
211 $ sudo apt-get install ipython python-matplotlib
212 \end{lstlisting} %$
213 Optional: to execute demo.oscopy script install geda and gnucap:
214 \begin{lstlisting}
215 $ sudo apt-get install ipython python-matplotlib
216 \end{lstlisting} % $
218 \subsubsection{Fedora}
219 Tested on Fedora 18.
221 Install git, autotools and related packages (maybe needed to run the command twice ?):
222 \begin{lstlisting}
223 # yum install git autoconf gettext intltool pygtk2-devel gcc
224 \end{lstlisting}
225 Install oscopy dependencies:
226 \begin{lstlisting}
227 # yum install ipython dbus-python
228 \end{lstlisting}
229 Optional: to execute demo.oscopy script install geda and gnucap:
230 \begin{lstlisting}
231 # yum install geda-gaf gnucap
232 \end{lstlisting}
233 Note that in Fedora 18 default geda-gaf and gnucap appear to be very old version and might not run demo/demo.oscopy correctly.
235 \subsection{Download the source}
236 The source can be downloaded from repo.or.cz: \href{http://repo.or.cz/w/oscopy.git}{http://repo.or.cz/w/oscopy.git}
238 To download it:
239 \begin{lstlisting}
240 $ git clone git://repo.or.cz/oscopy.git
241 \end{lstlisting} % $
243 Optional: to use the experimental branch:
244 \begin{lstlisting}
245 $ cd oscopy
246 $ git pull git://repo.or.cz/oscopy.git experimental
247 \end{lstlisting}
249 \subsection{Install oscopy}
250 IOscopy shall be compiled and installed on the system:
251 \begin{lstlisting}
252 $ cd oscopy
253 $ ./autogen.sh && ./configure && make install
254 \end{lstlisting}
255 Once installed, \texttt{PYTHONPATH} might need some update, for example if you install it in \texttt{\$\{HOME\}/geda}, to launch oscopy you might need the following line:
256 \begin{lstlisting}
257 $ export PYTHONPATH=${HOME}/geda/lib/python2.X/site-packages:$PYTHONPATH
258 $ export PATH=$PATH:${HOME}/geda/bin
259 \end{lstlisting}
260 To use gschem integration, you will need to use the same \texttt{--prefix} that you used to install gschem.
262 \subsection{Getting Started}
263 To run the program, just do
264 \begin{lstlisting}
265 ioscopy
266 \end{lstlisting}
267 This assume that ioscopy is in your \texttt{PATH}.
269 A sample circuit is provided for demonstration purposes.
270 \begin{lstlisting}
271 $ cd demo
272 $ ioscopy
273 \end{lstlisting}
274 Just select ``File$>$Run Netlister and simulate...'' and fill in the window with the commands provided below:
275 \begin{itemize}
276 \item For netlister: \lstinline!gnetlist -g spice-sdb -s -o demo.net demo.sch!
277 \item For simulator: \lstinline!gnucap -b demo.net!
278 \end{itemize}
279 then in the terminal window:
280 \begin{lstlisting}
281 oscopy> oexec demo.oscopy
282 \end{lstlisting}
284 \subsection{Integration with gschem}
285 \label{sec:gschemint}
286 To use gschem integration, add the following line to your gschemrc:
287 \begin{lstlisting}
288 (load-from-path "oscopy.scm")
289 \end{lstlisting}
290 On the next start of gschem, you should see the oscopy menu. Note that you should have done \texttt{./configure --prefix=''same prefix as gschem''} Then assuming you are in the oscopy directory:
291 \begin{itemize}
292 \item launch gschem
293 \item open demo/demo.sch
294 \item oscopy$> >$Launch oscopy
295 \item \lstinline!oscopy> oexec demo.oscopy!
296 \item Once the script finished to execute, go back to gschem and change the value of a component e.g. the capacitor C.
297 \item oscopy$> >$Update oscopy
298 \item once netlister and simulator ran, figures should have changed, e.g. figure 3 \texttt{vout} should have moved and \texttt{vo} not.
299 \end{itemize}
301 \section{IOscopy interfaces}
302 IOscopy has three main interfaces:
303 \begin{description}
304 \item[The command line] which is used to enter commands
305 \item[The Main Window] includes general file I/O, windows list and signal tree
306 \item[The figures] when instantiated
307 \end{description}
308 The two former are specific to IOscopy while the latter is a specialisation of Oscopy Figure.
309 The command line is an IPython application with customisation for Signal management.
310 All IOscopy commands are implemented as magic functions.
312 The Main Window and the figures form the IOscopy GUI and are implemented using GTK libraries.
314 \section{Command line options}
315 Command line options are reported in Tab.~\ref{tab:clio}.
316 \begin{table}[htbp]
317 \centering\sf
318 \begin{tabular}{ll}
319 \hline
320 -b& Execute an oscopy command file\\
321 -h& Show this help message\\
322 -i& Resume to command line executing after batch file\\
323 -q& Disable banner printing\\
324 \hline
325 \end{tabular}
326 \caption{Command line options}
327 \label{tab:clio}
328 \end{table}
329 \section{IOscopy Commands Reference}
330 % TODO: Detailled description of ioscopy commands with an example for each one, assuming the demo/demo.oscopy script conditions
331 This section describes the IOscopy commands. Unless otherwise noticed, examples assume that \texttt{demo/demo.oscopy} has been run.
333 \newcommand{\ocmd}[2]{\vspace{3eX}\noindent\fbox{\begin{minipage}{\linewidth}\large\noindent\textbf{#1} #2\end{minipage}}\vspace{1eX}}
335 \ocmd{oadd}{SIG [, SIG [, SIG]...]}
336 Add a graph to the current figure. Figure and graph are instanciated if not present.
338 \begin{lstlisting}
339 oscopy> oselect 1-1
340 oscopy> oadd vgs
341 \end{lstlisting}
343 \ocmd{ocreate}{[SIG [, SIG [, SIG]...]]}
344 Create a new figure, set it as current, add the signals in a first graph.
346 \begin{lstlisting}
347 oscopy> ocreate vgs,vds
348 \end{lstlisting}
350 \ocmd{ocontext}{\ }
351 Return the Context object used within ioscopy.
352 Use it only if you want to have direct access to internal ioscopy objects.
354 \ocmd{odelete}{GRAPH\#}
355 Delete a graph from the current figure.
357 \begin{lstlisting}
358 oscopy> odelete 1
359 \end{lstlisting}
361 \ocmd{odestroy}{FIG\#}
362 Destroy a figure
364 \begin{lstlisting}
365 oscopy> odestroy 3
366 \end{lstlisting}
368 \ocmd{oexec}{FILENAME}
369 Execute commands from file.
371 This following example assumes that demo/demo.oscopy has \textbf{not} been run.
373 \begin{lstlisting}
374 oscopy> oexec demo/demo.oscopy
375 \end{lstlisting}
377 \ocmd{ofactors}{X, Y}
378 Set the scaling factor of the graph (in powers of ten). Use \texttt{auto} for automatic scaling factor.
380 \noindent The following example sets the scale factor at 1e-3 for X axis and 10e6 for Y axis
381 \begin{lstlisting}
382 oscopy> oselect 1-1
383 oscopy> ofactor -3, 3
384 \end{lstlisting}
386 \ocmd{ofiglist}{\ }
387 Print the list of figures. The layout of the figure is indicated, and the graph mode as well as the Signals are shown. The current figure and graph are marked with a star.
388 \begin{lstlisting}
389 oscopy>ofiglist
390 Figure 1: horiz
391 Graph 1 : (linear) vgs
392 Graph 2 : (linear) vsqu
393 Figure 2: quad
394 Graph 1 : (linear) iRD
395 Graph 2 : (linear) vgs
396 Graph 3 : (linear) vds vgs
397 Graph 4 : (linear) vds
398 Figure 3: horiz
399 Graph 1 : (linear) vout vo
400 Figure 4: horiz
401 Graph 1 : (linear) vsqu
402 Graph 2 : (linear) vsqufft
403 Graph 3 : (linear) v1
404 * Figure 5: horiz
405 * Graph 1 : (linear) vs
406 \end{lstlisting}
408 \ocmd{ofreeze}{SIG [, SIG [, SIG]...]}
409 Do not consider signal for subsequent updates. See also \textbf{ounfreeze}.
410 \begin{lstlisting}
411 oscopy> ofreeze vout,vds
412 \end{lstlisting}
414 \ocmd{ogui}{\ }
415 Show the GUI window if it was closed.
417 \ocmd{oimport}{SIG [, SIG [, SIG]...]}
418 Import a list of signals into oscopy to handle dependencies during updates
419 \begin{lstlisting}
420 oscopy> pwr=iRD*vds
421 oscopy> oimport pwr
422 oscopy> ocreate pwr
423 oscopy> oupdate #if iRD or vds changed, pwr will be automatically updated
424 \end{lstlisting}
426 \ocmd{oinsert}{SIG [, SIG [, SIG]...]}
427 Insert a list of signals into the current graph
428 \begin{lstlisting}
429 oscopy> oselect 1-1
430 oscopy> oinsert vds
431 \end{lstlisting}
433 \ocmd{olayout}{horiz$|$vert$|$quad}
434 Define the layout of the current figure
435 \begin{description}
436 \item[olayout horiz] Graphs are stacked from top to bottom
437 \item[olayout vert] Graphs are side by side from left to right
438 \item[olayout quad] One graph per figure corner
439 \end{description}
440 \begin{lstlisting}
441 oscopy> oselect 2-1
442 oscopy> olayout horiz
443 oscopy> olayout vert
444 oscopy> olayout quad
445 \end{lstlisting}
447 \ocmd{omode}{MODE}
448 Set the type of the current graph of the current figure\\
449 Available modes:
450 \begin{description}
451 \item[omode lin] Linear graph
452 \end{description}
454 \ocmd{orange}{[x$|$y min max]$|$[xmin xmax ymin ymax]$|$[reset]}
455 Set the axis range of the current graph of the current figure
456 \begin{description}
457 \item[orange x xmin xmax] set x axis range
458 \item[orange y ymin ymax] set y axis range
459 \item[orange xmin xmax ymin ymax] set both axis range
460 % \item[orange reset] set automatic range on both axis
461 \end{description}
462 \begin{lstlisting}
463 oscopy> oselect 1-1
464 oscopy> orange x 0 1
465 oscopy> orange y -4 12
466 oscopy> orange 0.5 0.6 -2 2
467 \end{lstlisting}
469 \ocmd{oread}{DATAFILE}
470 Read signal file
471 \begin{lstlisting}
472 oscopy> oread demo/tran.dat
473 \end{lstlisting}
475 \ocmd{orefresh}{FIG\#$|$current$|$all$|$on$|$off}
476 Force/toggle autorefresh of current/\#/all figures on update
477 \begin{description}
478 \item[orefresh FIG\#] refresh figure \#
479 \item[orefresh current] refresh current figure
480 \item[orefresh all] refresh all figures
481 \item[orefresh on] turn on autorefresh on Signal updates
482 \item[orefresh off] turn off autorefresh on Signal updates
483 \end{description}
485 \begin{lstlisting}
486 oscopy> orefresh 3
487 oscopy> orefresh on
488 \end{lstlisting}
490 \ocmd{oremove}{SIG [, SIG [, SIG]...]}
491 Delete a list of signals into from current graph
492 \begin{lstlisting}
493 oscopy> oselect oselect 2-3
494 oscopy> oremove vds
495 \end{lstlisting}
497 \ocmd{oscale}{[lin$|$logx$|$logy$|$loglog]}
498 Set the axis scale
499 \begin{description}
500 \item[oscale lin] Set linear scale on both axis
501 \item[oscale logx] Set log scale on x axis and linear scale on y axis
502 \item[oscale logy] Set linear scale on x axis and log scale on y axis
503 \item[oscale loglog] Set log scale on both axis
504 \end{description}
506 \begin{lstlisting}
507 oscopy> oselect 3-1
508 oscopy> oscale logx
509 oscopy> oscale loglog
510 \end{lstlisting}
512 \ocmd{oselect}{FIG\#-GRAPH\#}
513 Select the current figure and the current graph
514 \begin{lstlisting}
515 oscopy> oselect 2-1
516 \end{lstlisting}
518 \ocmd{osiglist}{\ }
519 List loaded signals
520 \begin{lstlisting}
521 oscopy> siglist
522 Name Unit Ref Reader Last updated (sec)
523 vds V Time demo/irf540.dat 128
524 iRD A Time demo/irf540.dat 128
525 vgs V Time demo/irf540.dat 128
526 vsqu V Time demo/tran.dat 124
527 v1 None Time v1=((vsqu * 3) + 10) 123
528 vout V Freq demo/ac.dat 126
529 vs None Time vs=sin((Time * 1000000.0)) 121
530 vs2 V Time vs2=sin((Time * 1000000.0)) 121
531 vo V Freq vo=vout 121
532 vsqufft Frequency vsqufft=fft(vsqu) 124
533 \end{lstlisting}
535 \ocmd{ounfreeze}{SIG [, SIG [, SIG]...]}
536 Consider signal for subsequent updates. See also \textbf{ofreeze}
537 \begin{lstlisting}
538 oscopy> ounfreeze vout,vds
539 \end{lstlisting}
541 \ocmd{ounit}{[XUNIT,] YUNIT}
542 Set the unit to be displayed on graph axis
543 \begin{description}
544 \item[ounit XUNIT, YUNIT] Set both axis unit
545 \item[ounit YUNIT] Set Y axis unit
546 \end{description}
548 \begin{lstlisting}
549 oscopy> oselect 3-1
550 oscopy> ounit W # Set Y axis unit
551 oscopy> ounit /s,W # Set both axis unit
552 oscopy> ounit Hz, V
553 \end{lstlisting}
555 \ocmd{oupdate}{\ }
556 Reread data files.
558 \begin{lstlisting}
559 oscopy> oupdate
560 \end{lstlisting}
562 \ocmd{owrite}{format [(OPTIONS)] FILE SIG [, SIG [, SIG]...]}
563 Write signals to file.
564 Options common to all formats are:
565 \begin{description}
566 \item[ow] If \texttt{True} or 1 overwrite existing file
567 \end{description}
569 \noindent This example writes signals v1 and vsqu to the file \texttt{demo/res.dat} using format gnucap format,
570 overwriting the file if it already exists.
571 \begin{lstlisting}
572 oscopy> owrite gnucap (ow:1) demo/res.dat v1,vsqu
573 \end{lstlisting}
574 \newpage
575 \chapter{Oscopy GUI}
576 % TODO: Description of the GUI interface, main window, menus, contextual menus, buttons
577 The Graphical User Interface of oscopy is composed of several windows (Figure \ref{fig:screenshot}):
578 \begin{itemize}
579 \item The command line terminal
580 \item The main window
581 \item The (many) figures windows
582 \end{itemize}
583 The next paragraphs describe the two last types.
585 \begin{figure}[htbp]
586 \centering
587 \includegraphics[width=.8\textwidth]{../png/ioscopy.png}
588 \caption{ioscopy after running \texttt{demo/demo.oscopy}}
589 \label{fig:screenshot}
590 \end{figure}
592 \section{The main window}
593 This is the first window that you will see when starting ioscopy.
594 At anytime, it can be shown again by calling the command \texttt{ogui} from the terminal if closed.
596 It contains the list of Readers and their Signals currently handled by ioscopy.
597 Double--clicking on a Signal inserts it in a new Figure.
599 Each Signal 'freeze' status can be toggled using the checkbox located in the right column.
600 Toggling the checkbox for a Reader set the status for all the signals contained in the Reader.
602 The 'File' menu:
603 \begin{description}
604 \item[Add file(s)...] To read Signals from file(s)
605 \item[Update] To read Signals from file(s) again
606 \item[Execute script...] To read ioscopy commands from file
607 \item[New Math Signal] To compute a new Signal from existing ones
608 \item[Run netlister and simulate] To generate the netlist, run the simulator and eventually update the Signals (Figure~\ref{fig:netnsim})
609 \item[Quit] Exit ioscopy
610 \end{description}
612 \noindent The 'Windows' menu contains the list of the windows, and select one to show it.
614 % description des menus
615 % description de la liste (+ freeze fichier entier ou signal par signal)
617 \begin{figure}[htbp]
618 \centering
619 \includegraphics[scale=.5]{../png/ioscopy-gui.png}
620 \caption{The main window}
621 \label{fig:mainwin}
622 \begin{minipage}{.45\linewidth}
623 \includegraphics[scale=.5]{../png/ioscopy-file.png}
624 \caption{The 'File' menu}
625 \label{fig:filemenu}
626 \end{minipage}
627 \begin{minipage}{.45\linewidth}
628 \includegraphics[scale=.5]{../png/ioscopy-window.png}
629 \caption{The 'Window' menu}
630 \label{fig:windowmenu}
631 \end{minipage}
633 \includegraphics[scale=.5]{../png/ioscopy-netnsim.png}
634 \caption{The 'Run netlister and simulate' window. Call third party programs to generate oscopy input files. Can be toggled with the checkboxes. Setting are saved in .config/oscopy/gui file}
635 \label{fig:netnsim}
637 \end{figure}
639 \noindent Available mouse operations:
640 \begin{description}
641 \item[left] Select signal
642 \item[double left] Insert signal in new Figure
643 \item[right] Show 'Insert signal' menu
644 \end{description}
646 \section{The Figure windows}
648 % description de l'agencement de la fenĂȘtre
649 % description du menu contextuel et des sous-menus
650 Each Figure window is composed of two parts:
651 \begin{itemize}
652 \item On the top part, a zone containing up to 4 graphs
653 \item On the bottom part, the Matplotlib toolbar
654 \item On the right part, the Operation bar
655 \end{itemize}
656 A contextual menu is available for each graph, raised by a right-click on the mouse button.
657 Access to most of the ioscopy functionality is possible through this menu:
658 \begin{itemize}
659 \item Add/delete graph
660 \item Layout (Figure~\ref{fig:layout})
661 \item Range settings (Figure~\ref{fig:range})
662 \item Unit settings (Figure~\ref{fig:units})
663 \item Scale (Figure~\ref{fig:scale})
664 % Insert Signal not available anymore as per commit 084a6d87:
665 % the call to Context.create is delegated to UI. Furthermore, the Graph is
666 % not anymore aware of Context's Signals.
667 %\item Insert Signal (Figure~\ref{fig:insert})
668 \item Remove Signal (Figure~\ref{fig:remove})
669 \end{itemize}
671 For each Graph, cursors are available through keys (Figure~\ref{fig:cursors}):
672 \begin{itemize}
673 \item \texttt{'1'} for first vertical cursor
674 \item \texttt{'2'} for second vertical cursor
675 \item \texttt{'3'} for first horizontal cursor
676 \item \texttt{'4'} for second horizontal cursor
677 \end{itemize}
678 The value of each cursor is displayed on the bottom part of the graph, and the difference when both cursors are activated.
680 \noindent Available mouse operations:
681 \begin{description}
682 \item[left] In a graph and when 'span' is selected, define region for zooming
683 \item[roll] In a graph, Zoom in / Zoom out
684 %\item[double left] Insert signal in new Figure
685 \item[right] Show 'Contextual signal' menu. Sensitive to position, e.g. Graph-related items are only available when mouse is over a Graph.
686 \end{description}
689 \subsection{The Operation Bar}
691 This bar is used to set options for all the Graphs at the same time or for a particular Graph.
692 The target Graph is selected through the top-most combo-box.
693 \begin{description}
694 \item[Master pan] When scroll bars are moved, move also all Graphs with same X unit than selected.
695 \item[Zoom x10] When enabled, the graph range is expanded at a x10 scale, keeping the center of the view. When disabled, return to full range. E.g. if the initial range is [6 .. 11] and the data range is [0 .. 20], the x10 range will be [7.5 .. 9.5] and will be [0 .. 20] on disabling.
696 \item[Span] When enabled, use mouse--left to zoom in a region of a Graph (Figure~\ref{fig:span}). Region selection is made upon the Figure layout configuration:
697 \begin{description}
698 \item[horizontal] Region is selected on X axis
699 \item[vertical] Region is selected on Y axis
700 \item[quad] Region is selected on both axis
701 \end{description}
702 \item[Export] Save figure as image
703 \end{description}
705 \begin{figure}[htbp]
706 \centering
707 \includegraphics[scale=.5]{../png/ioscopy-figure}
708 \caption{A Figure window with the contextual menu.}
709 \label{fig:fig}
711 \begin{minipage}{0.45\linewidth}
712 \includegraphics[scale=.5]{../png/ioscopy-layout.png}
713 \caption{Layout configuration menu}
714 \label{fig:layout}
715 \end{minipage}
716 \begin{minipage}{0.45\linewidth}
717 \includegraphics[scale=.5]{../png/ioscopy-scale.png}
718 \caption{Scale configuration menu}
719 \label{fig:scale}
720 \end{minipage}
722 \begin{minipage}{0.95\linewidth}
723 \includegraphics[scale=.5]{../png/ioscopy-insert.png}
724 \caption{Insert signal menu}
725 \label{fig:insert}
726 \end{minipage}
728 \end{figure}
730 \begin{figure}[htbp]
731 \centering
732 \includegraphics[scale=.5]{../png/ioscopy-remove.png}
733 \caption{Remove signal menu}
734 \label{fig:remove}
736 \includegraphics[scale=.5]{../png/ioscopy-range.png}
737 \caption{Dialogue to set graph range}
738 \label{fig:range}
740 \includegraphics[scale=.5]{../png/ioscopy-units.png}
741 \caption{Dialogue to set graph units}
742 \label{fig:units}
744 \includegraphics[scale=.5]{../png/ioscopy-cursors.png}
745 \caption{Figure with cursors set (after changing capacitance value of \texttt{demo.sch} and running netlister and simulator}
746 \label{fig:cursors}
748 \end{figure}
750 \begin{figure}[htbp]
751 \centering
752 \includegraphics[scale=.5]{../png/ioscopy-span.png}
753 \caption{Select region for zooming. Here with horizontal layout.}
754 \label{fig:span}
755 \end{figure}
757 \appendix
758 \chapter{IOscopy commands quick reference guide}
759 \begin{landscape}
760 \begin{table}[htbp]
761 \centering\sf
762 \begin{tabular}{lll}
763 \hline
764 Command & Arguments & Description \\
765 \hline
766 oadd & SIG [, SIG [, SIG]...] &Add a graph to the current figure\\
767 ocontext& & Return the Context object used within ioscopy.\\
768 & &Use it only if you want to have direct access to internal ioscopy objects.\\
769 ocreate & [SIG [, SIG [, SIG]...] ]&Create a new figure, set it as current, add the signals\\
770 odelete & GRAPH\# &Delete a graph from the current figure\\
771 odestroy & FIG\# &Destroy a figure\\
772 oexec & FILENAME &execute commands from file\\
773 ofactors & X, Y &set the scaling factor of the graph (in power of ten) use 'auto' for automatic\\
774 & & scaling factor e.g. factor -3, 6 set the scale factor at 1e-3 and 10e6\\
775 ofiglist & &Print the list of figures\\
776 ofreeze & SIG [, SIG [, SIG]...] &Do not consider signal for subsequent updates\\
777 ogui & & Show the GUI\\
778 oimport& SIG [, SIG [, SIG]...] & Import a list of signals into oscopy to handle dependencies during updates\\
779 oinsert & SIG [, SIG [, SIG]...] &Insert a list of signals into the current graph\\
780 olayout & horiz | vert | quad&Define the layout of the current figure\\
781 omode & MODE &Set the type of the current graph of the current figure\\
782 & &Available modes :\\
783 & & lin Linear graph\\
784 orange & [x | y min max] | [xmin xmax ymin ymax] &Set the axis range of the current graph of the current figure\\
785 oread & DATAFILE &read signal file\\
786 orefresh & FIG\# | on | off | current | all& Force/toggle autorefresh of current/\#/all figures on update\\
787 oremove & SIG [, SIG [, SIG]...] &Delete a list of signals into from current graph\\
788 oscale & [lin | logx | logy | loglog] &Set the axis scale\\
789 oselect & FIG\#-GRAPH\# &Select the current figure and the current graph\\
790 osiglist & &List loaded signals\\
791 ounfreeze & SIG [, SIG [, SIG]...] &Consider signal for subsequent updates\\
792 ounit & [XUNIT,] YUNIT &Set the unit to be displayed on graph axis\\
793 oupdate & &Reread data files\\
794 owrite & format [(OPTIONS)] FILE SIG [, SIG [, SIG]...] &Write signals to file\\
795 \hline
796 \end{tabular}
797 \caption{Summary of IOscopy commands}
798 \label{tab:cmds:summary}
799 \end{table}
800 \end{landscape}
803 \end{document}
805 %%% Local Variables:
806 %%% Local IspellDict: british
807 %%% mode: latex
808 %%% TeX-master: t
809 %%% End: