Welcome! Log In Create A New Profile

Advanced

New to coding and learning. Have a qeustion about helloworld.dol

Posted by chrono36 
New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 05:36AM
I have done everything in the beginner tut for hello world.dol

I tried to figure out WiiLoad but I couldn't get it to work.

Anyway,

It mentions Dolphin as something that can run the .dol

Is that the only program that can run a .dol file?

I tried Snesgx but it couldn't read it.

Im new at this and could use some direction.

Can anyone help me?

I think Im getting a grasp on how devkitppc works but now Im trying to figure out
how get the program I make to play on the Wii.
If that makes any sense to anyone.

Thanks for any help.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 07:03AM
There are three ways I can think of to run a .dol. The first, and longes approch would be to get the .dol on you SD card. You could use an SD reader, or FTPii, and just put it on like any other app. The icon and xml file aren't important. This way is fool-proof, but it takes a while to test it each time.

The second and my perfered method is using WiiLoad. To get this to work both your wii, and your computer must be on the same wireless network. Turn on the Homebrew channel and look at the bottom-right corner and you will see a blinking while light. If this turns solid then the homebrew channel is connected. If it stops blinking, which is normal, just hit the spot that was binking and it will search again. If it doesn't connect again, make sure the wii will connect outside of the homebrew channel, like through the shop channel. Once the light turns solid, press the home button, and in the top left conner it will say Your wii's IP number is 192.168.x.x. remember this number, or just keep the wii on this screen. For the next part I'll assume your using windows. If you are not it is no big deal, the steps aren't that different. Anyways goto the my computer screen. Then right click anywhere in the window and select properties. If your on windows XP then just click on the advanced tab. If you are on Vista of 7 then click the advanced system setting on the left hand side. Next for either operating system click the enviromental variables button on the bottom of the window and another screen will pop up. Under the System variables section click new and type WIILOAD for the name and tcp:192.168.x.x.(replace the x's with your value). You should be setup now, find the wiiload exe and drag the helloworld.dol onto it and you should see it load on the wii. In Programmer's notepad you can also press the shortcut alt+r and it will run. As a note, you wii IP will change sometimes so you will have to go and edit the value of the enviromental variable from time to time.

The final way is through the dolphin emulator for the computer. go to the dolphin website and download the latest release, and extract the files. That is all you have to do. Click on the executable inside the folder and then from the GUI select open. Then find your .dol file and it will run it. I like this method because it is faster than loading onto your wii, and it is nice for configuring the location of text and buttons. The problem is that unless you have your wiimote connected to your computer you wont be able to move the cursor.

If any of this doesn't make sense just ask
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 11:43AM
no it does. Thank you. I will retry WiiLoad like you said.. I think I was doing it wrong...

I didn't know you had to drag the .dol into the WiiLoad.

I will retry it.

Edit: I got it to work!!


So now whats the best strategy for learning how to make cool wiibrew?

Go find source code for a existing app and play with it?

Or try to build my own game or program?

How did you learn it?

Also I decided to see if I could play around with a app (Wiimc)

And I don't see a template for it so I can open it up in the programmers notepad.

I see tons of files. And tons of C and C++ files.

Is it already built? Do I need to compile it in C++ visual first before I can run it off of the Programmers notepad?

Thanks for any help. I appreciate it. :)



Edited 3 time(s). Last edit at 04/20/2010 12:19PM by chrono36.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 01:21PM
I suggest you learn some C first, and go trough the tutorials at [www.codemii.com]

WiiMC (like all media players) is a very complex project. I suggest you look at something simpler.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 03:14PM
After you have gone through the tutorials and think you have a solid understanding, try taking a simple app with source. Get it to compile and then mess with the source and try to change it. I have always found that I learn best when I get to play and modify something I am given.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 20, 2010 08:58PM
Thank you I will do my best to learn C. Are there any simple apps out there that you can suggest to me?

Alot of them are read only with the source I notice....

Thanks again.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 12:16AM
If you want to study some code, here is the list of homebrew that are open source: [wiibrew.org]
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 12:29AM
Cool Thank you Crayon. This will help tremendously.

If I could give you all rep I would.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 12:48AM
I have another quick question.


I understand that when looking at source there's tons of files that makeup the whole game.

Like TetrisWii for example.

There's a Build,Data,Source,etc...

And a MakeFile.

Ive tried but shouldn't the game run or build and play on homebrew when I run it?


