forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

What are the PSP Network functions?

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
seventoes



Joined: 02 Oct 2005
Posts: 79

PostPosted: Sun Oct 02, 2005 4:54 am    Post subject: What are the PSP Network functions? Reply with quote

I am working on a game right now that will require network access, how would i be able to send packets and stuff to the master server? I know how to get all of the user's network configuration and stuff, but not how to send packets/threads/files whatever their called...

Sry if i sound noob-ie, but im new to PSP programming, but not C/C++.
Back to top
View user's profile Send private message
sambro



Joined: 29 Sep 2005
Posts: 7

PostPosted: Sun Oct 02, 2005 6:47 am    Post subject: Reply with quote

http://aibohack.com/psp/wifitest.htm

Search function rocks :)

-Sam

PS: Yup, they're packets. :P If you're not noob to C++ then you should have known that O.o
Back to top
View user's profile Send private message
seventoes



Joined: 02 Oct 2005
Posts: 79

PostPosted: Sun Oct 02, 2005 12:37 pm    Post subject: Reply with quote

Well im not a noob to c++, but ive never used any networking thing before, only local apps

EDIT: Oh, and thanks for the link :)
Back to top
View user's profile Send private message
sambro



Joined: 29 Sep 2005
Posts: 7

PostPosted: Sun Oct 02, 2005 6:16 pm    Post subject: Reply with quote

No worries.

Sorry if my post sounded rude, I didn't mean it like that :) Wrote that post not long after I woke up (slow riser)
Back to top
View user's profile Send private message
seventoes



Joined: 02 Oct 2005
Posts: 79

PostPosted: Mon Oct 03, 2005 3:00 am    Post subject: Reply with quote

Lol ok, but is there any simpler examples? This one has WAY more than i need, i just need to know how to send packets to other systems...
Back to top
View user's profile Send private message
PspPet



Joined: 30 Mar 2005
Posts: 210

PostPosted: Mon Oct 03, 2005 3:18 am    Post subject: Reply with quote

> Lol ok, but is there any simpler examples?
The core code is in nlh.c. Look at any of the packet send parts. It is four samples in one - pick one that is closest to your case.
The other features (like picking a connection, and checking for timeouts) are things you need to do.

If you have never used Berkeley style sockets before, you may want to read up on it first.
Eventually the WiFi APIs will be supported in the SDK, and samples can be much simpler.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
seventoes



Joined: 02 Oct 2005
Posts: 79

PostPosted: Mon Oct 03, 2005 3:40 am    Post subject: Reply with quote

Oh.. Well i dont see any send functions in there... maybe i should look over it more.....
Back to top
View user's profile Send private message
sambro



Joined: 29 Sep 2005
Posts: 7

PostPosted: Mon Oct 03, 2005 6:39 am    Post subject: Reply with quote

You're not seeing many functions because they're only declarations in the my_socket.h file (the firmware does the actual gruntwork)

What might be easier is if you do what PspPet said and learn about old school sockets. The easiest way down that path is to learn winsock.

When you have that understood, the transition to PSP networking can almost be seamless.

Just do something like this in the my_socket.h file:

Code:

  #define bind sceNetInetBind
  #define listen sceNetInetListen
  #define accept sceNetInetAccept
  #define connect sceNetInetConnect


Etc etc. The methods look strange now, but as I said earlier, a quick dabble in Winsock should get you on track.

-Sam

Pssssst... http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/winsock/winsock_reference.asp :)
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group