S Y M B O S   D E V E L O P E R   D O C U M E N T A T I O N
Author: Prodatron / Symbiosis
Date:   28.10.2005
===============================================================================

O V E R V I E W

1.) APPLICATIONS
2.) KERNEL
3.) DESKTOP MANAGER
4.) SYSTEM MANAGER
5.) FILE MANAGER
6.) DEVICE MANAGER
7.) DESKTOP MANAGER DATA RECORDS
8.) MEMORY MAP


===============================================================================
1.) APPLICATIONS
see: SymbOS-Applications.txt

This chapter describes, how to write applications for SymbOS.
-------------------------------------------------------------------------------
General
Memory area types
Application structure
Application header
Path and appended parameters
CPU register usage
Application templates
SymStudio system library
-------------------------------------------------------------------------------


===============================================================================
2.) KERNEL
see: SymbOS-Kernel.txt

The kernel contains the functions for sending and receiving messages to and
from other processes, the process handling functions (multitasking) and the
memory and banking functions.
-------------------------------------------------------------------------------
KERNEL RESTARTS
Message_Sleep_And_Receive                       RST #08 (MSGSLP)
Message_Send                                    RST #10 (MSGSND)
Message_Receive                                 RST #18 (MSGGET)
Banking_SlowCall                                RST #20 (BNKSCL)
Banking_FastCall                                RST #28 (BNKFCL)
Multitasking_SoftInterrupt                      RST #30 (MTSOFT)
Multitasking_HardInterrupt                      RST #30 (MTHARD)

KERNEL COMMANDS (MULTITASKING MANAGEMENT)
Multitasking_Add_Process_Command                001 (MSC_KRL_MTADDP)
Multitasking_Delete_Process_Command             002 (MSC_KRL_MTDELP)
Multitasking_Add_Timer_Command                  003 (MSC_KRL_MTADDT)
Multitasking_Delete_Timer_Command               004 (MSC_KRL_MTDELT)
Multitasking_Sleep_Process_Command              005 (MSC_KRL_MTSLPP)
Multitasking_WakeUp_Process_Command             006 (MSC_KRL_MTWAKP)

KERNEL RESPONSES (MULTITASKING MANAGEMENT)
Multitasking_Add_Process_Response               129 (MSR_KRL_MTADDP)
Multitasking_Delete_Process_Response            130 (MSR_KRL_MTDELP)
Multitasking_Add_Timer_Response                 131 (MSR_KRL_MTADDT)
Multitasking_Delete_Timer_Response              132 (MSR_KRL_MTDELT)
Multitasking_Sleep_Process_Response             133 (MSR_KRL_MTSLPP)
Multitasking_WakeUp_Process_Response            134 (MSR_KRL_MTWAKP)

KERNEL FUNCTIONS (MEMORY MANAGEMENT)
Memory_Summary                                  #8100 (MEMSUM)
Memory_Information                              #8121 (MEMINF)
Memory_Get                                      #8118 (MEMGET)
Memory_Free                                     #811B (MEMFRE)
Memory_Resize                                   #811E (MEMSIZ)

KERNEL FUNCTIONS (BANKING MANAGEMENT)
Banking_ReadWord                                #8124 (BNKRWD)
Banking_WriteWord                               #8127 (BNKWWD)
Banking_ReadByte                                #812A (BNKRBT)
Banking_WriteByte                               #812D (BNKWBT)
Banking_Copy                                    #8130 (BNKCOP)
Banking_GetBank                                 #8133 (BNKGET)
Banking_Call_Application16KRoutine              #8142 (BNK16C)

KERNEL FUNCTIONS (MISCELLANEOUS)
Multitasking_GetCounter                         #8109 (MTGCNT)
-------------------------------------------------------------------------------


===============================================================================
3.) DESKTOP MANAGER
see: SymbOS-Desktop.txt

