-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Penambahan source code milestone 3
- Loading branch information
Showing
36 changed files
with
4,405 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
global _interrupt | ||
|
||
;int interrupt (int number, int AX, int BX, int CX, int DX) | ||
_interrupt: | ||
push bp | ||
mov bp,sp | ||
mov ax,[bp+4] ;get the interrupt number in AL | ||
push ds ;use self-modifying code to call the right interrupt | ||
mov bx,cs | ||
mov ds,bx | ||
mov si,intr | ||
mov [si+1],al ;change the 00 below to the contents of AL | ||
pop ds | ||
mov ax,[bp+6] ;get the other parameters AX, BX, CX, and DX | ||
mov bx,[bp+8] | ||
mov cx,[bp+10] | ||
mov dx,[bp+12] | ||
|
||
intr: int 0x00 ;call the interrupt (00 will be changed above) | ||
|
||
mov ah,0 ;we only want AL returned | ||
pop bp | ||
ret |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
// 13519214 - Basic operation | ||
|
||
int div(int a, int b); | ||
|
||
int mod(int a, int n); |
Oops, something went wrong.