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 

PSP Wifi code

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



Joined: 08 Oct 2005
Posts: 2

PostPosted: Sat Oct 08, 2005 5:37 pm    Post subject: PSP Wifi code Reply with quote

Hi, I'm working on a super-stripped-down gecko engine browser for the PSP, and I'm sort of in the dark about using the PSP's wifi. If anyone could point me towards a helpful tut or could perhaps donate a bit of code, it would be greatly appreciated.
Back to top
View user's profile Send private message
CyberBill



Joined: 26 Jul 2005
Posts: 86
Location: Redmond, WA

PostPosted: Sat Oct 08, 2005 5:40 pm    Post subject: Reply with quote

There is wifi sample code in the PSPSDK.
Back to top
View user's profile Send private message AIM Address MSN Messenger
Escher



Joined: 08 Oct 2005
Posts: 2

PostPosted: Sat Oct 08, 2005 5:44 pm    Post subject: Reply with quote

Ah, thanks. I must have missed it, I'll look again...
Back to top
View user's profile Send private message
CyberBill



Joined: 26 Jul 2005
Posts: 86
Location: Redmond, WA

PostPosted: Sat Oct 08, 2005 5:48 pm    Post subject: Reply with quote

Ooops, I jumped the gun. I thought it had been added but it has not. Heres the link:

http://aibohack.com/psp/wifitest.htm
Back to top
View user's profile Send private message AIM Address MSN Messenger
jockyw2001



Joined: 29 Sep 2005
Posts: 339

PostPosted: Sat Oct 08, 2005 6:41 pm    Post subject: Reply with quote

I will try to port a CIFS client on top of it. This will allow us accessing shared Windows and Samba directories. Did anyone try that already?

/JockyW
Back to top
View user's profile Send private message
urchin



Joined: 02 Jun 2005
Posts: 121

PostPosted: Sat Oct 08, 2005 6:51 pm    Post subject: Reply with quote

I've had a play around with that wifi code. It's pretty easy to add it into your own code.
Back to top
View user's profile Send private message
Jim



Joined: 02 Jul 2005
Posts: 487
Location: Sydney

PostPosted: Mon Oct 10, 2005 8:40 am    Post subject: Reply with quote

Quote:
I will try to port a CIFS client on top of it. This will allow us accessing shared Windows and Samba directories. Did anyone try that already?


Neither samba, cifs vfs, or ecifs is an easy port. I spent a few hours on this at the weekend. Samba and cifs vfs need half of Linux porting to PSP (because the SMB/CIFS part isn't abstracted from the file system mounting part) and eCIFS is multithreaded. There's also jcifs which is java.

It might be simpler to roll a new basic raw smb client for PSP than try to port any of those. Did you have another client in mind?

Jim
_________________
http://www.dbfinteractive.com
Back to top
View user's profile Send private message Visit poster's website
matkeupon



Joined: 02 Jul 2005
Posts: 26

PostPosted: Mon Oct 10, 2005 9:57 pm    Post subject: Reply with quote

urchin wrote:
I've had a play around with that wifi code. It's pretty easy to add it into your own code.


Well, it's easy if your code runs in kernel mode. I'm trying to add wifi multiplayer on my game, but it won't support running in kernel mode (the game loads ok, but hangs on the splash screen).
I tried to setup a kernel thread in the constructor, and load the prxs from there. The prxs load ok, but sceNetInit() (nlhInit() ) fails with a huge negative number (-217.........).

I'm using pspkrazy's ftp client code.
Back to top
View user's profile Send private message
jockyw2001



Joined: 29 Sep 2005
Posts: 339

PostPosted: Mon Oct 10, 2005 11:20 pm    Post subject: Reply with quote

Jim wrote:
Neither samba, cifs vfs, or ecifs is an easy port. I spent a few hours on this at the weekend. Samba and cifs vfs need half of Linux porting to PSP (because the SMB/CIFS part isn't abstracted from the file system mounting part) and eCIFS is multithreaded. There's also jcifs which is java.

It might be simpler to roll a new basic raw smb client for PSP than try to port any of those. Did you have another client in mind?

Jim

I had the same experience last weekend:P It would be a lot easier if the PSP would be POSIX compliant, or much better if it would run linux ... But it doesn't, so we have to find some kind of solution. I will make one more attempt on CIFS, there is this product called Sharity (www.obdev.at/products/sharity/). It's not GPL or LGPL so not particular suitable. I'm a bit surprised that leight-weight CIFS clients are so hard to find. There are plenty of non-POSIX embedded systems running CIFS, so I was hoping it wouldn't be that difficult to find sourcecode.

The other solution I was thinking of is porting a leight-weight tcp/ip stack e.g. lwIP and then port a NFS client. I have to study pspkrazy's ftp client code, maybe that can speed up things a bit.

/JockyW
Back to top
View user's profile Send private message
Jim



Joined: 02 Jul 2005
Posts: 487
Location: Sydney

PostPosted: Tue Oct 11, 2005 9:09 am    Post subject: Reply with quote

If you read http://www.ubiqx.org/cifs/ it will become very clear why there are no lightweight cifs clients.
eCIFS is easily the closest, but we don't have posix threads.

Noone knows if you can send raw packets yet, so lightweight IP might be impossible. It would be easier and better to make a bsd sockets compliant API over the PSPSDK one.

Jim
_________________
http://www.dbfinteractive.com
Back to top
View user's profile Send private message Visit poster's website
PspPet



Joined: 30 Mar 2005
Posts: 210

PostPosted: Wed Oct 12, 2005 2:22 am    Post subject: Reply with quote

> It would be easier and better to make a bsd sockets compliant API over the PSPSDK one.
Not sure what you are looking for.
The PSP sceNetInet API is patterned after BSD/Berkeley. You need to add a few #defines (#define bind sceNetInetBind etc).
It is not 100% compliant especially when it comes to socket options and timeouts etc. No easy work arounds for some of these limitations.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Jim



Joined: 02 Jul 2005
Posts: 487
Location: Sydney

PostPosted: Wed Oct 12, 2005 8:39 am    Post subject: Reply with quote

That's exactly what I mean. If you're porting other people's code and the PSPSDK setsockopt(SO_RCVTIMO) doesn't work then you're probably stuffed. Reworking to get round a design that needs that will be tricky.
Don't get me wrong though, I think the work done so far will get many ports over the line.

Jim
_________________
http://www.dbfinteractive.com
Back to top
View user's profile Send private message Visit poster's website
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