Hi, I've got this hard-coded for the uart at 3f8h... Change the value in the START routine to try a different uart. This leaves the UART in a weird state, so you must reinitialize it after you use this. IT doesn't chek the BIOS addresses for valid uarts, you give it a base address you think is a UART and it tries it out. David .model small .stack .data irq db ? pic0 db ? pic1 db ? goodmsg db "IRQ detected - #",'$' badmsg db "IRQ not detected",'$' align port dw ? .code irqentry macro label,num label: push ds push ax push dx mov ax,dgroup mov ds,ax mov al,num mov ds:[irq],al mov dx,[port] in al,dx jmp $+2 jmp $+2 mov al,20h out 20h,al jmp $+2 jmp $+2 out 0a0h,al pop dx pop ax pop ds iret endm dset macro port,pos,lab .data lab dd ? .code mov bx,port mov si,offset lab mov ax,offset pos call loadint endm unset macro port,lab mov si,offset lab mov bx,port call unloadint endm irqentry irq3,03h irqentry irq4,04h irqentry irq7,07h irqentry irq10,10 irqentry irq11,11 irqentry irq12,12 irqentry irq15,15 ; ; Routine to unload ints ; unloadint proc shl bx,2 ; Get int address push 0 ; pop es ; ES = 0 mov ax,ds:[si] ; Move lo word mov es:[bx],ax ; mov ax,ds:[si+2] ; mov es:[bx+2],ax ; ret unloadint endp ; ; Routine to load an interrupt ; loadint proc shl bx,2 ; Get int address push 0 ; ES = 0 pop es mov di,es:[bx] ; Get old int mov ds:[si],di mov di,es:[bx+2] mov ds:[si+2],di cli mov es:[bx],ax ; Save new int mov es:[bx+2],cs ; sti ret loadint endp setirqs proc dset 0bh,irq3,irqs3 dset 0ch,irq4,irqs4 dset 0fh,irq7,irqs7 dset 72h,irq10,irqs10 dset 73h,irq11,irqs11 dset 74h,irq12,irqs12 dset 77h,irq15,irqs15 in al,21h jmp $+2 jmp $+2 mov [pic0],al and al,NOT 98h out 21h,al jmp $+2 jmp $+2 in al,0a1h jmp $+2 jmp $+2 mov [pic1],al and al,NOT 9ch out 0a1h,al jmp $+2 jmp $+2 ret setirqs endp unsetirqs proc unset 0bh,irqs3 unset 0ch,irqs4 unset 0fh,irqs7 unset 72h,irqs10 unset 73h,irqs11 unset 74h,irqs12 unset 77h,irqs15 mov al,[pic0] out 21h,al jmp $+2 jmp $+2 mov al,[pic1] out 0a1h,al jmp $+2 jmp $+2 ret unsetirqs endp triggerirq proc call dlab1 mov al,1 out dx,al jmp $+2 jmp $+2 inc dx dec al out dx,al jmp $+2 jmp $+2 dec dx call dlab0 inc dx mov al,2 out dx,al jmp $+2 jmp $+2 dec dx add dx,4 mov al,08h out dx,al jmp $+2 jmp $+2 sub dx,4 out dx,al jmp $+2 jmp $+2 mov cx,0 lp: jmp $+2 jmp $+2 loop lp ret triggerirq endp dlab1 proc push dx add dx,3 in al,dx jmp $+2 jmp $+2 or al,80h out dx,al pop dx ret dlab1 endp dlab0 proc push dx add dx,3 in al,dx jmp $+2 jmp $+2 and al,7fh out dx,al pop dx ret dlab0 endp IOTEST proc mov al,ah out dx,al jmp $+2 jmp $+2 in al,dx jmp $+2 jmp $+2 cmp al,ah ret IOTEST endp test1 proc cli mov [port],dx mov [irq],-1 call dlab1 mov ah,5ah call IOtest jnz bad mov ah,0a5h call IOtest jnz bad sti call setirqs call triggerIRQ call unsetirqs bad: sti mov al,[irq] ret test1 endp start proc mov ax,dgroup mov ds,ax mov dx,UARTBASE call test1 cmp al,0ffh jz bad2 push ax mov dx,offset goodmsg mov ah,9 int 21h pop ax add al,'0' cmp al,'9' jle ok sub al,10 push ax mov dl,'1' mov ah,2 int 21h pop ax ok: mov dl,al mov ah,2 int 21h jmp exit bad2: mov dx,offset badmsg mov ah,9 int 21h exit: mov ah,4ch int 21h start endp end start begin 777 isuart.exe M35H&`0,`"``@`$,`__\S```$``"6`@``/@````$`^V%J<@`````````````` M```````````````````````$````*````$P```!P````E````+@```#<```` MEP(````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````````````````````````````````````````` M```````````````````````>4%*X+@".V+`#H@``BQ8F`.SK`.L`L"#F(.L` MZP#FH%I8'\\>4%*X+@".V+`$H@``BQ8F`.SK`.L`L"#F(.L`ZP#FH%I8'\\> M4%*X+@".V+`'H@``BQ8F`.SK`.L`L"#F(.L`ZP#FH%I8'\\>4%*X+@".V+`* MH@``BQ8F`.SK`.L`L"#F(.L`ZP#FH%I8'\\>4%*X+@".V+`+H@``BQ8F`.SK M`.L`L"#F(.L`ZP#FH%I8'\\>4%*X+@".V+`,H@``BQ8F`.SK`.L`L"#F(.L` MZP#FH%I8'\\>4%*X+@".V+`/H@``BQ8F`.SK`.L`L"#F(.L`ZP#FH%I8'\_1 MX]'C4%6+[,=&`@``70>+!":)!XM$`B:)1P+#T>/1XU!5B^S'1@(``%T')HL_ MB3PFBW\"B7P"^B:)!R:,3P+[P[L+`+XH`+@``.C/_[L,`+XL`+@D`.C#_[L/ M`+XP`+A(`.BW_[MR`+XT`+AL`.BK_[MS`+XX`+B0`.B?_[MT`+X\`+BT`.B3 M_[MW`+Y``+C8`.B'_^0AZP#K`*(!`"1GYB'K`.L`Y*'K`.L`H@(`)&/FH>L` MZP##OB@`NPL`Z#__OBP`NPP`Z#;_OC``NP\`Z"W_OC0`NW(`Z"3_OC@`NW,` MZ!O_OCP`NW0`Z!+_OD``NW<`Z`G_H`$`YB'K`.L`H`(`YJ'K`.L`P^@X`+`! M[NL`ZP!"_LCNZP#K`$KH,P!"L`+NZP#K`$J#P@2P".[K`.L`@^H$[NL`ZP"Y M``#K`.L`XOK#4H/"`^SK`.L`#(#N6L-2@\(#[.L`ZP`D?^Y:PXK$[NL`ZP#L MZP#K`#K$P_J)%B8`Q@8``/_HR/^T6NC?_W41M*7HV/]U"OOHLO[H>/_H(__[ MH```P[@N`([8NO@#Z,O_//]T(E"Z`P"T"