From: Spehro Pefhany
Subject: Re: To C or not to C
References: <email@example.com> <firstname.lastname@example.org> <email@example.com> <firstname.lastname@example.org> <email@example.com> <firstname.lastname@example.org>
X-Newsreader: Forte Agent 1.92/32.572
Date: Mon, 06 Jan 2003 19:11:10 GMT
NNTP-Posting-Date: Mon, 06 Jan 2003 14:11:10 EST
On Mon, 6 Jan 2003 19:38:55 +0100, the renowned "Frank Bemelman"
>But perhaps his compiler was buggy and didn't know how to increment
>pointers to CODE space. I can vagely recall myself messing around with
>indexing arrays and not using pointers, when trying to do something
>in CODE space. CODE and RAM are physically seperated, in case of 8051.
Yes, well, one might wonder aloud why he isn't just using the library
strcpy(char *dest, char *src) .. doesn't it work with code memory?
A proper compiler should not have a problem with that, and it also
should take advantage of the dual DPTRs that are present in many
8051s these days, even cheap ones.
Anyway, your one-liner is the right way, strcpy just returns
dest (for some reason), which makes for a tiny bit more overhead.
"it's the network..." "The Journey is the reward"
email@example.com Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog Info for designers: http://www.speff.com