12 lines
349 B
ArmAsm
12 lines
349 B
ArmAsm
global outb
|
|
|
|
; outb - Send a byte to an I/O port.
|
|
; stack: [esp + 8] The data byte
|
|
; [esp + 4] The I/O port
|
|
; [esp ] Return address
|
|
outb:
|
|
mov al, [esp + 8] ; Move the data to send into the AL register
|
|
mov dx, [esp + 4] ; Move the address of the I/O port into the DX register
|
|
out dx, al ; Send the data to the I/O port
|
|
ret ; Return
|