DMP Electronics eBOX-3350MX-AP Manual de usuario Pagina 108

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 112
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 107
Jan Yin Chan Electronics Co.,LTD. 386SX Single Chip PC
M6117D : System on a chip
DM&P
Jan Yin Chan Electronics Co,. LTD. M6117D 386SX Single Chip PC Page 107
8F-1,No.22,Wuchyuan 2RD.,Hsin Chuang city Taipei Hsien, Taiwan, R.O.C. Tel: 886-(02) 2298-0770 Fax: (02) 2299-1883
Example C: Set GPCS1 decoder to I/O address 168h to16Bh 8bit data bus read/write.
; Please use TASM to compiler the following program.
; Execute under DOS environment.
;
.286
.model small
.code
Start proc c
mov ax,0c513h ; Unlock configuration register
call writechip
mov ax,0c45h ; Enable IO address A[15-1], 8bit data bus read/write.
call writechip
mov ax,0149h ; Set the GPCS0 A[15-8] is 01h. A15 A14 A13 A12 A11 A10 A9 A8 A7 A6 A5 A4 A3 A2 A1 A0
call writechip ; 0 0 0 0 0 0 0 1 0 1 1 0 1 0 X X = 168h -
16Bh
mov ax,6848h ; Set the GPCS0 A[7-1] is 68h.
call writechip
mov ax,004bh ; Set the GPCS0 mask A[15-8] is 00h, address A[15-8] full compare(set to" 0" is compare, set to "1" is don't care).
call writechip
mov ax,004ah ; Set the GPCS0 mask A[7-1] is 000000XXb, address A[7-2] full compare, A[1-0] is don't care.
call readchip :
and al,00000001b
or al,00000010b ;
xchg ah,al ;
call writechip ;
mov ax,0048h ;
call readchip
or al,00000001b
xchg ah,al
call writechip ; Active GPCS1 decoder single.
mov ax,0013h ; Lock configuration register
call writechip
mov ax,4c00h
int 21h
endp
readchip proc c
out 22h,al
nop
nop
in al,23h
nop
nop
ret
endp
writechip proc c
out 22h,al
nop
nop
xchg ah,al
out 23h,al
nop
nop
xchg ah,al
ret
endp
end
Vista de pagina 107
1 2 ... 103 104 105 106 107 108 109 110 111 112

Comentarios a estos manuales

Sin comentarios