OK, I’ll bite… My $0.02.
HTTP is a terribly wordy protocol. It requires substantial (on the AVR scale) computing for processing of requests and constructing replies. You will probably use up a lot of SRAM, data and EEPROM with reply templates. It does offer an advantage in that everything has a web browser, your smart phone, your video game console, etc. so the client side is written for you.
Here is what I have done… I have my AVR with a serial connection to the WiFly. I communicate with the AVR then through a TCP socket based client on my PC. The protocol is a custom packet based protocol that can be easily processed by a small state machine in the AVR. I keep all the individual portions of the packet to 8bit values so I don’t have to worry about endianism. The entire packet works out to be quite small and even at 57600 baud between the AVR and WiFLY, I can send orders of magnitude more packets / second than I could send complete messages with HTTP. For context, I’ve posted my packet.h file below so you can see how the packet, its envelope, etc. is laid out.
So… the TCP socket based client (I call it MCP) which runs on my PC is the actual the workhorse. My PC is fast and strong relative to the AVR so I offload all the algorithm handling to it. In addition, the MCP also has a web server built into it. This way I can interact with the MCP and the entire system via a web browser (pointed at my PC from my PC, e.g. http://localhost:8080). Further, the MCP web server can generate images on the fly to show plots of ADC values over time, or the motor speed / state over time. This is done by using libpng which is really straightforward to use. That kind of thing is going to be much (much) harder (and slower) to do with just the AVR serving out the pages (though maybe HTML5 offers some way, I don’t know).
My hardware actually involves two AVRs connected via SPI, one of which (AVR0 in the code below) has the serial port to the WiFly. Packets that come in from the WiFly can be forwarded to the second AVR (AVR1) and outbound packets from AVR1 are similarly handled to direct them back to the MCP. This is what the envelope source and destination is all about. You can see the packet types can turn on/off LEDs, drive motors, report the ADCs and disable the SPI interface. packet_process is the state machine. Down at the bottom are macros that do the bit handling for the packet header.
#ifndef _PACKET_H_
#define _PACKET_H_
#include "adc.h"
/* packet:
Envelope byte
Bit: Description
7 Destination bit 0 \__ 2 bit address of destination
6 Destination bit 1 /
5 Source bit 0 \__ 2 bit address of packet source
4 Source bit 1 /
3 Type bit 0 \
2 Type bit 1 |__ 4 bit (nibble) packet type
1 Type bit 2 |
0 Type bit 3 /
Data
Length
Type: (byte) Description
LED 1 Value of status LED (off = 'o', green = 'g', red = 'r'), first packet type, primarily for testing
ADC 8 8-bit ADC reading on 8 channels (0-7)
SPI 1 0 = enable (default, never sent), 1 = disable
MOTOR 2 1 byte for direction, 1 byte for speed
*/
/* byte shifts for dest and src to create envelope */
#define DEST_SHIFT 6
#define SRC_SHIFT 4
/* SRC and DEST values */
#define AVR0 1
#define AVR1 2
#define MCP 3
/* nibble value of packet type */
#define PKT_TYPE_LED 1
#define PKT_TYPE_ADC 2
#define PKT_TYPE_MOTOR 3
#define PKT_TYPE_SPI 4
/* length in bytes */
#define PKT_TYPE_LED_LENGTH 1
#define PKT_TYPE_ADC_LENGTH 8
#define PKT_TYPE_SPI_LENGTH 0
#define PKT_TYPE_MOTOR_LENGTH 2
/* packet data constants */
#define PKT_DATA_LED_OFF 1
#define PKT_DATA_LED_GREEN 2
#define PKT_DATA_LED_AMBER 3
typedef struct packet {
uint8_t envelope;
union packet_data {
struct packet_led {
uint8_t state;
} led;
struct packet_adc {
uint8_t ch[ADCS];
} adc;
struct packet_motor {
uint8_t dir;
uint8_t speed;
} motor;
} data;
} pkt_t;
void packet_process(pkt_t *p);
#define PKT_DEST_VAL(seminibble) (seminibble << DEST_SHIFT)
#define PKT_DEST_CLEAR(byte) (byte & ~(3 << DEST_SHIFT))
#define PKT_DEST_SET(byte, seminibble) PKT_DEST_CLEAR(byte) | PKT_DEST_VAL(seminibble)
#define PKT_DEST_GET(byte) (byte >> DEST_SHIFT)
#define PKT_SRC_VAL(seminibble) (seminibble << SRC_SHIFT)
#define PKT_SRC_CLEAR(byte) (byte & ~(3 << SRC_SHIFT))
#define PKT_SRC_SET(byte, seminibble) PKT_SRC_CLEAR(byte) | PKT_SRC_VAL(seminibble)
#define PKT_SRC_GET(byte) ((byte >> SRC_SHIFT) & 3)
#endif /* _PACKET_H_ */
Hope this helps.