Harald Kipp wrote: Hi Harald: > The flash is used in 16-bit mode, while you are > using 8-bit mode. Also volatile is required at > certain points. Otherwise your code may not work > with compiler optimization. > > This code should work: Now it works! Thank you!