Improvement on ROM of goahead 2.5 webpage
Goahead is the preferred tool for Embedded Web Server design. It converts HTML files and their resources *. the function of compiling C files into the final execution file provides a perfect solution for Embedded projects without a file system. The conversion principle is to convert files into several arrays in byte format, when a page request is sent, goahead returns the array content to the user so that no external file dependency is required. However, an issue in conversion is that HTML files are text files, there may be a lot of redundant data. After conversion, numerous useless data will be added to the Rom, which makes it difficult to reduce the size of the compiled Rom, this poses great challenges to some embedded systems with high resource requirements,
In the actualCodeIt is not difficult to find out that this problem can be solved by storing HTML compressed data *. the C file is resolved, and the data is decompressed using the decompression interface during page requests. Because the page data is usually small and memory exists, the reading speed is not affected, zlib is a simple compression module, which is suitable for use here.
Since we are using the Vxworks system, the current version has only tested Win32 and VxWorks, and there is no time for other tests.
Win32 Web server project: Webs-2-5 \ win
Win32 Web Conversion Tool project: Webs-2-5 \ win \ webutil
VxWorks project: Project
Code download: https://sourceforge.net/projects/goaheadz/