avr-gcc-list
[Top][All Lists]
Advanced

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

RE: [avr-gcc-list] PSTR in a struct


From: Ron Kreymborg
Subject: RE: [avr-gcc-list] PSTR in a struct
Date: Mon, 16 Sep 2002 21:13:50 +1000

The Mitsubishi M16 C compiler has a nice solution for constants in flash: if
you flag a constant with the C keyword "const", it gets put in flash. No
special keywords or macros, just standard C.

Ron

-----Original Message-----
From: address@hidden [mailto:address@hidden
Behalf Of Tom Harris
Sent: Monday, 16 September 2002 8:14 AM
To: address@hidden
Subject: [avr-gcc-list] PSTR in a struct


Greetings

I want to do something like this, but of course it won't work with PSTR. Can
anyone give me a pointer? I would really like to learn how to place any data
structure in program memory, out of precious RAM.

char*[] = {PSTR("Foo"), PSTR("Bar"), }

Tom Harris, Software Engineer
Optiscan Imaging, 15-17 Normanby Rd, Notting Hill, Melbourne, Vic 3168,
Australia
email address@hidden     ph +61 3 9538 3333  fax +61 3 9562 7742

This email may contain confidential information. If you have received this
email in error, please delete it immediately,and inform us of the mistake by
return email. Any form of reproduction, or further dissemination of this
email is strictly prohibited. Also, please note that opinions expressed in
this email are those of the author, and are not necessarily those of
Optiscan Pty Ltd.

avr-gcc-list at http://avr1.org

avr-gcc-list at http://avr1.org



reply via email to

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