Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Borland C++ 2.x ( with Turbo C ) - <b>biostime() return the time of day</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 biostime()              Return the Time of Day

 #include   <bios.h>

 long       biostime(cmd,newtime);
 int        cmd;                         Operation to perform
 long       newtime;                     Time

    Using BIOS interrupt 0x1A, biostime() gets or sets the time kept by
    the BIOS timer, which counts ticks at the rate of approximately 18.2
    per second, beginning at midnight.  If 'cmd' = 0, biostime() returns
    the current value of the timer.  If 'cmd' = 1, biostime() sets the
    timer to the long value in 'newtime'.

       Returns:     The timer's current value if 'cmd' = 0

   Portability:     IBM PC and compatibles only.

   -------------------------------- Example ---------------------------------
    The following statements display the current value of the BIOS timer.

           #include <stdio.h>              /* for printf */
           #include <bios.h>           /* for biostime */

           main()
           {
               printf("BIOS timer = %ld\n",biostime(0,0L));
           }




Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson