The -mserial=options
option allows a hexadecimal
code to be stored at a particular address in program memory. A typical task for this option
might be to position a serial number in program memory.
The byte-width of data to store is determined by the byte-width of the
hexcode parameter in the option. For example, to store a one-byte value, 0, at program
memory address 1000h, use -mserial=00@1000
. To store the same value as a
four byte quantity use -mserial=00000000@1000
.
This option is functionally identical to Hexmate's
-serial
option. For more detailed information and advanced controls
that can be used with this option (refer to Serial).
The driver will also define a label at the location where the value was stored and can be
referenced from C code as _serial0
. To enable access to this symbol,
remember to declare it, for example:
extern const int _serial0;