Hi all!
Fast question regarding the WiFly RN-171 solution.
Firstly, I have it working…I can create an Adhoc network, telnet to just fine etc…see data etc.
This is what I REALLY want to do.
#1. Create a server on the RN-171; in other words, people would connect to this network (be it adhoc or AP based)
#2. The client end would go to a specific port (ie. 80) where they would send a “stream” of data (from a browser it would be HTTP data)
#3. My micro connected to the RN-171, would receive the data, parse and process it, and then send back a formatted HTML stream so the data can be rendered on the browser.
#4. I (the backend micro) need to process the data, and I just need the WiFly to be a “socket” ↔ Serial proxy.
Can you recommend the best way to config this?
Also, can people use the serial at 38400 baud? For some reason, I cannot…9600 works just fine…and yes, I did update the new baud rate to the RN-171…
Thoughts?
~Kam
Hey all,
Okay, I’ve made some progress, and also found(?) and error with CCS regarding structures…does not work with struct, but SAME elements outside of struct work…strange…
But, okay, I can have a browser connect to my wiFly, and issue “commands” and I can send back data to the browser that shows up as pure unprocossed html!
So instead of showing “Hello World”, it shows the complete HTML “stream”
Here is the EXACT string I am sending back…
const char html = “Status: HTTP/1.1 200 OK \n\rContent-Type: text/html; charset=utf-8\n\rConnection: close\n\rHello World!\n\r”;
In other words, want the browser to render “Hello World!” and not the HTML string/stream…
Thoughts?
~Kam
i believe that there is a setting in command mode that automaticallyappends html headers. check it out in the documentation! wondering if adding an encode type will help (utf8) etc.
The documentation is not really clear about this…there is a setting to make the unit automagically send data WITHOUT a micro…I need the micro to control it 100%…