Imported Upstream version 3.2.2
[debian/gnuradio] / grc / blocks / gr_add_const_vxx.xml
1 <?xml version="1.0"?>
2 <!--
3 ###################################################
4 ##Add Const Block:
5 ##      all types, 1 output, 1 input & const
6 ###################################################
7  -->
8 <block>
9         <name>Add Const</name>
10         <key>gr_add_const_vxx</key>
11         <import>from gnuradio import gr</import>
12         <make>gr.add_const_v$(type.fcn)($const)</make>
13         <callback>set_k($const)</callback>
14         <param>
15                 <name>IO Type</name>
16                 <key>type</key>
17                 <type>enum</type>
18                 <option>
19                         <name>Complex</name>
20                         <key>complex</key>
21                         <opt>const_type:complex_vector</opt>
22                         <opt>fcn:cc</opt>
23                 </option>
24                 <option>
25                         <name>Float</name>
26                         <key>float</key>
27                         <opt>const_type:real_vector</opt>
28                         <opt>fcn:ff</opt>
29                 </option>
30                 <option>
31                         <name>Int</name>
32                         <key>int</key>
33                         <opt>const_type:int_vector</opt>
34                         <opt>fcn:ii</opt>
35                 </option>
36                 <option>
37                         <name>Short</name>
38                         <key>short</key>
39                         <opt>const_type:int_vector</opt>
40                         <opt>fcn:ss</opt>
41                 </option>
42         </param>
43         <param>
44                 <name>Constant</name>
45                 <key>const</key>
46                 <value>0</value>
47                 <type>$type.const_type</type>
48         </param>
49         <param>
50                 <name>Vec Length</name>
51                 <key>vlen</key>
52                 <value>1</value>
53                 <type>int</type>
54         </param>
55         <check>len($const) == $vlen</check>
56         <check>$vlen &gt; 0</check>
57         <sink>
58                 <name>in</name>
59                 <type>$type</type>
60                 <vlen>$vlen</vlen>
61         </sink>
62         <source>
63                 <name>out</name>
64                 <type>$type</type>
65                 <vlen>$vlen</vlen>
66         </source>
67 </block>