Multiplayer

Discuss the development of new homebrew software, tools and libraries.

Moderators: cheriff, TyRaNiD

Post Reply
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Multiplayer

Post by DarkShadow44 »

Hello !
Can you give me a short example (best would be a little application), how to use
1) Ad-Hoc Connections
2) Internet Playing (Later with Broadcating)
between 2 or more PSPs ?

The PspSDK Examples don't Start...

Thanks in advance !
sauron_le_noir
Posts: 203
Joined: Sat Jul 05, 2008 8:03 am

Post by sauron_le_noir »

hi,

look at the site of zorba
http://pspzorba.com//articles/articles.php?id=78&cat=10
he has some working samples and tutorial to use ad hoc communication
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

Thanks !!
But I thinks that's for cygwin...

Could you give me a working Makefile for devkitPSP ? (I don't know how to use this Options, so it throws always errors :-( )
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

You shouldn't be using devkitPSP - it's old. Get one of Heimdall's packages.

http://forums.ps2dev.org/viewtopic.php?t=12149
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

Solved the Makefile Problems.

What's better with this new SDK ?
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

DevkitWhatever is ALWAYS out of date, but Heimdall's packages are brand spanking new! You can't do some things with devkitPSP that you can with Heimdall's stuff. The last version of devkitPSP I saw didn't even handle user-mode homebrew! All homebrew these days should be user-mode style homebrew. Anyone making 1.50-based homebrew is to be pointed and laughed at. :)
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

Wow. Thanks for your help.
These dialogs are very useful :-))

My only problem is than my object is displayed teo times :-(
I didn't change any code.
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

What's "teo"? Two? Ten? And you have yet to show any code. :)
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

It's displayed twice.
And the colors are not good...
The code is from here:
http://ghoti.nl/PSPtutorial12.php
J.F.
Posts: 2906
Joined: Sun Feb 22, 2004 11:41 am

Post by J.F. »

Works fine for me - I userized it like I mentioned in the other thread, so the makefile is

Code: Select all

TARGET = out

OBJS = $(wildcard *.cpp) $(wildcard *.c)



INCDIR =

CFLAGS = -O2 -G0 -Wall -g

CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti -g

ASFLAGS = $(CFLAGS)



LIBDIR =

LDFLAGS =

LIBS = -lc -g -lpspgum -lpspgu -lpng -lz -lstdc++ -lm -lpsppower



BUILD_PRX = 1

PSP_FW_VERSION = 500

PSP_LARGE_MEMORY = 1



EXTRA_TARGETS = EBOOT.PBP

PSP_EBOOT_TITLE = Tutorial 12



PSPSDK=$(shell psp-config --pspsdk-path)

include $(PSPSDK)/lib/build.mak

and main.cpp has these lines

Code: Select all

// MODULE INITIALISATION



PSP_MODULE_INFO("Tutorial2", 0, 1, 1);

PSP_MAIN_THREAD_ATTR(PSP_THREAD_ATTR_USER|PSP_THREAD_ATTR_VFPU);

PSP_HEAP_SIZE_KB(-256);

It compiles just fine at that point, and runs fine in 5.00 M33-6. Be sure to copy all the .png, .mtl, and .obj files to the PSP along with the EBOOT.PBP.
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

But can you maybe post a short example (all other don't work with the newsetst pspSDK) how to conect to an AP (With 5.00 m33-6) ?

And maybe a short programm that connects two PSP and sends a bit text (Also 5.00 m33-6) ??

Please...
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

Can't someone post two short examples for 5.00 m33-6 ???

1) WIFI (with AP) Sample
2) AD-HOC Sample

But not zorba, that' too old...

Please !
slasher2661996
Posts: 91
Joined: Sun Feb 22, 2009 8:32 am
Location: Melbourne Australia ZOMG

Post by slasher2661996 »

No it's not, download it, and YOU make it new
DarkShadow44
Posts: 29
Joined: Thu Jul 09, 2009 4:13 am

Post by DarkShadow44 »

It throws errors like this:

Code: Select all

cannot convert 'char*' to 'SceNetApctlInfo*' for argument '2' to 'int sceNetApctlGetInfo(int,SceNetApctlInfo*)
I tried it with cygwin (original MAKEFILE) and with pspSDK 9.5.0 (With devkitPSP it works, but that is VERY old)
sakya
Posts: 190
Joined: Fri Apr 28, 2006 5:48 pm
Contact:

Post by sakya »

Hi! :)

From pspnet_apctl.h

Code: Select all

/**
 * Get the apctl information.
 *
 * @param code - One of the PSP_NET_APCTL_INFO_* defines.
 *
 * @param pInfo - Pointer to a ::SceNetApctlInfo.
 *
 * @return < 0 on error.
 */
int sceNetApctlGetInfo&#40;int code, union SceNetApctlInfo *pInfo&#41;;
Ciaooo
Sakya
Post Reply