Beruflich Dokumente
Kultur Dokumente
Development Environment
(for Revolution SDK)
Version 3.1
Confidential
These coded instructions, statements, and computer programs contain proprietary information of Nintendo
of America Inc. and/or Nintendo Company Ltd. and are protected by Federal copyright law. They may not be
disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written
consent of Nintendo.
Contents
1 Overview.............................................................................................................................................. 6
2 System Requirements ......................................................................................................................... 7
3 Hardware .............................................................................................................................................8
3.1 System Firmware....................................................................................................................... 8
4 Preparing Software ............................................................................................................................. 9
4.1 Obtaining Cygwin....................................................................................................................... 9
5 Connecting Hardware........................................................................................................................10
6 Installing Software .............................................................................................................................14
6.1 Cygwin .....................................................................................................................................14
6.2 NDEV Software........................................................................................................................14
6.3 CodeWarrior ............................................................................................................................14
6.4 Revolution SDK .......................................................................................................................15
6.5 Configuration of Environment Variables ..................................................................................15
6.6 Invoking Revolution Shell ........................................................................................................16
7 Running a Demo................................................................................................................................17
8 Building Code ....................................................................................................................................19
9 Troubleshooting.................................................................................................................................20
Code Examples
Code 6-1 RVL NDEV.bat .........................................................................................................................15
Tables
Table 2-1 Operating Environment............................................................................................................. 7
Table 4-1 Components of Revolution Development Environment ............................................................. 9
Table 6-1 Configuring Installation Paths ..................................................................................................15
Figures
Figure 5-1 NDEV System: Rear...............................................................................................................10
Figure 5-2 BT MODE Setting for the Wired Module (Enlarged View of NDEV Rear Panel) ..................11
Figure 5-3 BT MODE Setting for the Wireless Module (Enlarged View of NDEV Rear Panel)..............11
Figure 5-4 NDEV Front Panel ..................................................................................................................12
Figure 5-5 Left Panel of NDEV ................................................................................................................12
Figure 5-6 Right Panel of NDEV ..............................................................................................................13
Figure 9-1 Process to Check an Application when It Has Started but the TV Screen Is Blank ...............20
Figure 9-2 Process to Check an Application when It Sstarts but Debugging Information Is Not Shown .21
Revision History
Date Items
Revision No. Description
Revised (Chapter)
2.2.0 2006/09/28 6.5 Added note about double quotation marks (").
2.2.0 2006/09/19 4.1 Noted that Cygwin version 3.81-1 cannot be used.
Date Items
Revision No. Description
Revised (Chapter)
1 Overview
This document describes how to connect NDEV, install drivers and the Revolution SDK, update system
firmware, and build and run code.
No installer is provided with the Revolution SDK. Instead, developers copy the relevant directories to their
own PC and configure a few environment variables. Device drivers require separate installation.
The goal is to allow the developers to customize the configuration to their own environment, with a
minimum of intrusive system settings. The Revolution SDK is designed to co-exist with other Nintendo
development platforms, such as that for the Nintendo DSTM system.
Note: By default, Wii development hardware may not have the most recent firmware installed. If this is
the case, you must install the appropriate firmware version on the Wii development hardware
before running applications.
2 System Requirements
The Nintendo Revolution Development Environment runs on x86-compatible computers with Microsoft
Windows XP SP2. The required system specifications are as follows.
3 Hardware
The NDEV hardware for the Revolution Development Environment has the following interfaces.
• A USB-based Disc Interface. This enables disc emulation on the developer’s PC.
• A USB-based Debugger Interface. This channel provides debugger control.
• A USB-based Firmware Interface. This channel updates the firmware on the NDEV interface hardware.
• An RS-232 serial-based Terminal Interface. This channel provides terminal output from Revolution
applications.
Note: For maximum performance, we strongly recommend that you plug the USB interfaces directly into
the host controller of your PC rather than a hub.
4 Preparing Software
The Revolution Development Environment requires several software components. Download the software
in Table 4-1 from www.warioworld.com.
File Description
Download the latest setup program from one of the listed mirror sites. Note that you will only be obtaining
the setup program (a file named setup.exe). Within the program, you will be presented with a choice of
packages to install.
The packages provided may vary between sites.
The make utility is required by the SDK build system. Because the latest version of GNU make 3.81
available from the Cygwin site does not support DOS-style path expressions, it cannot be used for builds in
the Revolution development environment. Instead, use GNU make 3.80.1, which runs under the latest
Cygwin environment and is currently distributed on Nintendo’s support site.
Note: When installing the Cygwin package, we recommend that you install it along with the openssl utility
(version 0.9.8b-1). The openssl utility is used by the mastering tools and other utilities. For details,
see the Revolution Mastering Tools Quickstart Guide.
5 Connecting Hardware
Figure 5-1 shows the rear panel of the NDEV system.
Figure 5-1 NDEV System: Rear
SENSOR BAR
LABEL
S/N
AV MULTI OUT
USB3 (DI)
USB2 (COM)
SERIAL
USB1 (DEBUG)
With TeraTerm, the first four of the above settings can be changed when Serial Port is selected in the
toolbar's settings. When Terminal is selected, the last item listed above can be changed. Settings for
both sending and receiving Japanese characters should be SJIS. This can be changed when Terminal
is selected in TeraTerm's toolbar settings.
When turned on, the Device Manager's USB Controller displays one "DI to USB" and two "EXI to USB"
strings.
4. Connect the Sensor Bar to the port marked “SENSOR BAR.”
5. The port marked “AV MULTI OUT” provides audio and video output to your television monitor. Connect
this using a cable according to its intended use and the environment in which it will be used.
6. The switch marked "BT MODE" switches between wired and wireless versions of the Bluetooth
module (set to wireless when shipped). As shown in the following figures, set the switch to the right
when using the wired module, and to the left when using the wireless module. Be sure to toggle
switches only while NDEV power is Off.
A serial number label is attached on the back, in the upper left corner.
Figure 5-2 BT MODE Setting for the Wired Module (Enlarged View of NDEV Rear Panel)
Figure 5-3 BT MODE Setting for the Wireless Module (Enlarged View of NDEV Rear Panel)
Note: The controller ports on the front of the NDEV are ordered from right to left. Leave the DIP
switches on the front panel in the On position.
The NDEV includes an SMA connector for the wired Bluetooth module on the left panel.
Figure 5-5 Left Panel of NDEV
Up to four wired Wii Remotes can be connected by connecting a wired controller hub to the SMA con-
nectors marked "BT WIRED." Note that the player number does not depend on the connector being
connected to. (This is set during registration.) Note that the wired Wii Remote and wired controller hub
should be connected after turning NDEV power Off.
6 Installing Software
6.1 Cygwin
The Revolution SDK build system requires the Cygwin bash shell and developer tools. Ensure that you
have retrieved the appropriate installation package as discussed in Chapter 4, Preparing Software.
Install the Cygwin package. Make a note of where you installed Cygwin, as you’ll need this information
later.
Ensure that you have installed version 3.80.1 of make. Open a shell and type the following command.
% make --version
GNU Make 3.80
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
6.3 CodeWarrior
1. Unzip the contents of the CW_GCN_3_0_XXXXXX.zip archive into a directory of your choice. For exam-
ple, C:\CW_RVL.
Make a note of the destination directory. You will need it to configure environment variables later.
2. After the CodeWarrior installer has finished, execute regservers.bat, found in the bin/ directory of
your CodeWarrior installation. This batch file will register the COM components of the Codewarrior
IDE.
If CodeWarrior for Nintendo DS, or for some other platform, is already installed, its IDE configuration may
be in use. If you want separate IDE configurations for each installation, refer to the section “Using Separate
IDE Configurations” in Developer_Notes - Revolution_Tools.txt, which is included with
CodeWarrior.
Again, make a note of the destination directory. You will need it to configure environment variables
later.
In addition, you must install the appropriate firmware version before running programs. The appropriate
console firmware version is given in the Readme files of the Revolution SDK and the patches that are
used. Do not refer to the Revolution SDK’s Readme file when you install a patch; refer to that patch’s
Readme file instead and install firmware as necessary.
Note: When SDK patches are released, install the patch before using the SDK. Bug fixes and other
issues are fixed by the patches, so their use is strongly recommended.
REM ************************************************************
REM * Revolution SDK - Environment
REM ************************************************************
REM *
REM * Please specify your installation paths here:
REM *
REM ************************************************************
SET REVOLUTION_SDK_ROOT=C:\RVL_SDK
SET CWFOLDER_RVL=C:\CW_RVL
SET CYGWIN_PATH=C:\cygwin
You must change the items in red to match installation directories for each component.
Table 6-1 Configuring Installation Paths
Environment Variable Name Description
% rvl_ide.sh
You may then drag and drop Revolution projects or ELF files into the debugger.
• Only the bash shell is supported.
7 Running a Demo
1. Ensure that all USB cables are connected and that the NDEV is powered on.
2. Open a terminal program and confirm that the COM port is properly configured (for communication
channel settings see Chapter 5, Connecting Hardware).
3. Open a bash shell by double-clicking RVL_NDEV.bat.
4. Next, specify a directory for disc emulation. At the prompt, enter the following.
In this example, we are pointing the disc emulator at the dvddata/ directory where Revolution SDK is
installed. If you have installed your SDK elsewhere, modify the example accordingly. Note that the
emulation system is case-sensitive, so ensure that you specify DvdRoot and not dvdroot.
Note that if you inadvertently specify dvdroot instead of DvdRoot, unset the variable first by issuing
the following command without a value.
% setndenv dvdroot
Note that these NDEV settings will persist across sessions, until you decide to change the location of
DvdRoot.
Note also that the disc emulator requires MS-DOS style paths. When invoking this command, you may
need to enclose the path in quotes.
You can retrieve the current settings by issuing the following.
% getndenv
“DvdRoot” “C:\RVL_SDK\dvddata”
5. Go to:
% cd /cygdrive/c/RVL_SDK/RVL/bin/demos/gxdemo
% ndrun smp-onetri.elf
In addition, clear the Run with CWComUtil option. CWComUtil does not offer complete support
for Wii. To clear the option, from the Edit menu, click Environment Settings, then Debugger,
then GCN Remote Connection, then Run Settings, and then select Run with CWComUtil. By
default, CWComUtil is called first when running programs or debugging. However, its use is not
necessary, as programs can still be run and debugged occur without it.
Configure the script window so that it is displayed. To configure, from the Edit menu, select
Environment Settings, then Debugger, and then GCN Debugger Global Settings. In the dialog
box, clear the Minimize script window check box. When the ndrun_prechecker check called
by ndrun results in a “WARNING,” it will wait for key input; this will not be shown unless the script
window is configured to be displayed.
8 Building Code
To build a single demo, type the following.
% cd /cygdrive/c/RVL_SDK/build/demos/<demo_name>
% make
% make NDEBUG=TRUE
% cd /cygdrive/c/RVL_SDK/build
% make all
% cd /cygdrive/c/RVL_SDK/build
% make clobber
For more details on the Revolution SDK, please refer to the Build System document under the
Programmer’s Guide.
9 Troubleshooting
Use the following steps to perform a check if the NDEV is used to start an application, but the TV screen is
blank.
Figure 9-1 Process to Check an Application when It Has Started but the TV Screen Is Blank
Y Y Y
Does the smp-onetri.elf It is unlikely that the application is at fault, but to be safe,
Are operations normal with N Y
demo program, included check its implementation. If the cause of the bug is still
the Wii Menu uninstalled?
with the SDK, run? unknown, send the NDEV in for repairs.
Y N
Ensure that there were no problems installing the SDK
and NDEV software. If there are no problems with
these, there may be an issue with the NDEV hardware,
so you should send it in for repairs.
Is “Apploader ……”
This condition occurs when an application goes beyond
displayed to the screen at Y
the 9MB Apploader restriction. You must fix your
startup while the Wii Menu
implementation to follow the restriction.
is not installed?
Use the following steps to perform a check when NDEV is used to start an application and debugging
information is not shown.
Figure 9-2 Process to Check an Application when It Sstarts but Debugging Information Is
Not Shown
© 2006-2008 Nintendo
The contents of this document cannot be
duplicated, copied, reprinted, transferred,
distributed or loaned in whole or in part
without the prior approval of Nintendo.