[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?
From: |
Richard Urwin |
Subject: |
Re: [avr-gcc-list] Initilizing complex const arrays : syntax ? |
Date: |
Mon, 19 Sep 2005 00:33:09 +0100 |
User-agent: |
KMail/1.7.2 |
On Sunday 18 Sep 2005 23:33, Vincent Trouilliez wrote:
> If I may ask one more question before, I happen to have a problem
> define one of the units : " °C".
>
> This '°' degree sign is not ASCII but extended ASCII, and my LCD
> module has a japanese (!) page code for extended characters.
> So I need to squeeze a numerical value within my string definition,
> but I really can't manage to do it, and the string part of struct
> which itself is part of an array, can't help :-/
>
> So, I tried :
>
> const struct param __ATTR_PROGMEM__ param_list[] = {
> { ... , {0xDF, "C "}, ... },
> ...
> };
>
> but the compiler promptly insulted me !! ;o)
0xDF is not a string, it's a number.
Try
{ ... , {"\xDF" "C "}, ... },
I used two concatonated strings because otherwise the C will be taken as
part of the hex sequence.
--
Richard Urwin
- Re: [avr-gcc-list] OT Generic C question, (continued)
- Re: [avr-gcc-list] OT Generic C question, Anton Erasmus, 2005/09/20
- Re: [avr-gcc-list] OT Generic C question, Nils Springob, 2005/09/20
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, David Kelly, 2005/09/19
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/19
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, David Kelly, 2005/09/19
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/19
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/19
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/20
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, David Kelly, 2005/09/20
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/20
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?,
Richard Urwin <=
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/18
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Christopher G. Morlier, 2005/09/18
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/18
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, David Kelly, 2005/09/18
- Re: [avr-gcc-list] Initilizing complex const arrays : syntax ?, Vincent Trouilliez, 2005/09/18