[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Does anybody have a variant of memcpy that uses ELPM?

From: Eric Weddington
Subject: Re: [avr-gcc-list] Does anybody have a variant of memcpy that uses ELPM?
Date: Thu, 19 Jan 2006 11:10:46 -0700
User-agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)

Dave Hylands wrote:

I'm using the avr-gcc from WinAVR.

Before I go off and reinvent the wheel, I figured I'd ask if anybody
has a variant of memcpy which uses the ELPM instruction (as I
understand it, memcpy_P uses LPM which doesn't work for me).

I'd also like to find a way of getting the long address of a symbol
located in "high" flash (i.e. above the 64K mark - on an ATMega128).


    uint32_t addr = (uint32_t)&flashVar;

seems to give a sign-extended version of the lower 15 bits of the
address. This works for the upper and lower 32K on the ATMega128, but
not for stuff in the middle.

Hi Dave,

I'm sorry, no I don't have one. It shouldn't be too hard to grab a copy of the source from avr-libc and modify it to suit your needs.

But now that I'm thinking of it. Would you be willing to submit a new Task Tracker in the avr-libc project about this?:
This is a good idea to have in avr-libc and I don't want the issue to get lost.

Eric Weddington

reply via email to

[Prev in Thread] Current Thread [Next in Thread]