Selaa lähdekoodia

New placement of the system in mm

go32
Rhodez-x 5 vuotta sitten
vanhempi
commit
2b3978e4a0
2 muutettua tiedostoa jossa 7 lisäystä ja 4 poistoa
  1. +3
    -3
      bootloader.nasm
  2. +4
    -1
      kernel.nasm

+ 3
- 3
bootloader.nasm Näytä tiedosto

@ -50,7 +50,7 @@ start:
mov cl, 0x11 ;First sector to read (bits 0-5), upper bits of cylinder (bits 6-7)
mov dh, 0x0 ;Head number
mov dl, [disk_identifier] ;0x0 ;Drive number
mov bx, 0x7e00 ;Offset into section
mov bx, 0x500 ;Offset into section
int 0x13 ;Low level disk services
;mov [0x7000], es ; saving retult of read
;
@ -75,9 +75,9 @@ start:
; call dumpax
mov dl, [disk_identifier]
mov ax, 0x7e0
mov ax, 0x50
mov ds, ax
jmp 0x7e0:0x00
jmp 0x50:0x00 ; 0x500
endcarrycheck:
cli ; Clear the Interrupt Flag (disable external interrupts)

+ 4
- 1
kernel.nasm Näytä tiedosto

@ -6,7 +6,6 @@ start_sing:
; VSFS is loaded:
mov [global_disk_identifier], dl ; saving disk_identifier, this is the number the disk that we are booting from.
; This number is set by the bios
jmp sing_ready
%include "mem_lib/mem_lib.nasm"
%include "lib/os_lib.nasm"
@ -18,6 +17,10 @@ jmp sing_ready
%include "CLI/CLI.nasm"
sing_ready: ; SingOS is ready for the user:
mov ax, 0x8fc0
mov ss, ax ; Set 'ss' to this location (the beginning of our stack region)
mov sp, 0xffff ; Set 'ss:sp' to the top of our 8K stack
mov bp, sp
call os_clear_screen

Ladataan…
Peruuta
Tallenna