title: Printing out a 8 bit register as two hex characters with NASM
body: <p>I am attempting to print out the hex value of an 8 bit register in assembly for a bootloader. I have written code to print out values, but only as ASCII characters. For example:</p>
  
  <pre><code>BITS 16
  
  start:
      mov ax, 07C0h
      add ax, 288
      mov ss, ax
      mov sp, 4096
  
      mov ax, 02h
      int 10h
      mov ax, 07C0h
      mov ds, ax
  
      mov al, 19h
      mov ah, 0Eh
      int 10h
  
      jmp $
  
      ret
      times 510-($-$$) db 0
      dw 0xAA55 
  </code></pre>
  
  <p>When i compile this with NASM, it prints out an ASCII symbol. I want it to be able to print out "19", how would I go about doing this?</p>