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

<root>
  <func>


    <title>cnc_rdpm_item</title>



    <declare>
      <vc>
        <include>#include "fwlib32.h"</include>
        <prottype>FWLIBAPI short WINAPI cnc_rdpm_item(unsigned short FlibHndl, short start_num, short* data_num, IODBPMAINTE* item);</prottype>
      </vc>
    </declare>



    <doc>
        <cmn>
            Reads all data specified by the item index.<br/>
            The acquired data is as follows.
            <dl>
                <dd>- Name</dd>
                <dd>- Life count type</dd>
                <dd>- Life time data</dd>
                <dd>- Life remained time data</dd>
                <dd>- Life count state</dd>
            </dl>
        </cmn>
    </doc>



    <argument>
        <common>
            <vc>
                <item>
                    <name>FlibHndl</name>
                    <type>in</type>
                    <content>
                        <p>
                            Specify the library handle. See "<a href="handle.htm" target="_parent">Library handle</a>" for details.
                        </p>
                    </content>
                </item>
                <item>
                    <name>start_num</name>
                    <type>in</type>
                    <content>
                        Specify the starting item index to be read. (1..10)
                    </content>
                </item>
                <item>
                    <name>data_num</name>
                    <type>in/out</type>
                    <content>
                        Specify the pointer for the number of items to be read.<br/>
                        This function returns the item number that is actually read.
                    </content>
                </item>
                <item>
                    <name>item</name>
                    <type>out</type>
                    <content>
                        <p>
                            Specify the pointer to the array of IODBPMAINTE structure.<br/>
                            The array of the structure specified by (*data_num) is required.
                        </p>
The IODBPMAINTE  structure is as follows.
<pre>
typedef struct tagIODBPMAINTE {
    char  name[62];     /* Name string */
    long  type;         /* Life count type */
    long  total;        /* Life time (unit:minute) */
    long  remain;       /* Life remained time */
    long  stat;         /* Life count state */
} IODBPMAINTE;
</pre>
            <dt>name</dt>
            <dd>Name string</dd>
            <dd>This data is terminated with 'NULL'.</dd>

            <dt>type</dt>
            <dd>Life count type</dd>
            <dd>
                        <table class="dd">
                            <tr><td>0</td><td>:</td><td>Invalidity</td></tr>
                            <tr><td>1</td><td>:</td><td>All time  </td></tr>
                            <tr><td>2</td><td>:</td><td>Power on  </td></tr>
                            <tr><td>3</td><td>:</td><td>Running   </td></tr>
                            <tr><td>4</td><td>:</td><td>Cutting   </td></tr>
                        </table>
            </dd>

            <dt>total</dt>
            <dd>Life time</dd>
            <dd>In case of 16i/18i/21i, unit is "hour".</dd>
            <dd>In case of 30i/31i/32i, unit is "minute".</dd>

            <dt>remain</dt>
            <dd>Life remained time</dd>
            <dd>In case of 16i/18i/21i, unit is "hour".</dd>
            <dd>In case of 30i/31i/32i, unit is "minute".</dd>

            <dt>stat</dt>
            <dd>Life count state</dd>
                        <dd>16i/18i/21i is unused. "0" is set.</dd>
                    </content>
                </item>
            </vc>
        </common>
    </argument>



    <errcode>
        <item>
            <name>EW_LENGTH</name>
            <content>data block length error<br/>The number of items to be read(*data_num) is 0.</content>
        </item>
        <item>
            <name>EW_NUMBER</name>
            <content>data number error<br/>The starting item index to be read(start_num) is invalid.</content>
        </item>
        <add></add>
    </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>However, in case of Series 160i/180i/210i/0i MODEL B and 300i, the required CNC option is as follows.</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>
        <add></add>
    </option>



    <parameter></parameter>



    <mode></mode>



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



    <reference>
        <item>
            <name>cnc_wrpm_item</name>
            <file>misc/cnc_wrpm_item.htm</file>
        </item>
    </reference>



    <example></example>



  </func>
</root>
