Class Kernel
Provides a base kernel class for a Cosmos-based system
Inheritance
Inherited Members
Namespace: Cosmos.System
Assembly: Cosmos.System2.dll
Syntax
public abstract class Kernel
Constructors
| Improve this Doc View SourceKernel()
The kernel object construtor. Overriding this constructor is not recommended and may result in undesirable behavior.
Declaration
public Kernel()
Fields
| Improve this Doc View SourcemDebugger
User ring debugger instance, with the tag "Kernel".
Declaration
public readonly Debugger mDebugger
Field Value
Type | Description |
---|---|
Debugger |
mStarted
Declaration
protected bool mStarted
Field Value
Type | Description |
---|---|
System.Boolean |
mStopped
Declaration
protected bool mStopped
Field Value
Type | Description |
---|---|
System.Boolean |
Properties
| Improve this Doc View SourceInterruptsEnabled
Whether system interrupts are currently enabled.
Declaration
public static bool InterruptsEnabled { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceAfterRun()
Called after the main kernel loop method finishes. The main kernel loop can stop after e.g. a call to the Stop() method.
Declaration
protected virtual void AfterRun()
BeforeRun()
Called before the main kernel loop begins.
Declaration
protected virtual void BeforeRun()
GetTextScreen()
Gets the text screen device to initialize the system with. If not overriden, the default text screen device will be used.
Declaration
protected virtual TextScreenBase GetTextScreen()
Returns
Type | Description |
---|---|
TextScreenBase |
OnBoot()
This method controls the driver initialisation process.
Declaration
protected virtual void OnBoot()
PrintDebug(String)
Prints a message to the debugger with the "Global" tag.
Declaration
public static void PrintDebug(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | The message to print. |
Run()
The main kernel loop method; this method is called on a infinite loop, until Stop() is called.
Declaration
protected abstract void Run()
Start()
Start the system up using the properties for configuration.
Declaration
public virtual void Start()
Stop()
Stops the main kernel loop.
Declaration
public void Stop()