Difference between revisions of "Genfile"
From DIDEAS Wiki
m |
m |
||
(2 intermediate revisions by the same user not shown) | |||
Line 9: | Line 9: | ||
examples: | examples: | ||
− | genfile outfile.txt 10 0x41 - create a 10 byte file | + | genfile outfile.txt 10 0x41 - create a 10 byte file containing the letter 'A' (65) |
− | genfile outfile.bin 10k 255 - create a 10k file with | + | genfile outfile.bin 10k 255 - create a 10k file with containing value 255 |
− | genfile outfile.bin 4C 255 2k - create a file 8k in size(4 clusters each which are 2k) | + | genfile outfile.bin 4C 255 2k - create a file 8k in size(4 clusters each which are 2k) containing the value 255 |
+ | |||
+ | genfile c:\temp\outfile.bin $100C 255 2k - create an 8meg file in c:\temp | ||
+ | |||
+ | [http://www.dideas.com/docs/datalogger/ Visual Studio project and source code] |
Latest revision as of 11:51, 22 August 2005
genfile : create a file with single value
- Usage : genfile [output file name] [size bytes in hex] [value in hex] <cluster size>
- All numbers may be expressed in decimal or hex. Hex is preceded with $ or 0x
- bytes may be followed by the power of 2 modifiers (K, M, G), or C to multiply by the cluster size (default = 512)
examples:
genfile outfile.txt 10 0x41 - create a 10 byte file containing the letter 'A' (65)
genfile outfile.bin 10k 255 - create a 10k file with containing value 255
genfile outfile.bin 4C 255 2k - create a file 8k in size(4 clusters each which are 2k) containing the value 255
genfile c:\temp\outfile.bin $100C 255 2k - create an 8meg file in c:\temp