Thanks Phillipp and Royce. Your suggestion
            const char * const cmds[] = { Thw_cmd, Cnts_cmd, NULL };
solved the problem. Both the strings and the array of pointers to them are in code space now. Still being fairly new to sdcc had not spotted section 3.4.1.8 in the docs. I am curious about one thing though, are const and __code synonymous or is there some slight difference between them - eg could const be applied to __xdata as off chip "RAM" could be implimented with flash or eprom? (or even data/near to indicate once initialised never changed)

Thanks for the help,
Regards,
John


Royce Pereira wrote:
Hi John
On Wed, 08 Nov 2006 01:03:30 +0530, John Pote <johnpote@jptechnical.co.uk> wrote:

  
Is it possible to have the compiler place the cmds[] array in code space
as well? That being so how could I declare a function so it would take a
pointer so such a const array of pointers to const strings?
    

Have you read the SDCC user manual? This stuff (and other queries you might want to post)is exhaustively discussed.
Particularly in section "3.4.1.8 Pointers to MCS51/DS390 specific memory spaces"

Regards,
--Royce