Time Services


 
Contents: 0x10    Get current time of day

This gets the time from the CMOS.

Input
  none

Output
  BL    Second (BCD)
  BH    Minute (BCD)
  CL    Hour (BCD)
  AL    Status

 
0x11    Get current date


This gets the date from the CMOS.

Input
  none

Output
  BX    Year (BCD)
  BH    Month (BCD)
  CL    Day (BCD)
  AL    Status
 

0x40    End tasks time slice


This ends a tasks time slice. Use it when your code has to wait for anything.

Input
  none

Output
  AL    Status
 

0x41    Pause task


This suspends a task for at least the amount of time specified. Be carefull asking for large amounts of time asleep if the task has a message queue.

Input
  EBX    Minimum milli-seconds to sleep for

Output
  AL    Status
 

0x60    Get task priority


Each task has 2 priority values, one set by the user and one set by the task.

Input
  BX    Code ID

Output
  BL    Priority
  AL    Status
 

0x61    Set current tasks priority


Each task has 2 priority values, one set by the user and one set by the task.

Input
  BL    Priority

Output
  AL    Status
 

0x98    Suspend Task


This sets a flag that prevents a task from getting any CPU time. If the current task is suspended this service won't return until this flag has been cleared (using service 0x9C).

Input
  BX    Task ID

Output
  AL    Status

0x99    Stop task until message received


This sets a flag that prevents a task from getting any CPU time. If the current task is suspended this service won't return until this flag has been cleared (using service 0x9D). It should only ever be used by Messaging Services.

Input
  BX    Task ID

Output
  AL    Status
 

0x9C    Un-suspend Task


This clears a flag that prevents a task from getting any CPU time.

Input
  BX    Task ID

Output
  AL    Status
 

0x9D    Start task (message received)


This clears a flag that prevents a task from getting any CPU time. It should only ever be used by Messaging Services.

Input
  BX    Task ID

Output
  AL    Status
 

0xC0    Install Code


This installs and starts any native code.

Input
  EBX    Physical address of code

Output
  BX    Code ID for module
  AL    Status
 

0xD0    Create system task


This creates a task for systems code and drivers. The task created is treated by the scheduler the same as a normal application.

Input
  EBX    Maximum stack size in pages
  CX     Code ID for module
  EDX    New tasks EIP

Output
  EBX    Address of pages allocated for stack
  AL     Status
 

0xD1    Create system idle task


This creates a task for systems code and drivers than only ever runs when there's nothing else to do.

Input
  EBX    Maximum stack size in pages
  CX     Code ID for module
  EDX    New tasks EIP

Output
  EBX    Address of pages allocated for stack
  AL     Status
 

0xD8    Kill task


This removes a tasks TSS and scheduling info (eventually). It doesn't de-allocate any other resources used.

Input
  BX    Task ID

Output
  AL     Status
 

0xDF    Jump to task


Switches from the current task to a new one.

Input
  BX    Task ID

Output
  AL     Status
 

0xF0    Self Test


This service tests the time services data structures.

Input
  none

Output
  EBX    address of error string (unless no error)
  AL     status (0 means ok, no error string)
  


Home  Index
Copyright 1998, Brendan Trotter