January
2006, Issue 186
Portable
Web Server
Renesas
M16C Design Contest 2005 Entry
ADDITIONAL
WORK
My
design has some limitations that I’ll probably address
in a future revision. The first limitation is the relatively
inefficient implementation of packet buffering, which
results in a larger than necessary RAM requirement for
a relatively small number of socket handlers. A better
approach would be to recycle the buffers from a centrally
managed pool. This is similar to the socket memory concept
used for the networking system on Linux. The improved
RAM usage efficiency would increase the number of simultaneous
socket connections. Therefore, I’d see an increase in
the maximum number of users before receiving a “server
busy” message.
Substituting
the carrier detect (CD) input with a clear-to-send (CTS)
signal from the modem would also enable the module to
make better use of the buffers contained in the modem.
It would reduce the size of the local transmit stream
buffer. Removing the carrier detect signal would require
the software to be changed so that it monitors the modem
connection using something else, such as a keep-alive
ping.
Additionally,
the FAT file system interface on the module doesn’t
support long file names. This results in the need to
truncate the web site page file names to the shortened
(and ancient) 8.3 convention. Incorporating these missing
features, perhaps together with Wi-Fi capability, would
make for an even more useful, cool gadget.