Saturday 28 September 2013

C64 Coding - Part 2 - Setting Up

So, you have downloaded all components from part one. Perhaps you've also installed them... but if not, here is the way I did it:

  • Notepad++ - default installation. Easy!
  • dasm - installed to a location within a C64-related folder (see below)
  • VICE - same again
I have a second drive in my PC, used for data (and games). I have labelled this drive E:

The folder structure will reflect this, but if you only have one drive, or have a different drive letter arrangement, substituting it for E: should be good enough to replicate my steps below.

Note: all steps assume Windows 7 usage. (If enough people ask, I shall also detail how to do this on the Mac.)

I firstly opened a command prompt and created a C64 folder.
  1. Press the Windows key, to bring up the search box.
  2. Type "cmd" and press Enter. This should bring up a black DOS command prompt window.
  3. Type "E:" and press Enter (which should place you on the E: drive)
  4. Type "mkdir C64" and press enter. This should create your very own C64 working folder.
  5. Type "cd C64" to enter the folder.
Basic folder created!

Now, I prefer to separate my tools from my code, so I used the following command window steps to create separate folders for development.
  1. mkdir src
  2. mkdir dasm
  3. mkdir vice
Both dasm and VICE come as compressed zip (or equivalent) archives. I chose to expand these archives to the folders illustrated in steps 2 and 3, to keep them separated.

So that I could run both apps instantly every time I opened a command prompt window, I did the following:

  1. Click on the Start menu button.
  2. Right-click on "Computer"
  3. Select "Properties"
  4. Select "Advanced System Settings"
You should arrive at this window:



  1. Select "Environment Variables..."
  2. Under "System variables", locate and select the entry for "Path".
  3. Click the "Edit..." button
This will present you with a dialog for editing the system paths that the command prompt will check for existing commands.
  1. Click on the "Variable value" edit field.
  2. Press the End key to jump to the end of the field.
  3. Type ";" (semi colon)
  4. Add the full path to the binary directory in the dasm folder you created earlier, e.g. "E:\C64\dasm\dasm-2.20.11\bin" (look for the "bin" folder in what you expanded)
  5. Type ";"
  6. Add the full path to the VICE folder you extracted earlier, e.g. "E:\C64\vice\WinVICE-2.2-x64"
  7. Click the OK button on the variable dialog.
  8. Click the OK button on the Environment Variables dialog.
  9. Click the OK button on the System Preferences dialog.
If you have a command window open, close and reopen it. Then from the command prompt, type:

dasm.exe

and press Enter. If all is well, you should get a usage report from the dasm tool, no matter where you are located in the file system.

Do the same for:

x64.exe

which should also test the same thing for WinVICE.

If all is well, you are ready to go! Simply use the command prompt window to move to the "src" folder with:

E:
cd E:\C64\src

and you will be in the right place to make some C64 code!

No comments:

Post a Comment