|
|
发表于 2008-7-21 13:02:13
|
显示全部楼层
你确认访问的位置是Bus0:Device2:Function0的Reg48h吗?
& N: ^) X0 f1 k) e" y% S请用下面这段代码来试试
% D8 e" H$ X) ~0 N. R% d+ w$ I reg:BYTE4 c( P1 |, e2 w7 M0 y
mov ax,0b108h
# ]. ^7 r9 m- }8 F2 t mov bx,10h+ i% ^- D0 A/ c; [5 U; Q
mov di,48h9 w, l. C5 l! n( f% d+ }* V
int 1ah
9 M: g$ d6 r. w1 d# s* ]; k mov reg,cl ;get RTC Control Register3 O! `, T6 F! t7 `0 ^; ^: G
2 e/ v5 i3 X5 h6 ~ y mov cl,reg: Y$ _/ D" Q9 b A$ {
and cl,3fh
/ d4 G0 j3 F# z or cl,40h ;set APCREG_EN
2 t4 a2 \0 N u$ \* C) B( L mov ax,0b10bh
6 ~2 p/ o5 b, K3 \- ~0 d mov bx,10h
- Y- }- f% K/ x' s6 P7 N mov di,48h% q% o* v. C. V% h
int 1ah2 P, c1 ]4 M% |
//now can access the APC register . }! \, P5 Z0 s+ }
; c u% U- u" X+ r; k. J5 ~; R mov cl,reg$ z. T' t" ^' N$ f9 `2 m
mov ax,0b10bh I$ { h9 W" A; a0 u! t5 j& z
mov bx,10h
* z0 ^2 L: W& }. E W mov di,48h* v2 e+ q. ]* s% S4 D$ }
int 1ah ;Restore |
|