Category : Assembly Language Source Code
Archive   : JED.ZIP
Filename : WORD2STR.SRC

 
Output of file : WORD2STR.SRC contained in archive : JED.ZIP
;---------------------------------------------------------------
; Word2Str -- Converts a word passed in AX to a string at
; DS:SI
; Last update 3/8/89
;
; 1 entry point:
;
; Word2Str:
; Caller must pass:
; AX : Word to be converted
; DS : Segment of destination string
; SI : Offset of destination string
;---------------------------------------------------------------

Word2Str PROC
mov CX,AX ; Save a copy of convertee in CX
xchg AH,AL ; Swap high and low AX bytes to do high first
call Byte2Str ; Convert AL to string at DS:SI
add SI,2 ; Bump SI to point to second 2 characters
mov AX,CX ; Reload convertee into AX
call Byte2Str ; Convert AL to string at DS:SI
ret ; And we're done!
Word2Str ENDP

  3 Responses to “Category : Assembly Language Source Code
Archive   : JED.ZIP
Filename : WORD2STR.SRC

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/