diff -r ad71cf47d037 -r 3031cd3ebd1e SoundGraphAccess.cpp --- a/SoundGraphAccess.cpp Sat Apr 13 00:45:13 2013 +0200 +++ b/SoundGraphAccess.cpp Sun Apr 14 22:40:46 2013 +0200 @@ -193,12 +193,23 @@ //Convert first line OutputDebugStringA(gTextFirstLine); - int convertedChars = MultiByteToWideChar(CP_UTF8, 0, gTextFirstLine, -1, gTextFirstLine16, sizeof(gTextFirstLine16)); - OutputDebugString(gTextFirstLine16); + //int convertedChars = MultiByteToWideChar(CP_UTF8, 0, gTextFirstLine, -1, gTextFirstLine16, sizeof(gTextFirstLine16)); + for (int i=0;i<=strlen(gTextFirstLine);i++) + { + unsigned char myChar=(unsigned char)gTextFirstLine[i]; + gTextFirstLine16[i]=myChar; + } + OutputDebugStringW(gTextFirstLine16); //Convert second line OutputDebugStringA(gTextSecondLine); - convertedChars = MultiByteToWideChar(CP_UTF8, 0, gTextSecondLine, -1, gTextSecondLine16, sizeof(gTextSecondLine16)); - OutputDebugString(gTextSecondLine16); + //convertedChars = MultiByteToWideChar(CP_UTF8, 0, gTextSecondLine, -1, gTextSecondLine16, sizeof(gTextSecondLine16)); + for (int i=0;i<=strlen(gTextSecondLine);i++) + { + unsigned char myChar=(unsigned char)gTextSecondLine[i]; + gTextSecondLine16[i]=myChar; + } + + OutputDebugStringW(gTextSecondLine16); //IMON API call need to be done from window thread for some reason SendMessageToServer(KRspPending); @@ -555,7 +566,11 @@ break; // case WM_IMON_DISPLAY_SET_VFD_TEXT: +#ifdef _UNICODE if (DSP_SUCCEEDED==IMON_Display_SetVfdText(gTextFirstLine16,gTextSecondLine16)) +#else + if (DSP_SUCCEEDED==IMON_Display_SetVfdText(gTextFirstLine,gTextSecondLine)) +#endif { SendMessageToServer(KRspDone); }