brew-framework

Multidimensional array as a flat array problem

爱⌒轻易说出口 提交于 2019-12-24 06:16:10
问题 I'm looking at two lines of code that somebody wrote and there is an exception in the 2nd one, however I don't understand why. char** array = (char**) new char [2] [6]; std_strlprintf(array[0],6,"[%d]", num); std_strlprintf is a Brew function that writes formatted output to a string. (num is an integral value which is 0) Why is there an exception with this code, what's wrong with accessing the first elelment of the array as buff[0]? EDIT: sorry there was a typo in my initial posting. Its

How to detect phone handset brand and model info on Brew?

為{幸葍}努か 提交于 2019-12-12 06:37:11
问题 How do I runtime detect which make and model a phone is, which is running Brew or Brew MP? 回答1: This should work if you have USB logging enabled printdevinfo(s, AEE_DEVICEITEM_MODEL_NAME); printdevinfo(s, AEE_DEVICEITEM_MANUFACTURER_NAME); printdevinfo(s, AEE_DEVICEITEM_FRIENDLY_NAME); and if printdevinfo is defined like this: static void printdevinfo(IShell* s, int id) { AECHAR* pItemBuff; int nItemLen = 0; ISHELL_GetDeviceInfoEx(s, AEE_DEVICEITEM_MANUFACTURER_NAME, NULL, &nItemLen);

Why does not detecting phone make and model work on HTC Smart?

怎甘沉沦 提交于 2019-12-11 20:11:54
问题 I can not seem to detect handset make and model on the Brew MP phone HTC Smart? (Same as Dopod F3188 and HTC F3188.) I am using ISHELL_GetDeviceInfoEx(s, AEE_DEVICEITEM_MANUFACTURER_NAME, NULL, &nItemLen); Only empty strings are returned. What could be the problem? 回答1: This is a problem with the HTC Smart. I used conditional compiling for that handset instead. 来源: https://stackoverflow.com/questions/6760687/why-does-not-detecting-phone-make-and-model-work-on-htc-smart

Disable warnings being treated as errors(cc1.exe)

↘锁芯ラ 提交于 2019-11-29 00:42:45
问题 I am developing a brew app. When compiling the app to get MOD file, I am continuously getting this error cc1.exe: warnings being treated as errors I want to disable this warning. I have googled it, and many says disabling -werror will help but I don't know how to do that. The compiler is CodeSourcery ARM. 回答1: You need to remove -Werror from CFLAGS , CPPFLAGS etc.; these are usually set in Makefile's or build scripts. However, I'd strongly advice to fix the actual warnings instead, which will

How to suppress warnings in external headers in Visual C++

人走茶凉 提交于 2019-11-27 11:25:55
I'm starting a new BREW project, and I'd like to compile with Warning Level 4 (/W4) to keep the application code nice and clean. The problem is that the BREW headers themselves don't compile cleanly with /W4. In gcc you can differentiate between application and system headers by using -I and -isystem, and then by default gcc doesn't report any compilation warnings in system headers. Is there an equivalent mechanism in Visual C++? Only use this method around a block of headers that you cannot change, but that you need to include. You can selectively, and temporarily disable all warnings like

How to suppress warnings in external headers in Visual C++

感情迁移 提交于 2019-11-26 17:59:58
问题 I'm starting a new BREW project, and I'd like to compile with Warning Level 4 (/W4) to keep the application code nice and clean. The problem is that the BREW headers themselves don't compile cleanly with /W4. In gcc you can differentiate between application and system headers by using -I and -isystem, and then by default gcc doesn't report any compilation warnings in system headers. Is there an equivalent mechanism in Visual C++? 回答1: Only use this method around a block of headers that you