> dseg segment .data
segment .data
> Letter DB 'H'
>
> cseg segment .text
segment .text
> MOV AX, dseg
> MOV DS, AX
These two lines are needed for an .exe file, but you don't want 'em for a .com file. Dos loads a .com file with segment registers pointed to your one-and-only segment. But your .com file is loaded into memory at offset 100h into that segment, so you *do* need:
org 100h
> MOV AH, 02H
> MOV DL, [Letter]
> INT 21H
>
> MOV AH, 4CH
> INT 21H
>
> Why won't this print out the letter 'H'? It's instead printing out some strange
> symbol ?.
A case of Nasm not calculating a value for "Letter" such that ds:Letter actually points to your letter.
> I'm using the 16-bit version of NASM, by the way.
Why? Unless you're running on a 286, that isn't the build you want!
> Compiling
> it with:
> nasm -o test.com -f bin test.asm
That should be right.
Best,
Frank