PutCharEx function
The PutCharEx function outputs a character to the screen. The character is passed through the stack. The function automatically aligns the stack to 2 bytes.
Parameters (stack): 1. Character to output.
Return value: The function does not return a value.
Flag state: The function does not modify the flags.
Program source code
Intel 8086 assembly program example demonstrating the use of the PutCharEx function to output a character passed through the stack.
title .286C .model small .stack 100h code segment public assume cs:code include Handyfar.inc ; Include the file with functions main proc call SetDataSegment ; Call the SetDataSegment procedure push 'A' ; Push character 'A' onto the stack call PutCharEx ; Call procedure PutCharEx('A') push 0 ; Push the byte return code onto the top of the stack call ExitProcessEx ; Call the ExitProcessEx(0) procedure main endp code ends end main
A
Example taken from the textbook "HANDYFAR - MASM (Evgeny Sergeevich Dovgopolov)".