The invention discloses an implementation method and
system of an embedded C
compiler. The method comprises the following steps: A: creating an
interpreted language script, and compiling a C language
source code compiled on a PC (
Personal Computer) side by a user into a target code of an appointed executive address; B: writing the target code into the appointed compiling address of an embedded lower computer; C: creating a file
protection mechanism by the lower computer, and then, executing the target code; and D: after the lower computer finishes executing the target code,
jumping to a file protection position, carrying out field
recovery, and continuously executing other codes of the lower computer. The
system comprises the PC side and an upper computer. The compiled code of a
client is converted into a target language, i.e., a
machine code which can be identified by an industrial controller. Meanwhile, execution efficiency is quick, the research and development convenience of the user in the field of configuration
software is greatly improved, and the implementation method and
system has good economic and social benefit. The implementation method and system of the embedded C
compiler can be widely applied to the field of the configuration
software.