iPhone/iPod receive messages from C# tcpip server using CocoaAsyncSocket
- by SorinA.
Hello,
i'm trying to send/receive data over wifi to an iphone/ipodtouch app from a C# tcpip server. for this i used cocoaAsyncSocket from the google project. If i push a button and i send a request from ipod to server it returns the requested data(song title for example)..i want to know every second what song is playng...so from C# server i send at intervals of 1 second messages to my app. In my app in an timer with the interval of 1 second i call the asyncSocket read readDataWithTimeout method. My problem is that after 8-9 seconds that method is not called anymore. The connection to the server is still active and the C# server still sends data..
what i want to do is the following thing:
- winamp plays a song
- C# server asks winamp what songs is he playing and sends the song title to my app.
- iphone app receives the data and displays it
i don't know why the readDataWithTimeout method is not called anymore after a short period of time..Maybe because the short time between messages sent by the C# server?
Thank you,
Sorin