<?xml version="1.0" encoding="Shift_JIS"?>
<?xml-stylesheet type="text/xsl" href="../Fmethod_xsl/fmethod_he_c.xsl"?>

<root>
  <func>


    <title>cnc_rdtlctldata</title>



    <declare>
      <vc>
        <include>#include "fwlib32.h"</include>
        <prottype>
            FWLIBAPI short WINAPI cnc_rdtlctldata(unsigned short FlibHndl, IODBTLCTL *tlctl);
        </prottype>
      </vc>
    </declare>



    <doc>
        <cmn>
            <p>
                Reads the tool control data.<br/>
                The data is stored in each member of the IODBTLCTL structure( user define type ).
            </p>
        </cmn>
    </doc>



    <argument>
        <common>
            <vc>
                <item>
                    <name>FlibHndl</name>
                    <type>in</type>
                    <content>
                        <p>
                            Specify the library handle.<br/>
                            See "<a href="handle.htm" target="_parent">Library handle</a>" for details.
                        </p>
                    </content>
                </item>
                <item>
                    <name>tlctl</name>
                    <type>out</type>
                    <content>
                        <p>
                           Pointer to the IODBTLCTL structure including the tool control data.<br/>
                           The IODBTLCTL structure is as follows.
                        </p>
<pre>
typedef struct iodbtlctl {
    short   slct;          /* Flag of valid data */
    short   used_tool;     /* Number of used tool */
    short   turret_indx;   /* Number of turret index */
    long    zero_tl_no;    /* Zero point tool number */
    long    t_axis_move;   /* Turret axis movement */
    long    total_punch[2];/* Total number of punch operation*/
    short   reserve[11];   /* (reserve) */
} IODBTLCTL ;
</pre>
                        <dl>
                            <dt>slct</dt>
                            <dd>Flag of valid data is set.
                                <table class="dd">
                                    <tr><td>bit 0</td><td>:</td><td>Number of used tool</td></tr>
                                    <tr><td>bit 1</td><td>:</td><td>Number of turret index</td></tr>
                                    <tr><td>bit 2</td><td>:</td><td>Zero point tool number</td></tr>
                                    <tr><td>bit 3</td><td>:</td><td>Turret axis movement</td></tr>
                                    <tr><td>bit 4</td><td>:</td><td>Total number of punch operation</td></tr>
                                </table>
                                <table class="dd">
                                    <tr><td>bit 5,..,15</td><td>:</td><td>(reserve)</td></tr>
                                </table>
                            * When a bit is 0, it means the corresponding data has no meaning.
                            </dd>
                            <br/>
                            <dt>used_tool</dt>
                            <dd>Number of used tool is set. (0,..)</dd>
                            <br/>
                            <dt>turret_indx</dt>
                            <dd>Number of turret index is set. (0,..)
                                (This must be fewer than number of used tool.)</dd>
                            <br/>
                            <dt>zero_tl_no</dt>
                            <dd>Zero point tool number is set. (0,..)</dd>
                            <br/>
                            <dt>t_axis_move</dt>
                            <dd>Turret axis movement is set.</dd>
                            <br/>
                            <dt>total_punch</dt>
                            <dd>Total number of punch operation is set.
                                <table class="dd">
                                    <tr><td>total_punch[0]</td><td>:</td><td>Lower (0,..,99999999)</td></tr>
                                    <tr><td>total_punch[1]</td><td>:</td><td>Upper (0,..,99999999)</td></tr>
                                </table>
                            </dd>
                            <br/>
                            <dt>reserve</dt>
                            <dd>(reserve)</dd>
                        </dl>
                    </content>
                </item>
            </vc>
        </common>
    </argument>



    <errcode>
        <item>
            <name>EW_FUNC</name>
            <content>
                Unavailable<br/>
                This function cannot be used except 160i/180i-P
            </content>
        </item>
        <item>
            <name>EW_NOOPT</name>
            <content>
                No option<br/>
                The extended driver/library function is necessary.
            </content>
        </item>
    </errcode>



    <option>
        <hssb>The extended driver/library function is necessary.</hssb>
        <ethr><p>The Ethernet function and the extended driver/library function are necessary.</p>
              <p>When Embedded Ethernet is used,</p>
              <p><ul>above two optional functions are not required.</ul></p>
              <p>When Ethernet board is used,</p>
              <p><ul>only Ethernet function is required.</ul></p>
        </ethr>
        <type>Tool data setting function</type>
    </option>



    <parameter>
        <type>
            <li>Series 160i/180i</li>
            <div class="dd">16265,..,16270</div>
        </type>
    </parameter>



    <mode>
    </mode>



    <support>
        <m>
            <fs0ia>-</fs0ia>
            <fs0ib>-</fs0ib>
            <fs15>-</fs15>
            <fs15i>-</fs15i>
            <fs16>-</fs16>
            <fs18>-</fs18>
            <fs21>-</fs21>
            <fs16ia>-</fs16ia>
            <fs18ia>-</fs18ia>
            <fs21ia>-</fs21ia>
            <fs16ib>-</fs16ib>
            <fs18ib>-</fs18ib>
            <fs21ib>-</fs21ib>
            <fs30i>-</fs30i>
        </m>
        <t>
            <fs0ia>-</fs0ia>
            <fs0ib>-</fs0ib>
            <fs15>-</fs15>
            <fs15i>-</fs15i>
            <fs16>-</fs16>
            <fs18>-</fs18>
            <fs21>-</fs21>
            <fs16ia>-</fs16ia>
            <fs18ia>-</fs18ia>
            <fs21ia>-</fs21ia>
            <fs16ib>-</fs16ib>
            <fs18ib>-</fs18ib>
            <fs21ib>-</fs21ib>
            <fs30i>-</fs30i>
        </t>
        <lc>
            <fs0ia>-</fs0ia>
            <fs0ib>-</fs0ib>
            <fs15>-</fs15>
            <fs15i>-</fs15i>
            <fs16>-</fs16>
            <fs18>-</fs18>
            <fs21>-</fs21>
            <fs16ia>-</fs16ia>
            <fs18ia>-</fs18ia>
            <fs21ia>-</fs21ia>
            <fs16ib>-</fs16ib>
            <fs18ib>-</fs18ib>
            <fs21ib>-</fs21ib>
            <fs30i>-</fs30i>
        </lc>
        <p>
            <fs16i>O</fs16i>
            <fs18i>O</fs18i>
        </p>
        <l>
            <fs16i>-</fs16i>
            <fs18i>-</fs18i>
        </l>
        <w>
            <fs16i>-</fs16i>
            <fs18i>-</fs18i>
        </w>
        <pw>
            <d>-</d>
            <h>-</h>
        </pw>
    </support>



    <reference>
        <item>
            <name>cnc_wrtlctldata</name>
            <file>Punch/cnc_wrtlctldata.htm</file>
        </item>
        <item>
            <name>cnc_rdtooldata</name>
            <file>Punch/cnc_rdtooldata.htm</file>
        </item>
        <item>
            <name>cnc_wrtooldata</name>
            <file>Punch/cnc_wrtooldata.htm</file>
        </item>
        <item>
            <name>cnc_rdmultitldt</name>
            <file>Punch/cnc_rdmultitldt.htm</file>
        </item>
        <item>
            <name>cnc_wrmultitldt</name>
            <file>Punch/cnc_wrmultitldt.htm</file>
        </item>
        <item>
            <name>cnc_rdtoolinfo</name>
            <file>Punch/cnc_rdtoolinfo.htm</file>
        </item>
    </reference>



    <example>
    </example>



  </func>
</root>
