This is the first tutorial of programming for the Wii and it will cover setting up our environment. These tutorials will be as detailed as I can make them and will try to cover different programming subjects. You can grab the PDF of this tutorial here: codemii-tutorial-1.
Use the automated-installer. Install in C: devkitPro and it will install all the latest versions of the required programs (you can disable devkitPSP, but be sure to enable libctru in devkitARM menu). It will create the environment variables automatically. Linux / Mac OSX. Last Update: 2018-06-04. This project is for homebrew console development tools based on the gnu compiler collection with additional tools and libraries to aid programming each supported console. The windows variants are built with MinGW.
Our first step in order to code for the Wii is to set up the programming environment and for this we are required to download DevKitPro. DevKitPro is a compilation of compilers, useful applications and example source code which will all be set up for us at a click of a button. For those wondering what a compiler is, a compiler is an application which can convert our code into a machine executable format.
So let’s go to www.devkitpro.org, select Downloads then select Windows Installer. This will take you to the sourceforge devkitpro page where you should click on the .exe file to download it. At the time of writing this tutorial it is devkitProUpdater-1.4.7.exe. Save the file somewhere on your computer and then run it.
Once in the installer, say yes to downloading and installing files and yes to keeping the files we download. When it gets to the screen where it’s asking you which components you want to install, you only need to check the minimal system box, devkitPPC box and Programmer’s notepad box. PPC (PowerPC) is the computer hardware which our compiler will compile our source code to. Leave the installation directory as c:devkitpro.
So now we’ve set up the programming environment which was pretty simple wasn’t it?
I will give you a run down of the things included in DevKitPro that will be useful for us.
Firstly we have Programmers Notepad (devkitpro/Programmers Notepad) which is where we will be writing our code in. Programmers notepad makes things a whole lot easier for us by using syntax highlighting, showing line numbers, grouping files into a project, etc.
![Installing Devkitpro Installing Devkitpro](/uploads/1/2/5/8/125859340/552958656.jpg)
The next application we have is called gcube (devkitpro/emulators/gcube) which is a gamecube emulator. This application is quite handy as you can test most of the code that you develop on it. I find it much easier when writing code to test things out on gcube instead of having to turn on the Wii and test it that way. I used gcube to test out the two homebrew games that I made, which were Simon and Matching Cards.
The last thing that is handy is the gamecube and Wii example source code (devkitpro/examples). The source code gives us a template which we can start our applications on. Example source code for the gamecube includes how to access the dvd, memory card, network, etc.
In the next tutorial I’ll cover Makefiles, compiling your first source using the template example, dealing with errors and a very basic run down on the C programming language.
devkitPPC | |
General | |
---|---|
Maintainer(s) | WinterMute |
Type | Library |
Version | r27 |
Licence | Various |
Links | |
Download | |
Website | |
Discussion | |
Source |
devkitPPC is a port of the GNU Compiler Collection (GCC) and includes a C (gcc) and C++ compiler (g++), a debugger (gdb) and associated utilities, with the architecture 'powerpc-eabi'. It also includes standard C libraries based on newlib, which is specifically designed for embedded systems. Compilers and libraries are also included for the MN10200, the Matsushita (Panasonic) chip used in the Wii DVD controller. It is designed to be used in conjunction with libogc, a collection of Wii-specific low-level libraries.
Instructions for setting up the system are available for Windows, Mac OSX and Linux. Additional information and download links can be found at the devkitPro website.
Automated install scripts for Linux can be found at DevkitPPC.sh and DevkitProLinuxInstall. These are 3rd party installers and are not supported by the devkitPRO team. So don't complain to them if they break something.
For Windows users it comes with the MSYS environment, which is a minimal set of GNU tools such as a shell.
Ported libraries
The following libraries are available for download from devkitPro SourceForge, precompiled for use with devkitPPC. Simply place them in the appropriate devkitPPC portlibs folder (on Windows this is c:devkitProportlibsppc).
- Expat - XML parser library
- FreeType - TTF/Type1 font support
- libjpeg - JPEG support library
- libpng - PNG support library
- Mini-XML - XML library
- libtremor - An integer-only fully Vorbis compliant software decoder library
- zlib - ZIP compression/decompression library
Tools
The following tools are included as well:
- doltool - a tool for converting to and from .dol executable files and examining their contents
- gcdspsuite - an assembler for the gamecube DSP chip written by duddie.
- wiiload - a utility for uploading code to the wii written by Dhewg.
- gxtexconv - a utility for texture conversion written by Shagkur.
See also
Retrieved from 'https://wiibrew.org/w/index.php?title=DevkitPPC&oldid=103356'