Thanks, Jack. What are the issues? Does the code fail?
The code doesn't fail, but I have not been able to achieve the reliability that I would like in posting data to sites like Cosm and Thingspeak, meaning that sometimes the data just doesn't get there. My main application is logging data from wireless (XBee-based) sensor networks to these web sites. For instance, one network I have has five sensor units, each transmitting five or six data points once per minute. Each unit has its own time slot to transmit, and these are spaced five seconds apart. These all funnel to a central unit with the Ethernet interface.
The code does the usual thing, posts the data, waits for the server to respond and disconnect, then it disconnects. Sometimes the response doesn't arrive or the server doesn't disconnect before the next sensor's data arrives. Some amount of this is understandable due to network or server delays. If this happens, the code will disconnect, i.e. client.stop(), reset the WizNet module, and carry on. Sometimes the data gets posted on the web site OK even though a response didn't arrive (or didn't arrive quickly). I assume that could be network delays, etc. But sometimes it just doesn't get posted.
Initially I thought I had a reasonable aggregate data rate, but maybe not, maybe I'm pushing it too hard. I didn't want to get into queueing data, not enough memory for much of that, and while I fully expect that I may lose the occasional post with this approach, it's a matter of degree, I just haven't been able to get to the level of reliability that I'd like.
Sorry for the long story, don't expect you to debug my code necessarily, but if you have ideas I'd be glad to hear them too. I'll have a look at the code in the playground and see what I can learn from it. I very much appreciate your efforts for the community!