2.2 Modifying polyline

First the sample program polyline will be modified and run on the 64DD. A work directory (called $(WORK) here) will be created, and the program will be copied to that directory and run. (For example, with a work directory of /usr/people/mario/work, the notation $(WORK) should be read as /usr/people/mario/work.)

1. Copy polyline to $(WORK)

[NW]

% cp -r /usr/src/PR/demos/polyline $(WORK)

[PC]

Use a tool such as Explorer to copy ultra\usr\src\PR\demos\polyline to $(WORK)

2. Switch to that directory

[NW]

% cd $(WORK)/polyline

[PC]

Open an MS-DOS window, and enter

C>cd $(WORK)\polyline

3. Open an editor and modify Makefile as shown below.

[NW]

..........
$(MAKEROM) -r rom spec ..........

[PC]

..........
$(MAKEROM) -r rom specifies ..........

(modified) (modified)
..........
/usr/sbin/makedisk -t 0 -r rom spec
..........
..........
$(MAKEROM) -DD64 -t 0 -r rom spec
..........

The -t 0 option specifies a disk type of 0. Disk types are discussed in section 11.5, Disk Types (ROM and RAM areas).

4. Compile

[NW]

% make

[PC]

C>make

5. Start Partner

[NW]

% ptn64

[PC]

Double-click on the Partner N64 PC icon.

The commands that follow are entered in the Partner command box.

6. Insert the 64DD disk

Insert the 64DD disk and write the previously compiled polyline program to the disk.

[ NW and PC ]

> <gwrite

gwrite is a batch file created by makedisk for writing rom images to disk. "<"is a Partner command that runs the subsequently named batch file.

7. Load debugging information

[NW]

> ls lines

[PC]

> ls lines.out (.out can be omitted)

8. Next start the IPL.

Until a disk is inserted, the IPL runs a demonstration. Details are provided in "Chapter 4 64DD Internal ROM" In this example, however, the disk is not ejected after it is written to, so the game is started from the disk without the demonstration.

[ NW and PC ]

>resetdd

9. Run the game (polyline)

[ NW and PC ]

>g

Warning: <gwrite, ls "debugging file name" and "resetdd" can be automatically run in sequence in Partner versions 1.05 or later using the command l debugging information file name. In this section, however, the commands were discussed separately for the purpose of explanation. In the examples that follow, the l command is used.