[avr-gcc-list] memcpy_P on XMega

2010-06-01 Thread Johannes Bauer
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi there,

I've had some trouble today with the XMega. I used memcpy_P, which
usually worked just fine, except for a certain part of my code where it
suddenly produced garbled output. Tracing the source of the problem I
noticed that on the ATxmega I use the NVM.CMD register and set it to
reading the calibration row (0x02). However, since I did not return it
to NOP (0x00), subsequent calls to memcpy_P lead to a wrong result,
since the behaviour of lpm has changed with a changed NVM.CMD.

I suggest on the XMega to set NVM.CMD to zero in the beginning of memcpy
or include this in the docs, as it might cost someone else roughly a day
in debugging time :-/

Regards,
Johannes
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkwFEwQACgkQN7zEVXrmOiMAUQCgo9AAC2NdXAqRFYmWVDR/Ee6C
omYAoI7mfEMejlTDijHHkLAwDAMZZYH4
=vPjS
-END PGP SIGNATURE-

___
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-gcc-list


Re: [avr-gcc-list] memcpy_P on XMega

2010-06-01 Thread Joerg Wunsch
Johannes Bauer jb@gmx.de wrote:

 I suggest on the XMega to set NVM.CMD to zero in the beginning of memcpy
 or include this in the docs, as it might cost someone else roughly a day
 in debugging time :-/

Please submit an avr-libc bug report.
-- 
cheers, Jorg   .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)

___
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-gcc-list