User`s manual

230 digi.com Keywords
#zimport
Syntax: #zimportfilenamesymbol
This compiler directive extends the functionality of #ximport to include file compression by an external
utility. filename is the input file (and must be relative to the Dynamic C installation directory or be a fully
qualified path) and symbol represents the 20-bit physical address of the downloaded file.
The external utility supplied with Dynamic C is zcompress.exe. It outputs the compressed file to the
same directory as the input file, appending the extension .DCZ. E.g., if the input file is named
test.txt, the output file will be named test.txt.dcz. The first 32 bits of the output file contains
the length (in bytes) of the file, followed by its binary contents. The most significant bit of the length is set
to one to indicate that the file is compressed.
The sample program zimport.c illustrates the use of this compiler directive. Please see Appendix C.2.2
for further information regarding file compression and decompression.