An apparatus and a method for updating data in an embedded system are
provided. The apparatus includes a processor for retrieving new data and
a transmission line. The transmission line connects to the processor to
receive the new data and transmits the new data to the embedded system.
The data of a data area has a end address for the data and a plurality of
application programs arranged in order, and the new data includes an
application program update. The embedded system executes the following
steps: searching for an application program corresponding to the
application program update; if the corresponding application program is
found, retrieving a first address and a second address of the
corresponding application program; obtaining a length value of the
corresponding application program from the second address and the end
address; writing contents of the data area from the second address to the
end address into the data area beginning from the first address; adding
the first address to the length value to obtain a third address; and
writing the application program update into the data area beginning from
the third address.