Hello World
'Hello World' is the traditional first program on a new platform. It It's purpose is to allow one to work out the mechanics of software development without being distracted by the details of program logic. In the Atari 2600, there is quite a bit of code required just to be able to wrtie anything to the screen, and this is why I'm providing that code for you. It merely outputs the message 'Hello World!'. So you can see it's output in the image below.
Click the 'See the Code' to both see and run the code. Once you are in the code, you may find it interesting to perform the following experiments.
Experiments
- Change BACKGROUND_COLOR on line 33 to something other than blue (128).
- Change MESSAGE_COLOR on line 35 to something other than white (255).
- Change LETTER_SIZE on line 41. Try the alternate values suggested in the comments.
- Change the ldx (load x register) instruction on line 87 to load something other than 35. Numbers less than 20 fail in a way that should be familiar to anyone that has used one of the old analog television sets.
