Networking question
Networking question
I've got two PSPs connected to a wireless router and I'm trying to send a UDP packet from one to the other. They're both connected, I've got the IP addresses, but when I send a packet from one PSP, it never reaches the second. Instead the router responds with an ICMP Type 3 Code 3 packet and I get a "Host is down" error on the sending PSP. Has anyone run into this before?
Yes, I'm using the MAC filters, but as I said, they're both connected. I couldn't get them to connect until they were in the Mac filter list. When you create an access point, you're given the opportunity to test the connection. I'd hope that people did. :)varmint wrote:Only thing I can think of is maybe your router has MAC filters setup? I send UDP & TCP packets between PSP's on our wireless all the time with out problems.
Until the PSP is in the MAC filter list, the test fails immediately. Oh, I have the filter set for excluding connections not in the list. The list has only the two PSPs in it. Both PSPs can reach Google (for example), but not each other.
Well, I learned a valuable lesson and thought I'd share it in case someone else has the same trouble some day. My network code was fine. No problems at all. The reason neither PSP responded to the other (or to the computer) was that I forgot the PSP uses COOPERATIVE MULTITASKING and the network libs use threads to handle the ARP packets to resolve addresses. If you don't call a function that allows tasks to switch, your PSP will not respond to ARP packets and thus appears unreachable. My packets were set for non-blocking, and the program looped around waiting/sending packets. All I had to do to get it to work was stick an sceKernelDelayThread(10); in front of the packet function and everything was peachy.
If it could help, I've set up and run under 3.xx both on Fat and S&L the follwing tests using WiFi between 2 PSPs:
- Adhoc Client-Server connection
- Via Access Point Static IP Address Client-Server connection
- Via Access Point Static IP Address FTP Client-Server connection
- Via Access point with Dynamic IP Address connection (mandatory) WebGet
- Via Access point with Dynamic IP Address connection (mandatory) HTTP client
- Via Access point with Dynamic IP Address connection (mandatory) Resolver
- With Adhoc connection: Sort of walkie-talkie for audio with both socom microphone or gocam microphone : spoken audio input is transmitted from one PSP to another, two-ways, once per time
- With Adhoc connection: Video frame 160x120 pixels transfer from a Server PSP to a Client
Next steps:
- Audio buffers and Video frames transmitted between PSPs using Access Point
[Speech Recognition using PocketSphinx]
Here "proof of concept": http://www.psp-ita.com/?module=fileview&file_id=690
Source code available if specifically requested.
- Adhoc Client-Server connection
- Via Access Point Static IP Address Client-Server connection
- Via Access Point Static IP Address FTP Client-Server connection
- Via Access point with Dynamic IP Address connection (mandatory) WebGet
- Via Access point with Dynamic IP Address connection (mandatory) HTTP client
- Via Access point with Dynamic IP Address connection (mandatory) Resolver
- With Adhoc connection: Sort of walkie-talkie for audio with both socom microphone or gocam microphone : spoken audio input is transmitted from one PSP to another, two-ways, once per time
- With Adhoc connection: Video frame 160x120 pixels transfer from a Server PSP to a Client
Next steps:
- Audio buffers and Video frames transmitted between PSPs using Access Point
[Speech Recognition using PocketSphinx]
Here "proof of concept": http://www.psp-ita.com/?module=fileview&file_id=690
Source code available if specifically requested.
I wouldn't mind seeing the ad-hoc code. What's out there right now tends to be rather messy. :)mypspdev wrote:If it could help, I've set up and run under 3.xx both on Fat and S&L the follwing tests using WiFi between 2 PSPs:
- Adhoc Client-Server connection
- Via Access Point Static IP Address Client-Server connection
- Via Access Point Static IP Address FTP Client-Server connection
- Via Access point with Dynamic IP Address connection (mandatory) WebGet
- Via Access point with Dynamic IP Address connection (mandatory) HTTP client
- Via Access point with Dynamic IP Address connection (mandatory) Resolver
- With Adhoc connection: Sort of walkie-talkie for audio with both socom microphone or gocam microphone : spoken audio input is transmitted from one PSP to another, two-ways, once per time
- With Adhoc connection: Video frame 160x120 pixels transfer from a Server PSP to a Client
Next steps:
- Audio buffers and Video frames transmitted between PSPs using Access Point
[Speech Recognition using PocketSphinx]
Here "proof of concept": http://www.psp-ita.com/?module=fileview&file_id=690
Source code available if specifically requested.
Sorry for boring you with such a mess...
Up to me this sequence of tests is my own substitute under 3.xx for fat and slim of the "/pspdev/psp/sdk/samples" contents.
On network I had initially some issues related to acptl, dhcp, static/dynamic ip, transmitted/received streams, resolvers, that I solved step by step and now I have the final way all they work properly.
Sorry, for what doesn't help.
Up to me this sequence of tests is my own substitute under 3.xx for fat and slim of the "/pspdev/psp/sdk/samples" contents.
On network I had initially some issues related to acptl, dhcp, static/dynamic ip, transmitted/received streams, resolvers, that I solved step by step and now I have the final way all they work properly.
Sorry, for what doesn't help.