Spaces:
Sleeping

XCos_MCP / data /help /Signalrouting_pal /M_SWITCH.xml
xcos-bot
Deploy snapshot from 23aafd1a (verified archive)
39e01c4
Raw History Blame Contribute Delete
8.74 kB
<?xml version="1.0" encoding="UTF-8"?>
<!--
* Scicos
*
* Copyright (C) INRIA - METALAU Project <scicos@inria.fr> (HTML version)
* Copyright (C) DIGITEO - Scilab Consortium (XML Docbook version)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* See the file ./license.txt
-->
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML"
xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org"
xml:id="M_SWITCH" xml:lang="en_US">
<refnamediv>
<refname>M_SWITCH</refname>
<refpurpose>Multi-port switch</refpurpose>
</refnamediv>
<refsection>
<title>Block Screenshot</title>
<inlinemediaobject>
<imageobject>
<imagedata fileref="../../../../images/palettes/M_SWITCH.png" align="center"/>
</imageobject>
</inlinemediaobject>
</refsection>
<refsection id="Contents_M_SWITCH">
<title>Contents</title>
<itemizedlist>
<listitem>
<xref linkend="Description_M_SWITCH">Description</xref>
</listitem>
<listitem>
<xref linkend="Dialogbox_M_SWITCH">Parameters</xref>
</listitem>
<listitem>
<xref linkend="Defaultproperties_M_SWITCH">Default properties</xref>
</listitem>
<listitem>
<xref linkend="Interfacingfunction_M_SWITCH">Interfacing function</xref>
</listitem>
<listitem>
<xref linkend="Computationalfunction_M_SWITCH">Computational function</xref>
</listitem>
</itemizedlist>
</refsection>
<refsection id="Description_M_SWITCH">
<title>Description</title>
<para>
The Multi-Port Switch block chooses between a number of inputs. The
first (top) input is called the control input, while the rest of the
inputs are called data inputs. The value of the control input
determines which data input is passed through to the output port.
</para>
</refsection>
<refsection id="Dialogbox_M_SWITCH">
<title>Parameters</title>
<inlinemediaobject>
<imageobject>
<imagedata fileref="../../../../images/gui/M_SWITCH_gui.gif" align="center" style="float:right"/>
<!-- align => Javahelp, style => Online -->
</imageobject>
</inlinemediaobject>
<itemizedlist>
<listitem>
<para>
<emphasis role="bold">number of inputs</emphasis>
</para>
<para> Specify the number of data inputs to the block.</para>
<para> Properties : Type 'vec' of size 1 </para>
</listitem>
<listitem>
<para>
<emphasis role="bold">zero base indexing </emphasis>
</para>
<para> If selected, the block uses zero-based indexing. Otherwise, the block uses
one-based indexing.
</para>
<para> Properties : Type 'vec' of size 1 </para>
</listitem>
<listitem>
<para>
<emphasis role="bold">rounding rule: int </emphasis>
</para>
<para> Select the rounding mode for the output.</para>
<para> Properties : Type 'vec' of size 1</para>
</listitem>
</itemizedlist>
</refsection>
<refsection id="Defaultproperties_M_SWITCH">
<title>Default properties</title>
<itemizedlist>
<listitem>
<para>
<emphasis role="bold">always active:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">direct-feedthrough:</emphasis> yes
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">zero-crossing:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">mode:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">regular inputs:</emphasis>
</para>
<para>
<emphasis role="bold">- port 1 : size [1,1] / type 1</emphasis>
</para>
<para>
<emphasis role="bold">- port 2 : size [-1,1] / type 0</emphasis>
</para>
<para>
<emphasis role="bold">- port 3 : size [-1,1] / type 1</emphasis>
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">regular outputs:</emphasis>
</para>
<para>
<emphasis role="bold">- port 1 : size [-1,1] / type 1</emphasis>
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">number/sizes of activation inputs:</emphasis> 0
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">number/sizes of activation outputs:</emphasis> 0
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">continuous-time state:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">discrete-time state:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">object discrete-time state:</emphasis> no
</para>
</listitem>
<listitem>
<para>
<emphasis role="bold">name of computational function:</emphasis>
<emphasis role="italic">mswitch</emphasis>
</para>
</listitem>
</itemizedlist>
<para/>
</refsection>
<refsection id="Examples_M_SWITCH">
<title>Example</title>
<refsection id="Example_M_SWITCH_1">
<title>Example 1</title>
<para>This sample model demonstrates signal selection with different parameters : with a 0 or 1 indexation and with different rounding modes.
</para>
<para>
<link type="scilab" linkend="scilab.xcos/xcos/examples/signalrouting_pal/M_SWITCH.zcos">
<inlinemediaobject>
<imageobject>
<imagedata align="center" fileref="../../../../examples/signalrouting_pal/M_SWITCH.zcos" valign="middle"/>
</imageobject>
</inlinemediaobject>
</link>
</para>
<scilab:image><![CDATA[
importXcosDiagram(SCI + "/modules/xcos/examples/signalrouting_pal/M_SWITCH.zcos");
xcos_simulate(scs_m, 4);
]]></scilab:image>
</refsection>
</refsection>
<refsection id="Interfacingfunction_M_SWITCH">
<title>Interfacing function</title>
<itemizedlist>
<listitem>
<para> SCI/modules/scicos_blocks/macros/Branching/M_SWITCH.sci</para>
</listitem>
</itemizedlist>
</refsection>
<refsection id="Computationalfunction_M_SWITCH">
<title>Computational function</title>
<itemizedlist>
<listitem>
<para> SCI/modules/scicos_blocks/src/c/mswitch.c (Type 4)</para>
</listitem>
</itemizedlist>
</refsection>
</refentry>