[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[avr-gcc-list] memcpy_P on XMega
From: |
Johannes Bauer |
Subject: |
[avr-gcc-list] memcpy_P on XMega |
Date: |
Tue, 01 Jun 2010 16:02:44 +0200 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100423 Thunderbird/3.0.4 |
-----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] memcpy_P on XMega,
Johannes Bauer <=