瀏覽代碼

commit to remind me not to read own fd

Phil 5 年之前
父節點
當前提交
cd4911c5a9
共有 1 個文件被更改,包括 7 次插入2 次删除
  1. 7 2
      timer.asm

+ 7 - 2
timer.asm

@@ -18,7 +18,8 @@ section .bss
 	itimer RESQ 2
 	;timer struct init val
 	vtimer RESQ 1
-
+	;variable for timer read
+	tval RESB 8
 
 section .data
 	tick equ 2000
@@ -63,7 +64,7 @@ _start:
 	;mov edx, 1
 	;int 0x80
 
-	jmp exit
+	;jmp exit
 
 poll:
 	;get time
@@ -74,6 +75,10 @@ poll:
 	int 0x80
 	
 	mov eax, SYS_READ
+	mov ebx, 0x0
+	mov ecx, tval
+	mov edx, 0x20
+	int 0x80
 
 	;mov bx, [ot+13]
 	;sub bx, [lt]