<!-- Converted to DocBook/SGML by Kevin Conder -->
<refentry id="timeinsts">
  <refmeta>
    <refentrytitle>timeinsts</refentrytitle>
  </refmeta>
 
  <refnamediv>
    <refname>timeinsts</refname>

    <refpurpose>
      Read absolute time in seconds.
      <indexterm id="IndexTimeinsts"><primary>timeinsts</primary></indexterm>
    </refpurpose>
  </refnamediv>
 
  <refsect1>
    <title>Description</title>
    <para>
      Read absolute time, in seconds, since the start of an instance of an instrument.
    </para>
  </refsect1>
 
  <refsect1>
    <title>Syntax</title>
    <synopsis>kr <command>timeinsts</command></synopsis>
  </refsect1>

  <refsect1>
    <title>Performance</title>
    <para>
      Time in seconds is available with <emphasis>timeinsts</emphasis>. This would return 0.5 after half a second.
    </para>

    <para>
      <emphasis>timeinsts</emphasis> produces a k-rate variable for output. There are no input parameters.
    </para>

    <para>
      <emphasis>timeinsts</emphasis> is similar to <link linkend="times"><citetitle>times</citetitle></link> except it returns the time since the start of this instance of the instrument.
    </para>
  </refsect1>

  <refsect1>
    <title>Examples</title>
    <para>
      Here is an example of the timeinsts opcode. It uses the files <ulink url="examples/timeinsts.orc"><citetitle>timeinsts.orc</citetitle></ulink> and <ulink url="examples/timeinsts.sco"><citetitle>timeinsts.sco</citetitle></ulink>.

      <example>
        <title>Example of the timeinsts opcode.</title>

        <programlisting>
<inlinemediaobject>
            <imageobject>
              <imagedata fileref="examples/timeinsts.orc" format="linespecific">
            </imageobject>
          </inlinemediaobject>
        </programlisting>

        <programlisting>
<inlinemediaobject>
            <imageobject>
              <imagedata fileref="examples/timeinsts.sco" format="linespecific">
            </imageobject>
          </inlinemediaobject>
        </programlisting>
      </example>

      Its output should include lines like this:
      <screen>
k1 = 0.000227 seconds
k1 = 0.500000 seconds
k1 = 1.000000 seconds
k1 = 1.500000 seconds
k1 = 2.000000 seconds
      </screen>
    </para>
  </refsect1>

  <refsect1>
    <title>See Also</title>
    <para>
      <link linkend="timeinstk"><citetitle>timeinstk</citetitle></link>, <link linkend="timek"><citetitle>timek</citetitle></link>, <link linkend="times"><citetitle>times</citetitle></link>
    </para>
  </refsect1>

  <refsect1>
    <title>Credits</title>
    <para>
      <simplelist>
        <member>Author: Robin Whittle</member>
        <member>Australia</member>
        <member>May 1997</member>
      </simplelist>
    </para>
    <para>Example written by &namekevin;.</para>
  </refsect1>
</refentry>
