The MSX-C development environment


Note: this article was published originally as the 4th chapter in my Relearning MSX series. Cover photo by Markus Vordermeier. Used under permission.

It's time to prepare our development environment. We'll develop using primarily MSX-C v1.2, and maybe some small stuff in assembler from time to time.

Don't worry if you don't have the hardware or software. Everything is available for emulators. This is what we'll use:


MSX-DOS2

MSX-DOS2 ad. MSX Magazine (December 1988)

Often referred to as DOS2 (which is exactly what I'll do from this point) is a disk operating system for MSX released by ASCII Corporation (now ASCII Media Works) in 1988. Its file system was compatible with MS-DOS 2.x including support for directories. Until DOS2 we could have only up to 112 files per disk, all in the disk root. DOS2 also added support for memory mappers, input/output redirection, environment variables, RAM disk and Japanese text, among other features.

The DOS2 package came with a ROM cartridge containing the Disk ROM functions, and two floppy disks, both containing the kernel (MSXDOS2.SYS) and command interpreter (COMMAND2.COM). One of the disks contains the Japanese version of DOS2, and the other contains the English version.

There were at least three versions of the DOS2 cartridge:

  • MSX-DOS2 ROM, no RAM
  • MSX-DOS2 ROM, 128 KB RAM expansion
  • MSX-DOS2 ROM, 256 KB RAM expansion

The first two were released in 1988, and the 256 KB version was released in mid-1989.

We will be using the cartridge without RAM with the English system disk.


MSX Professional Development Tools

MSX Professional Development Tools. MSX Magazine ad (February 1988)

The MSX Professional Development Tools (MSX PDT) was a set of software tools released by ASCII targetting software developers. It consisted on the following packages, all sold separately:


MSX-DOS TOOLS

This package contains MSX-DOS and a bunch of miscellaneous command line utilities to work with disks and files. More importantly, it contains the assembler, linker, and library management utilities used by MSX-C. It also comes with a text editor.


MSX-S BUG

A symbolic debugger. Helps you troubleshoot problems in your applications during development.

We won't be needing this one for now.


MSX-C

The compiler itself is split in several smaller applications: CF.COM (parser), CG.COM (code generator), FPC.COM (function parameter checker) and MX.COM (module extracting utility). The floppy included contains these applications, plus all the C header files, precompiled relocatable object files for the MSX-C runtime and libraries, plus the C and assembler source code for all of these.

If all of this sounds like technical mumbo-jumbo then you're not alone. Don't worry, we don't really need to know much about how these work in order to compile our programs.


MSX-C Library

You don't need this package to write simple command-line applications, but it is a must when developing games or more complex applications.

MSX-C Library doesn't include any command-line tool for MSX-C. It's just a bunch of header files and relocatable object libraries that expand MSX-C to support things like:

  • MSX ROM-BIOS functions
  • Access to VDP commands
  • Graphical functions (line, circle, paint, point, copy, etc...)
  • Sprites
  • Mouse, joystick, cursor keys, triggers
  • Printer
  • PSG
  • 32-bit integers and 64-bit floats (types SLONG and XDOUBLE)
  • Type conversion functions for the new numeric types
  • Slots
  • Cursor management (MSX-CURSES)

MSX-DOS2 versions released in 1989

MSX PDT series for DOS2. MSX Magazine (August 1989)

In 1989 ASCII released updated versions of the MSX Professional Development Tools: MSX-DOS2 TOOLS, MSX-S BUG2 and MSX-C v1.2. The most obvious change is that now now all the applications come with full directory support. Also, many of the applications are smaller because they don't handle I/O redirection anymore (as that's done by DOS2 itself). The compiler is updated to support environment variables to specify settings like the directory where include files reside and so on.

MSX-DOS2 TOOLS also include two very decent text editors: KID and AKID. KID runs in graphical mode and has full support for kanji, and also has Japanese menus. AKID runs in text mode and is much faster, but only supports ASCII text and the menus are in English. Which one you use is up to you, but I will be using AKID.

That's all for this post. In the next one we'll set up the hardware (under an emulator), we will download all the software and install the compiler, libraries and tools so we can start compiling programs.

Post a comment

You need to sign in in order to comment.