Yeah I just tried it to run it again in the programmers notepad with the makefile in the folder and it doesn't do anything.

Am I missing a step?

I guess what Im asking is how do I build the program so the game will play on Homebrew.



Edited 1 time(s). Last edit at 04/21/2010 12:54AM by chrono36.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 03:15AM
If the apps is open-source, open the app and find the file called ~.pnproj. Opening this file will bring up a programmer's notepad screen, and from this point go to tools->make. If successful the app folder will have a .dol and you can run that on your wii, otherwise you will get errors. These errors should be complaining about a library file not being linked, or installed. So you can eith install the library, which could be hard if you new, or find a simpiler source. Most basic apps should only need GRRLIB, which should be easy to install.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 09:56AM
Thank you I will try that g_man

Edit: Ive searched 2 or 3 open source apps for .pnproj and It wasn't there.

I will continue to look for it.

I looked in a open source app that I was pretty sure would have it which was quake
and I still couldn't find it even when I searched for it.

Alot of the open source apps have a svn download:

# Non-members may check out a read-only working copy anonymously over HTTP.
svn checkout [qrevpak.googlecode.com] qrevpak-read-only

Just using quake as a example.

But still no .pnproj

Is it hidden?



Edited 3 time(s). Last edit at 04/21/2010 10:37AM by chrono36.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 02:21PM
It's not hidden, it just doesn't exist because the dev probably isn't using Programmer's Notepad to build the project. Just add your own from the helloworld example and then double click it and run make.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 05:51PM
I don't recommend ports (like quake) as first sources to look at and toy with, ports are most of the time large projects done in a way they work but are not pretty. And have complicated build systems.

Maybe look at something like "BlastGuy" or "Helii", which are pretty simple games and don't contain shitloads of sources.

Also, it seems you lack some understanding about a few things. Especially on the 'tools' and 'how things go' department.

Let me explain a few things.

First, what the Wii runs are the ".dol" files. These can be seen as ".exe" files for the Wii. This is what you want to create, your 'goal' so to say. A ".dol" file is created from sources, most of the time named ".c" or ".cpp" files. The ".c" and ".cpp" files (and other source files) are just text files containing your code.
This is where DevkitPRO steps in, inside DevkitPRO there is this tool called a "compiler" which can compile ".c" and ".cpp" files into a .dol file.

"Programmer's Notepad". While a nice tool, it's just an text editor. It doesn't do much special. It allows you to edit text files and as extra feature it allows you to run "make". Not everyone is fond of this tool, and there are lots of other tools out there that can edit text files and run "make".

Next, "make" this is an important tool, it reads the "Makefile" and executes commands to build files. "make" is a command line tool, and you can run it without anything else. Now, "make" doesn't know anything about the contents of the file and just runs the right compiler tools in the right order.

The example "Makefile" that comes with DevkitPRO works for most people and is quite clever. But not everyone likes it, so some people build different Makefiles. And some (like myself) don't use "make" at all.

So many projects where you will find sources will come without a .pnproj file because they use different text editors. But when you see a Makefile then it shouldn't be that hard to setup Programmer's Notepad to run "make" at the right location. And as all the magic about building is contained within the "Makefile" it shouldn't be a problem at all! (as long as you encounter a Makefile)

For projects without Makefiles, well, stay away from those until you know what you are doing :-)
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 21, 2010 10:06PM
Ok. Thanks for the help Daid.

And the explanation.

I learn new things everyday.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 26, 2010 11:07AM
You mentioned this daid:

"Programmer's Notepad". While a nice tool, it's just an text editor. It doesn't do much special. It allows you to edit text files and as extra feature it allows you to run "make". Not everyone is fond of this tool, and there are lots of other tools out there that can edit text files and run "make".


Can you direct me to another tool that can do the same thing?

Programmers notepad isen't working for me anymore.

When I build something I don't see a output window.(output is enabled-press F8)

When I try to run a program like the simple hello world program
it wont run like it used to.....

It used to automatically run on my Wii and now it wont..

The IP is correct. I checked it in system--environment variables

Can you help?
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 26, 2010 03:00PM
I use [www.codeblocks.org] myself.

Which requires a bit of manual configuration: [wiibrew.org] if you use the internal build system. Or you can setup your project to use the Makefile.
Re: New to coding and learning. Have a qeustion about helloworld.dol
April 26, 2010 07:45PM
Thanks Daid. I will check it out.
Sorry, only registered users may post in this forum.

Click here to login