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

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

[avr-gcc-list] Re: Passing a string variable to lcd_puts


From: David Brown
Subject: [avr-gcc-list] Re: Passing a string variable to lcd_puts
Date: Mon, 30 Mar 2009 20:06:38 +0200
User-agent: Thunderbird 2.0.0.21 (Windows/20090302)

David VanHorn wrote:
I was originally declaring my variable passed to lcd_puts as signed char LCD_String[LCD_Line_Len + 1] This, after discovering to my surprise that lcd_puts wants signed chars. Recently, I've converted to the portable typedefs as unit8_t and int8_t Now, whichever of those I use, I get a warning: warning: pointer targets in passing argument 1 of 'lcd_puts' differ in signedness

According to stdint.h, int8_t is supposed to be signed, which I understand to be the same as char. So what am I missing? And as a secondary question, why does lcd_puts want signed data? Seems nonsensical to me..


I know what *I* am missing - the source code! How is anyone supposed to help you with your problem until you post the actual compilable code snippet? We need a compilable code sample which demonstrates the problem, along with the compiler flags you used and also the compiler version you used. Getting a warning for int8_t but not for "signed char" is not expected behaviour, and I think many people (as well as you) would be interested to find out if that is really the case, and if so, if there is some strange compiler issue. But we need the code so that other people can test this.

I had hoped that after being asked so many times to post code snippets in previous threads, that you would have thought of this yourself. I'm happy to spend time helping out (when I have the chance), but I'm not fond of repeating myself.

mvh.,

David





reply via email to

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