Archive for June 2017




The actual book cover

We’re now really getting down to understanding how the Commodore 64 works and how some people managed to program it, in spite of its totally crappy built in Commodore BASIC V2 language, which had no dedicated commands for colour, graphics, or sound, and didn’t support the Hexadecimal numbering system either, as well as Commodore’s crappy manuals totally leading people off track by telling them to PEEK and POKE to 5 digit decimal memory locations, instead of having the locations stored in files as hex labelled by EQU directives.

This year (2017) marks the 35th anniversary of the C64 being released. It also marks the 35th anniversary of me and my Mum running away from the home my Dad had turned into a slum with lots of unfinished DIY jobs and hoarding. Neither of these events is anything to celebrate, especially as my Mum and me ended up having to return to that slum after only about six months.

Some big news on this subject is that since my last post in this series, the companion disk image to this book has been made available on , so you should be able to download that and run it on either a C64 emulator, or on a real C64 or C128 using an SD2IEC device. This means it should be possible to use the programs in the book with the exact syntax used, instead of having to convert them for use in another Assembler. In spite of this, readers should familiarise themselves with the syntax of other Assemblers, otherwise they’ll be stuck using the LEA Assembler.

Some more news, is that I’m going to list a few more 6502 Assembler directives, this time from yet another book about 6502 Assembly Language programming. This is called, surprisingly enough “6502 Assembly Language Programming”, was published by John Wiley & Sons Inc, and was written by THREE WOMEN! You can find it on and elsewhere if you look round. Their names are Judi N Fernandez, Donna N Tabler, and Ruth Ashley. According to Amazon this book was published in 1983, before computers became really popular and there were a lot of women involved in programming computers before then. The book is about Assembly Language, but not on any specific computer. The Introduction/Preface mentions Commodore, Apple, and Atari computers as being 6502 based and that it applies to all those computers as well as to any other 6502 based computer, so it wouldn’t enable you to write any C64 demos. The Assembler Directives used in this book are called DS, ASC, DFB, ORG, and EQU. The labels used in programs in this book are all in upper case text without any characters to indicate that they are labels. Some examples are how the directives are used are as follows…

DS means Define Storage. This can be for any kind of data. One example of this is DS 10 , which reserves 10 bytes of storage.

ASC stores any ASCII text contained in single quotes. An example of this is ASC ‘WHY’

DFB means define byte. Examples given are DFB 3, $15, 12, 7 and DFB ‘H’ , ‘I’

ORG means where to store your code. An example of this is ORG $8000

EQU means equate or equals. An example of this is VIDEO EQU $D000

So, that’s all you need to know for now! This book has a chapter called “Extending BASIC”, but actually there are no extended BASIC commands in the book. All it shows you is how to pass parameters to a SYS command. This isn’t good, but not as bad as certain people listing a graphics program without any way to save your creations. In the next instalment, I’ll be trying to draw some lines across a C64 graphics screen in 6502 Assembly Language, based on an example in the book. I may even try to animate these lines, but that won’t be according to any mathematical formula, because don’t forget I’m useless at maths!

Finally, here’s some artwork I did in the C64 lores screen mode. No programming was required at all, I just used some software called Multipaint, which runs on Linux, Windows, and Mac OSX. I didn’t spend all that long working on it. It gives you a rough impression of the slum I grew up in, which was in stark contrast to the semi detached house next door. I found I couldn’t convert the original graphics file from .bin or .ocp (Advanced Art Studio) to GIF, JPG, or even BMP, so in the end I had to take a pic of it with my Android phone. I hope you enjoy it! 


Posted June 18, 2017 by C64hater in Uncategorized