The desktop manager contains all functions to open and manage windows, to
manage the controls inside a window and to interact with the user.
-------------------------------------------------------------------------------
DESKTOP MANAGER COMMANDS
Window_Open_Command                             032 (MSC_DSK_WINOPN)
Window_Redraw_Menu_Command                      033 (MSC_DSK_WINMEN)
Window_Redraw_Content_Command                   034 (MSC_DSK_WININH)
Window_Redraw_Toolbar_Command                   035 (MSC_DSK_WINTOL)
Window_Redraw_Title_Command                     036 (MSC_DSK_WINTIT)
Window_Redraw_Statusbar_Command                 037 (MSC_DSK_WINSTA)
Window_Set_ContentX_Command                     038 (MSC_DSK_WINMVX)
Window_Set_ContentY_Command                     039 (MSC_DSK_WINMVY)
Window_Focus_Command                            040 (MSC_DSK_WINTOP)
Window_Size_Maximize_Command                    041 (MSC_DSK_WINMAX)
Window_Size_Minimize_Command                    042 (MSC_DSK_WINMIN)
Window_Size_Restore_Command                     043 (MSC_DSK_WINMID)
Window_Set_Position_Command                     044 (MSC_DSK_WINMOV)
Window_Set_Size_Command                         045 (MSC_DSK_WINSIZ)
Window_Close_Command                            046 (MSC_DSK_WINCLS)
Window_Redraw_ContentExtended_Command           047 (MSC_DSK_WINDIN)
Desktop_Service_Command                         048 (MSC_DSK_DSKSRV)
Window_Redraw_Slider_Command                    049 (MSC_DSK_WINSLD)

DESKTOP MANAGER RESPONSES
Window_OpenError_Response                       160 (MSR_DSK_WOPNER)
Window_OpenOK_Response                          161 (MSR_DSK_WOPNOK)
Window_UserAction_Response                      162 (MSR_DSK_WCLICK)
Desktop_Service_Response                        163 (MSR_DSK_DSKSRV)

DESKTOP MANAGER SERVICES
DesktopService_ScreenModeGet                    001 (DSK_SRV_MODGET)
DesktopService_ScreenModeSet                    002 (DSK_SRV_MODSET)
DesktopService_ColourGet                        003 (DSK_SRV_COLGET)
DesktopService_ColourSet                        004 (DSK_SRV_COLSET)
DesktopService_RedrawBackground                 005 (DSK_SRV_DSKBGR)
DesktopService_RedrawComplete                   006 (DSK_SRV_DSKPLT)
-------------------------------------------------------------------------------


===============================================================================
4.) SYSTEM MANAGER
see: SymbOS-System.txt

The system manager contains the functions to start and end applications, to
open special dialogues and some more services.
-------------------------------------------------------------------------------
SYSTEM MANAGER COMMANDS AND RESPONSES (APPLICATION MANAGEMENT)
Program_Run_Command                             016 (MSC_SYS_PRGRUN)
Program_Run_Response                            144 (MSR_SYS_PRGRUN)
Program_End_Command                             017 (MSC_SYS_PRGEND)
Program_Run_Dialogue_Command                    020 (MSC_SYS_PRGSTA)
Program_Run_ControlPanel_Command                024 (MSC_SYS_PRGSET)
Program_Run_TaskManager_Command                 025 (MSC_SYS_PRGTSK)

SYSTEM MANAGER COMMANDS (SYSTEM MANAGEMENT)
System_Dialogue_NextWindow_Command              018 (MSC_SYS_SYSNXT)
System_Dialogue_PreviousWindow_Command          019 (MSC_SYS_SYSPRV)
System_Dialogue_SystemSecurity_Command          021 (MSC_SYS_SYSSEC)
System_Dialogue_ShutDown_Command                022 (MSC_SYS_SYSQIT)
System_ShutDown_Command                         023 (MSC_SYS_SYSOFF)
System_Configuration_Command                    028 (MSC_SYS_SYSCFG)

SYSTEM MANAGER COMMANDS AND RESPONSES (FILE MANAGEMENT)
System_Filemanager_Command                      026 (MSC_SYS_SYSFIL)
System_Filemanager_Response                     154 (MSR_SYS_SYSFIL)

