wlanGPSend & wlanGPRecv ??
wlanGPSend & wlanGPRecv ??
Anybody know what thies functions are for and what their purpose is?
Any idea if they can be used for communication between units?
-- link --
http://pspdev.ofcode.com/api.php?type=2&id=178
Any idea if they can be used for communication between units?
-- link --
http://pspdev.ofcode.com/api.php?type=2&id=178
As mentioned, the sceWlan APIs are very low level.
Not recommended for use.
> Any idea if they can be used for communication between units?
For regular PSP -> PSP communication, I recommend the standard sockets API (sceNetInet). One PSP must act as a server, the other as a client. You will need to tell the client the IP Address of the server.
Similar to how you write networking code on many other platforms. See my WiFi .02 sample for tricky driver init.
http://pspdev.ofcode.com/api.php?type=2&id=201
(TCP/IP or UDP/IP protocols, ie. socket "sendto" is "sceNetInetSendto")
-----
BTW:
Uses the PSP "Infrastructure Mode" network settings - whether used with a true access point or WiFi adhoc. Manually set IP Addresses required (no DHCP)
(related topic: http://forums.ps2dev.org/viewtopic.php?t=2471)
=========
Alternatively, the PSP "game-sharing-adhoc" communication protocol can be used (the way PSP "game sharing" is done)
Non-standard PSP specific API
http://pspdev.ofcode.com/api.php?type=2&id=191
A working sample is not yet complete! (so I don't recommend this approach right now unless you want to do some experimentation)
Overview: allows PSP -> PSP communication without IP addresses, either with hard coded MAC addresses or with PSP specific discovery features (not all worked out yet)
Not standard TCP/IP or UDP/IP (ie. "sceNetAdhocPdpSend" is similar to "sendto" but using MAC addresses)
Uses the PSP "Adhoc Mode" network settings (ie. channel nothing more). Much easier to setup. Will work between two HomeBrew PSPs (so the audience is relatively small)
Not recommended for use.
> Any idea if they can be used for communication between units?
For regular PSP -> PSP communication, I recommend the standard sockets API (sceNetInet). One PSP must act as a server, the other as a client. You will need to tell the client the IP Address of the server.
Similar to how you write networking code on many other platforms. See my WiFi .02 sample for tricky driver init.
http://pspdev.ofcode.com/api.php?type=2&id=201
(TCP/IP or UDP/IP protocols, ie. socket "sendto" is "sceNetInetSendto")
-----
BTW:
Uses the PSP "Infrastructure Mode" network settings - whether used with a true access point or WiFi adhoc. Manually set IP Addresses required (no DHCP)
(related topic: http://forums.ps2dev.org/viewtopic.php?t=2471)
=========
Alternatively, the PSP "game-sharing-adhoc" communication protocol can be used (the way PSP "game sharing" is done)
Non-standard PSP specific API
http://pspdev.ofcode.com/api.php?type=2&id=191
A working sample is not yet complete! (so I don't recommend this approach right now unless you want to do some experimentation)
Overview: allows PSP -> PSP communication without IP addresses, either with hard coded MAC addresses or with PSP specific discovery features (not all worked out yet)
Not standard TCP/IP or UDP/IP (ie. "sceNetAdhocPdpSend" is similar to "sendto" but using MAC addresses)
Uses the PSP "Adhoc Mode" network settings (ie. channel nothing more). Much easier to setup. Will work between two HomeBrew PSPs (so the audience is relatively small)
> Is the only way to go psp to psp via "Infrastructure Mode" is going though a router or can you go directly from psp to psp (adhavoc style) with Infrastructure Mode using ips ...
You can do both / either, using IP addresses (TCP/IP or UDP/IP usually)
[no need to use MAC addresses using this approach]
See that related thread: http://forums.ps2dev.org/viewtopic.php?t=2471
PSP "Infrastructure Mode" is somewhat misleading since it can be used with WiFi Infrastructure mode (ie. an access point/wireless router) or WiFi Adhoc (peer to peer)
You can do both / either, using IP addresses (TCP/IP or UDP/IP usually)
[no need to use MAC addresses using this approach]
See that related thread: http://forums.ps2dev.org/viewtopic.php?t=2471
PSP "Infrastructure Mode" is somewhat misleading since it can be used with WiFi Infrastructure mode (ie. an access point/wireless router) or WiFi Adhoc (peer to peer)
Few questions after looking over your stuff.
1) Say if I wanted to do a test to do a file transfer program based on your TestPhotoFrame. To send would I pretty much follow the same steps but insted do sceNetInetSendto?
2) Is there a delay from the use of sceNetInetRecvfrom? I'm guessing every call it trys to establish a connection?
3) if 2 is true, how would I establish a pernament connection to a unit. Would the host follow the same standards and set it self to ip 0.0.0.0 to listen for any incomming request? I am guessing I would need to use sceNetInetConnect, sceNetInetListen, & sceNetInetAccept functions to establish a connection between units?
Thanks for all help you give & your wifi test. Suprise I have not seen any psp stuff try to study your demo and build wifi software.
1) Say if I wanted to do a test to do a file transfer program based on your TestPhotoFrame. To send would I pretty much follow the same steps but insted do sceNetInetSendto?
2) Is there a delay from the use of sceNetInetRecvfrom? I'm guessing every call it trys to establish a connection?
3) if 2 is true, how would I establish a pernament connection to a unit. Would the host follow the same standards and set it self to ip 0.0.0.0 to listen for any incomming request? I am guessing I would need to use sceNetInetConnect, sceNetInetListen, & sceNetInetAccept functions to establish a connection between units?
Thanks for all help you give & your wifi test. Suprise I have not seen any psp stuff try to study your demo and build wifi software.
> The inet api of the PSP is like standard POSIX sockets. Just study how unix sockets work and you're done.
Good advice.
Short primer for this discussion, the two common protocols/uses:
TCP/IP -- more robust connection based communication (system will retry if packet is lost), data is often text & sometimes binary, prime examples: telnet, ftp, http. Use "send" and "recv" after a connection is setup.
UDP/IP - connectionless, no retrying, less overhead, data is often binary. Use "sendto" and "recvfrom"
My "WiFi .02" sample has samples of a TCP/IP server (PSP TelnetD), a UDP/IP server (PSP PhotoFrame), a UDP/IP client (PC program 'udpsend'), and two TCP/IP client programs (PSP ClieSpy and AiboCam).
> 1) Say if I wanted to do a test to do a file transfer program based on your TestPhotoFrame. To send would I pretty much follow the same steps but insted do sceNetInetSendto?
You should probably use TCP/IP (a connection protocol). Base it off the simple TelnetD or the much more robust FTP server app.
> 2) Is there a delay from the use of sceNetInetRecvfrom? I'm guessing every call it trys to establish a connection?
Usually used with UDP/IP, it is fast, no connections. Good for sending video frames or other binary data (like two player realtime game sync info) with little overhead. As long as you can live with a few dropped frames, and/or add your own recovery on top !!
> 3) if 2 is true, how would I establish a pernament connection to a unit
See the TCP/IP samples, similar to what you describe:
"sceInetBind" to 0.0.0.0, "sceNetInetListen" and "sceNetInetAccept" on the server side.
"sceNetInetConnect" on the client side (or use my helper)
Good advice.
Short primer for this discussion, the two common protocols/uses:
TCP/IP -- more robust connection based communication (system will retry if packet is lost), data is often text & sometimes binary, prime examples: telnet, ftp, http. Use "send" and "recv" after a connection is setup.
UDP/IP - connectionless, no retrying, less overhead, data is often binary. Use "sendto" and "recvfrom"
My "WiFi .02" sample has samples of a TCP/IP server (PSP TelnetD), a UDP/IP server (PSP PhotoFrame), a UDP/IP client (PC program 'udpsend'), and two TCP/IP client programs (PSP ClieSpy and AiboCam).
> 1) Say if I wanted to do a test to do a file transfer program based on your TestPhotoFrame. To send would I pretty much follow the same steps but insted do sceNetInetSendto?
You should probably use TCP/IP (a connection protocol). Base it off the simple TelnetD or the much more robust FTP server app.
> 2) Is there a delay from the use of sceNetInetRecvfrom? I'm guessing every call it trys to establish a connection?
Usually used with UDP/IP, it is fast, no connections. Good for sending video frames or other binary data (like two player realtime game sync info) with little overhead. As long as you can live with a few dropped frames, and/or add your own recovery on top !!
> 3) if 2 is true, how would I establish a pernament connection to a unit
See the TCP/IP samples, similar to what you describe:
"sceInetBind" to 0.0.0.0, "sceNetInetListen" and "sceNetInetAccept" on the server side.
"sceNetInetConnect" on the client side (or use my helper)
PspPet,
I have one more big question.
How come when I suply a SSID for my router it fails to init the drivers? The connecting screen will show and the "++" will keep going up but then eventualy drop and lock up with only 2 + on the screen. Yet if I dont suply an SSID it will get though the setup fine and get me to the option screen.
How can i go about getting it to work with my router so I can communicate with the psp?
I have one more big question.
How come when I suply a SSID for my router it fails to init the drivers? The connecting screen will show and the "++" will keep going up but then eventualy drop and lock up with only 2 + on the screen. Yet if I dont suply an SSID it will get though the setup fine and get me to the option screen.
How can i go about getting it to work with my router so I can communicate with the psp?
dhcp
Related to dhcp ? The PSP may have some comflicts getting an IP address from the router.
I don't know wifi test .02 but when connection is in state 2 (you said 2+ on screen) the PSP is waiting for an ip address.
Have you tried to use static ip addresses ? Use manual configuration under PSP's network configuration and set up ip's manually.
In fact, i don't know much about your SSID problem. First time i see this kind of problem so...
I don't know wifi test .02 but when connection is in state 2 (you said 2+ on screen) the PSP is waiting for an ip address.
Have you tried to use static ip addresses ? Use manual configuration under PSP's network configuration and set up ip's manually.
In fact, i don't know much about your SSID problem. First time i see this kind of problem so...
Re: dhcp
100% it is a static ip. I entered all the manual settings (including my routers ip). Yet when I have an SSID I get locked at 2+. If I have a blank SSID, I pass throught just fine.pspkrazy wrote:Related to dhcp ? The PSP may have some comflicts getting an IP address from the router.
I don't know wifi test .02 but when connection is in state 2 (you said 2+ on screen) the PSP is waiting for an ip address.
Have you tried to use static ip addresses ? Use manual configuration under PSP's network configuration and set up ip's manually.
In fact, i don't know much about your SSID problem. First time i see this kind of problem so...
the ip address I use works fine on my router when I do a manual test internaly on the psp.
Re: ok
Yep pspftp works like a charm. So I definantly am going to have to step though all your code and try finding the problem child between the two.pspkrazy wrote:Ok then :)
After reading psppet source it seems that 2+ is state 0.
In fact the PSP is idle trying to find the router.
Do you have the same problems with pspftp ?
pspftp's connection loop is different so it may work.
Can u try ?
Thanks.
The short answer: find a configuration that works, and stick with it.
> How come when I suply a SSID for my router it fails to init the drivers?
Not sure what is different for your case.
I specify the SSID (and WEP) and it works like a charm
[without an explicit SSID, I don't know what it will pick]
If you have multiple connections, it may be picking the wrong one.
[The WiFi .02 sample lets you pick connections from the available non-DHCP net configs - the older WiFi .01 sample does not -- like the original 'pspftp']
> How come when I suply a SSID for my router it fails to init the drivers?
Not sure what is different for your case.
I specify the SSID (and WEP) and it works like a charm
[without an explicit SSID, I don't know what it will pick]
If you have multiple connections, it may be picking the wrong one.
[The WiFi .02 sample lets you pick connections from the available non-DHCP net configs - the older WiFi .01 sample does not -- like the original 'pspftp']