Merge pull request #48 from SamTebbs33/feature/runtime-testing
Add runtime testing harness
This commit is contained in:
commit
811ee30f17
9 changed files with 103 additions and 13 deletions
|
|
@ -305,4 +305,5 @@ pub fn init() void {
|
|||
|
||||
// Load the TSS
|
||||
arch.ltr();
|
||||
log.logInfo("Done\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -122,4 +122,5 @@ pub fn closeInterruptGate(index: u8) void {
|
|||
pub fn init() void {
|
||||
log.logInfo("Init idt\n");
|
||||
arch.lidt(&idt_ptr);
|
||||
log.logInfo("Done\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -273,6 +273,7 @@ pub fn getFrequency() u32 {
|
|||
/// Initialise the PIT with a handler to IRQ 0.
|
||||
///
|
||||
pub fn init() void {
|
||||
log.logInfo("Init pit\n");
|
||||
// Set up counter 0 at 1000hz in a square wave mode counting in binary
|
||||
const f: u32 = 10000;
|
||||
setupCounter(OCW_SELECT_COUNTER_0, f, OCW_MODE_SQUARE_WAVE_GENERATOR | OCW_BINARY_COUNT_BINARY);
|
||||
|
|
@ -281,4 +282,5 @@ pub fn init() void {
|
|||
|
||||
// Installs 'pitHandler' to IRQ0 (pic.IRQ_PIT)
|
||||
irq.registerIrq(pic.IRQ_PIT, pitHandler);
|
||||
log.logInfo("Done\n");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue