A little bit of assembler to honour one of my favourite series at the moment.
This time in the old 16-bit fashion of DOS coded in DEBUG.EXE
Output: Mr.Robot
100 mov dx,10a // Hold the initial offset memory value for the loop
103 mov al,4d // “M” [write char]
105 mov ah,0e //BIOS function to write a character to screen
107 int 10; //BIOS interrupt/call
109 add dx,4 // Add 4 bytes to the 10a jmp memory address for the loop
10C jmp dx // [Offset change +4]
10E mov al,72 // “r”
110 jmp 105 // [GOTO write char]
112 mov al,2e // “.”
116 jmp 105 // [GOTO write char]
118 mov al,52 // “R”
11A jmp 105 // [GOTO write char]
11C mov al,6f // “o”
11E jmp 105 // [GOTO write char]
120 mov al,62 // “b”
122 jmp 105 // [GOTO write char]
124 mov al,6f // “o”
126 jmp 105 // [GOTO write char]
128 mov al,74 // “t”
12A jmp 105 // [GOTO write char]
12C mov ax,4c // DOS exit function
12F int 21 // DOS interrupt/call
103 mov al,4d // “M” [write char]
105 mov ah,0e //BIOS function to write a character to screen
107 int 10; //BIOS interrupt/call
109 add dx,4 // Add 4 bytes to the 10a jmp memory address for the loop
10C jmp dx // [Offset change +4]
10E mov al,72 // “r”
110 jmp 105 // [GOTO write char]
112 mov al,2e // “.”
116 jmp 105 // [GOTO write char]
118 mov al,52 // “R”
11A jmp 105 // [GOTO write char]
11C mov al,6f // “o”
11E jmp 105 // [GOTO write char]
120 mov al,62 // “b”
122 jmp 105 // [GOTO write char]
124 mov al,6f // “o”
126 jmp 105 // [GOTO write char]
128 mov al,74 // “t”
12A jmp 105 // [GOTO write char]
12C mov ax,4c // DOS exit function
12F int 21 // DOS interrupt/call
No comments:
Post a Comment