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

  <refnamediv>
    <refname>rtclock</refname>
    <refpurpose>
      Read the real time clock from the operating system.
      <indexterm id="IndexRtclock"><primary>rtclock</primary></indexterm>
    </refpurpose>
  </refnamediv>
  
  <refsect1>
    <title>Description</title>
    <para>
      Read the real-time clock from the operating system.
    </para>
  </refsect1>

  <refsect1>
    <title>Syntax</title>
    <synopsis>ir <command>rtclock</command></synopsis>

    <synopsis>kr <command>rtclock</command></synopsis>
  </refsect1>

  <refsect1>
    <title>Performance</title>
    <para>
      Read the real-time clock from operating system. Under Windows, this changes only once per second. Under GNU/Linux, it ticks every microsecond. Performance under other systems varies.
    </para>
  </refsect1>

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

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

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

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

      Its output should include lines like this:
      <screen>
 i   1 time     0.00002: 1018236096.00000
 i   1 time     1.00002: 1018236224.00000
      </screen>
    </para>
  </refsect1>

  <refsect1>
    <title>Credits</title>
    <para>Author: &namejohn;</para>
    <para>Example written by &namekevin;.</para>
    <para>New in version 4.10</para>
  </refsect1>
</refentry>
