Personal tools
You are here: Home Forums R8C/Tiny Special characters (like ä ö ü )

Special characters (like ä ö ü )

Up to R8C/Tiny

Special characters (like ä ö ü )

Posted by RicoB at August 12. 2008

I try to use special characters in strings. I found that I have to replace it with code.

When I try to use it for example in a char array

unsigned char test[] = "This is a \x81 ";

So  I expect test[5] to be 0x81, but it changes to 2 Byte code???

Very strange.

Re: Special characters (like ä ö ü )

Posted by RicoB at August 12. 2008

I found a solution/workarround: It seems hex-Code in a string don't work (compiler fault?) but octed code \201 works...

Re: Special characters (like ä ö ü )

Posted by FrankL at August 12. 2008

Go to Tools > Administration, select your compiler in Toolchains and click on Properties. On the Environment tab you will see the variables NCKIN and NCKOUT. By default these are set to "SJIS". If you change the value to "EUC" for both, the special characters are coded aqccording to ISO8859-1 and should work.

Re: Special characters (like ä ö ü )

Posted by RicoB at August 12. 2008

OK, is there a way to use codepage 437. I still have an old charset in codepage 437.

Re: Special characters (like ä ö ü )

Posted by FrankL at August 13. 2008

Not that I know of. I only know the settings with SJIS and EUC.

Powered by Ploneboard