<VCCC2022>
Author: Harm Backer
Category: Christmas Challenge 2022
System: IBM PC 8086 resp. Windows 11 with DOSBox
Language: Assembler (Microsoft (R) Macro Assembler Version 6.14.8444) - 16 bit program
Len source code: <# bytes>
Len exe file: no exe file. .com file length is 80 bytes
Len code only: 62 bytes (pure code), remaining 18 bytes is data
Instructions:
Install DOSBox
create folder VCCC2022 as subfolder of DOSBox folder
copy program VCCC2022.com to VCCC2022 subfolder
Use DOSBox with following autoexec entries:
--- snip ---
@echo off
mount C C:\DOSBOX
c:
cd \VCCC2022
cls
VCCC2022.com
dir VCCC2022.com
pause
exit
--- snip ---
Description:
The code reads a table with 2 bytes per line.
The 2 bytes (16 bits) contain a 0 for space and a 1 for asterisk.
Once 2 bytes are loaded into AX register, 16 times a shift left command is issued to
bring the first bit into the carry flag. This is used to decide to print space or asterisk.
When that 16 bits are done, a trailing linefeed character is issued.
Only the first 9 lines are represented in the table - once at the end, the table is processed backwards.
Comments:
Great idea to have such a challenge, thank you very much!
Was fun to code once again like in the good old times!