SYSTEM MANAGER COMMANDS AND RESPONSES (DIALOGUE SERVICES)
Dialogue_Infobox_Command                        029 (MSC_SYS_SYSWRN)
Dialogue_FileSelector_Command                   031 (MSC_SYS_SELOPN)
Dialogue_FileSelector_Response                  159 (MSR_SYS_SELOPN)

SYSTEM MANAGER FUNCTIONS
System_Information                              #8103 (SYSINF)
-------------------------------------------------------------------------------


===============================================================================
5.) FILE MANAGER
see: SymbOS-File.txt

The file manager contains all functions for reading from files and writing to
files and to manage the content of directories.
-------------------------------------------------------------------------------
MASS STORAGE DEVICE FUNCTIONS
Storage_Init                                    000 (STOINI)
Storage_New                                     001 (STONEW)
Storage_Reload                                  002 (STORLD)
Storage_Delete                                  003 (STODEL)
Storage_ReadSector                              004 (STOINP)
Storage_WriteSector                             005 (STOOUT)
Storage_Activate                                006 (STOACT)
Storage_Information                             007 (STOINF)

FILE MANAGEMENT FUNCTIONS
File_Init                                       016 (FILINI)
File_New                                        017 (FILNEW)
File_Open                                       018 (FILOPN)
File_Close                                      019 (FILCLO)
File_Input                                      020 (FILINP)
File_Output                                     021 (FILOUT)
File_Pointer                                    022 (FILPOI)
File_Decode_Timestamp                           023 (FILF2T)
File_Encode_Timestamp                           024 (FILT2F)
File_LineInput                                  025 (FILLIN)

DIRECTORY MANAGEMENT FUNCTIONS
Directory_Device                                032 (DIRDEV)
Directory_Path                                  033 (DIRPTH)
Directory_Property_Set                          034 (DIRPRS)
Directory_Property_Get                          035 (DIRPRR)
Directory_Rename                                036 (DIRREN)
Directory_New                                   037 (DIRNEW)
Directory_Input                                 038 (DIRINP)
Directory_DeleteFile                            039 (DIRDEL)
Directory_Input_Extended                        013 (DEVDIR)
-------------------------------------------------------------------------------


===============================================================================
6.) DEVICE MANAGER
see: SymbOS-Device.txt

The device manager controls all parts of the computer hardware. As in generel
the desktop manage and the file manager is between the application and the
device manager, only a few functions of the device manager are available for
the application directly.
-------------------------------------------------------------------------------
DEVICE MANAGER FUNCTIONS
Device_TimeGet                                  #810C (TIMGET)
Device_TimeSet                                  #810F (TIMSET)
Device_MousePosition                            #813C (MOSGET)
Device_MouseKeyStatus                           #813F (MOSKEY)
-------------------------------------------------------------------------------


===============================================================================
7.) DESKTOP MANAGER DATA RECORDS
see: SymbOS-DesktopDataRecords.txt

This chapter describes the data structure of all records which are used in the
desktop manager.
-------------------------------------------------------------------------------
Window Data Record
Control Group Data Record
Control Data Record
Calculation Rule Data Record
Control Types
Pulldown Menus
Graphics

CONTROL TYPES
paint_area                                      00 (PLF)
paint_text                                      01 (PLT)
paint_frame                                     02 (PLR)
paint_frame_with_title                          03 (PLX)
paint_progress                                  04 (PLP)
graphic_simple                                  08 (ICN)
graphic_with_text                               09 (ICT)
button_simple                                   16 (BTN)
button_check                                    17 (BTC)
button_radio                                    18 (BTR)
button_hidden                                   19 (BTP)
button_tabs                                     20 (BTT)
slider_simple                                   24 (SLD)
textinput_line                                  32 (TXL)
textinput_box                                   33 (TXB)
list_title                                      40 (LST)
list_content                                    41 (LSI)
list_dropdown                                   42 (LSP)
list_complete                                   43 (LSC)
-------------------------------------------------------------------------------


===============================================================================
8.) MEMORY MAP
see: SymbOS-MemoryMap.txt

Here you have an overview of the memory usage in SymbOS.
-------------------------------------------------------------------------------
General Memory Usage
Application Memory Usage
Memory Configurations
-------------------------------------------------------------------------------
