Re: .vmc file Kategorie: Verschiedenes (von André H. - 7.09.2012 10:21) | ||
Als Antwort auf .vmc file von Philippe - 5.09.2012 18:10 | ||
| ||
Hallo Philippe, > One of my customers have a CC2 unit built by a sub-contractor. > They have *only* some kind of backup in the form of a .vmc file. > What can we do with only this file? > I guess that we cannot "disassemble" this file to retreive the source code? the vmc-file contains no source code. This file contains VM-Tokens (like assembler). You can download the file to the CC2 using the CC2Net.de-Download-Tool. It is possible to decompile a vmc, but there is no special software. This must be done by hand. All VM-Codes are listed in the module vmcode.c2. You must also know all four types of VM-Codes. (see manual) VM-Codes can be 16 or 32 Bit. (one or two words in vmc-file) The vmc-file contains a header and two sections. Header: first line: "CC2VMC" second line: count VM-Constants in bytes third: count VM-Code in words Sections: First: constants as byte-values They are used for constants greater 16Bit, constant arrays, strings and thread-definition. Second: VM-Code as word-values But with decompiling a vmc-file you won't get the source code. You would only get a kind of pseudo-source looking like Assembler. e.g. "load byte addr 65 to stack", "load int addr 20 to stack", "add last two values in stack as int and store the result to stack", "store last int of stack to int addr 20" In C2 it could look like that: x=y+x; Regards, André Antworten bitte nur ins Forum! Fragen per EMail auf Forum-Postings werden nicht beantwortet! Das macht meine Heizung gerade | ||
Antwort schreiben Antworten: Re: .vmc file (von Philippe - 7.09.2012 19:00) |