Make pc86 echo console output to the serial port, so qemu can pipe it to
stdout.
This commit is contained in:
parent
ed181a8d20
commit
bfa8e501a3
|
@ -23,6 +23,9 @@ are stubs required to make the demo apps link. File descriptors 0, 1 and 2
|
||||||
represent the console. All reads block. There's enough TTY emulation to allow
|
represent the console. All reads block. There's enough TTY emulation to allow
|
||||||
\n conversion and local echo (but it can't be turned off).
|
\n conversion and local echo (but it can't be turned off).
|
||||||
|
|
||||||
|
Console output is echoed to the serial port (without any setup). This is used
|
||||||
|
by qemu for running tests.
|
||||||
|
|
||||||
|
|
||||||
Example command line
|
Example command line
|
||||||
====================
|
====================
|
||||||
|
|
|
@ -21,9 +21,18 @@ __sys_rawwrite:
|
||||||
push bp
|
push bp
|
||||||
mov bp, sp
|
mov bp, sp
|
||||||
|
|
||||||
|
! Write to the BIOS console.
|
||||||
|
|
||||||
movb al, 4(bp)
|
movb al, 4(bp)
|
||||||
movb ah, 0x0E
|
movb ah, 0x0E
|
||||||
mov bx, 0x0007
|
mov bx, 0x0007
|
||||||
int 0x10
|
int 0x10
|
||||||
|
|
||||||
|
! Also write to the serial port (used by the test suite).
|
||||||
|
|
||||||
|
movb ah, 0x01
|
||||||
|
xor dx, dx
|
||||||
|
int 0x14
|
||||||
|
|
||||||
jmp .cret
|
jmp .cret
|
||||||
|
|
Loading…
Reference in a new issue