Graphics samples work, but not text, like hello.

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Graphics samples work, but not text, like hello.

Post by hexperience »

I am able to compile and run teapot and cube, but something like hello or pad_example will compile, but it hangs on my ps2 when I try to run the elf.

Running on linux. ee-gcc ver shows 3.2.2. iop-ee ver shows 2.8.1-ps2dev.

More details if you need them, but I'm hoping I'm doing something fairly common. I am looking for the answer by searching, but any tips will help me out.

Cheers
ooPo
Site Admin
Posts: 2023
Joined: Sat Jan 17, 2004 9:56 am
Location: Canada
Contact:

Post by ooPo »

First of all, your IOP compiler seems very old. Are you using that version for a specific purpose?

Second, what version of ps2link and client are you using?
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Post by hexperience »

Hi, thanks very much for your reply.

I ran the toolchain-oldiop.sh to make sure that I wasn't posting without trying that first. Of course that seems to have been the wrong thing to do.

I'm not using ps2link at all. Using sneeker net and a usb pen drive.

I don't think I did the setup very well. I also don't know how to update from csv.

It's been awhile since I did any C so I'm a bit rusty. But programming the PS2 has got my excitement level up!

Thanks again.
Hex.
ooPo
Site Admin
Posts: 2023
Joined: Sat Jan 17, 2004 9:56 am
Location: Canada
Contact:

Post by ooPo »

Ahhh, no ps2link eh? Try just using scr_init() and scr_printf().
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Post by hexperience »

So would this be considered the minimum includes?

Code: Select all

#include <debug.h>
                                                                                                                                               
int main&#40;&#41;
&#123;
   init_scr&#40;&#41;;
   scr_printf&#40;"Hello, world!\n"&#41;; // hello world in the screen
   return 0;
&#125;
I get this error;

/usr/local/ps2dev/ps2sdk/ee/include/debug.h:23: parse error before "u32"

I guess I should start fresh again with a fresh install of Linux and reinstall the toolchains. Can you point me at a page for the use of the CSV update?

Thanks very much,
Hex.
weltall
Posts: 310
Joined: Fri Feb 20, 2004 1:56 am
Contact:

Post by weltall »

before debug
#include "tamtypes.h"
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Post by hexperience »

Thanks! That, plus adding -ldebug to the EELIBS in the Makefile did the trick.

Cheers
Hex.
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Post by hexperience »

ooPo wrote:First of all, your IOP compiler seems very old. Are you using that version for a specific purpose?
Does the IOP now use 3.2.2 as well? I read in the doc's on your site that IOP uses a different version? I see that the doc file is marked Jan. 2004.

If I re-run the normal toolchain.sh will ip update and overwrite the old IOP version?

Thanks again!
Hex.
ooPo
Site Admin
Posts: 2023
Joined: Sat Jan 17, 2004 9:56 am
Location: Canada
Contact:

Post by ooPo »

The latest version of iop-gcc is based upon gcc-3.2.2, same as ee-gcc. There are still some quirks and other strangeness that happen sometimes so the older iop-gcc is still offered in case the user wants to use that instead.

If you rerun toolchain.sh, it should overwrite the older version, yes.
hexperience
Posts: 19
Joined: Tue Jul 05, 2005 7:35 am

Post by hexperience »

Thanks very much ooPo.

I am now able to run the samples in the PS2SDK from ps2link. I even impressed my 5 year old son by "making a paper airplane". Which was two triangles slightly bent.

I wanted to ask about the other lib's that are around. Where can I find, for example, the SBV lib, if there is one. I try to compile some other sample code and it tells me it's missing.

Did I miss a step?

Is PS2SDK kind of an add on to the main lib's of PS2DEV? If so, I guess I need to correctly get that installed.

Do I need to run a seperate toolchain for that?

Again, thanks very much for your patience.

Cheers
Hex.
Post Reply