|
发表于 2008-7-21 13:02:13
|
显示全部楼层
你确认访问的位置是Bus0:Device2:Function0的Reg48h吗?' h- v% h. k+ \; |
请用下面这段代码来试试
5 W/ E1 x9 s* i" |: V* f" H reg:BYTE# h Z% w. \! V" v( _) R4 g6 r, [
mov ax,0b108h
" Q6 v- |0 M' H& @9 H$ X& o9 M) b mov bx,10h
/ R$ @# }; _1 R mov di,48h
" v1 ?$ P& ^% y int 1ah
" ]7 f* p' ?: r% o W" c j4 k mov reg,cl ;get RTC Control Register! U. d; f) j$ f/ W a o6 g' F
( a) }) d, o( E/ [# S9 k( j2 K
mov cl,reg/ V6 W0 O! G/ A. E3 A8 _: j+ Z' `5 b9 c
and cl,3fh, y: `5 ]' G8 w" b. T; ]; p1 Y
or cl,40h ;set APCREG_EN
8 j0 J- k" ~4 d" A, `6 u9 q, q' ^ mov ax,0b10bh9 o$ \, `1 k% J8 c3 U8 Y
mov bx,10h# V1 @; T5 v% q9 D
mov di,48h
2 }2 W3 I3 |7 |5 v! Q# Y3 ^ int 1ah
8 R. e; S$ G9 g6 ^! { //now can access the APC register 5 @& E! J; S6 x J- ]; S
& j( ]; U5 }6 M+ J! r" Y- u5 G mov cl,reg
- _8 _0 w! g0 Y& W6 ]+ H( [: ~ mov ax,0b10bh
/ s! b3 s. q7 ] mov bx,10h
5 N7 j- E& w/ h; R2 E! D mov di,48h0 G8 G: r+ b# } d! M% V& e
int 1ah ;Restore |
|