| View previous topic :: View next topic |
| Author |
Message |
Escher
Joined: 08 Oct 2005 Posts: 2
|
Posted: Sat Oct 08, 2005 5:37 pm Post subject: PSP Wifi code |
|
|
| 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 |
|
 |
CyberBill
Joined: 26 Jul 2005 Posts: 86 Location: Redmond, WA
|
Posted: Sat Oct 08, 2005 5:40 pm Post subject: |
|
|
| There is wifi sample code in the PSPSDK. |
|
| Back to top |
|
 |
Escher
Joined: 08 Oct 2005 Posts: 2
|
Posted: Sat Oct 08, 2005 5:44 pm Post subject: |
|
|
| Ah, thanks. I must have missed it, I'll look again... |
|
| Back to top |
|
 |
CyberBill
Joined: 26 Jul 2005 Posts: 86 Location: Redmond, WA
|
|
| Back to top |
|
 |
jockyw2001
Joined: 29 Sep 2005 Posts: 339
|
Posted: Sat Oct 08, 2005 6:41 pm Post subject: |
|
|
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 |
|
 |
urchin
Joined: 02 Jun 2005 Posts: 121
|
Posted: Sat Oct 08, 2005 6:51 pm Post subject: |
|
|
| I've had a play around with that wifi code. It's pretty easy to add it into your own code. |
|
| Back to top |
|
 |
Jim

Joined: 02 Jul 2005 Posts: 487 Location: Sydney
|
Posted: Mon Oct 10, 2005 8:40 am Post subject: |
|
|
| 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 |
|
 |
matkeupon
Joined: 02 Jul 2005 Posts: 26
|
Posted: Mon Oct 10, 2005 9:57 pm Post subject: |
|
|
| 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 |
|
 |
jockyw2001
Joined: 29 Sep 2005 Posts: 339
|
Posted: Mon Oct 10, 2005 11:20 pm Post subject: |
|
|
| 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 |
|
 |
Jim

Joined: 02 Jul 2005 Posts: 487 Location: Sydney
|
Posted: Tue Oct 11, 2005 9:09 am Post subject: |
|
|
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 |
|
 |
PspPet
Joined: 30 Mar 2005 Posts: 210
|
Posted: Wed Oct 12, 2005 2:22 am Post subject: |
|
|
> 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 |
|
 |
Jim

Joined: 02 Jul 2005 Posts: 487 Location: Sydney
|
Posted: Wed Oct 12, 2005 8:39 am Post subject: |
|
|
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 |
|
 |
|