Symbian’s context-sensitive help system can be a beast of its own – especially, as its HlpModel panics have not been documented anywhere.
Thanks to the USB stick from the Mobile World Congress, I now present you the official list – taken right from the Symbian Os source code:
// Enums
enum THlpPanic
{
EHlpNoRowAtCursor,
EHlpInvalidView,
EHlpInvalidTDbCol,
EHlpInvalidTDbKeyCol,
EHlpInvalidColName,
EHlpInvalidTableName,
EHlpInvalidComparison,
EHlpInvalidQuery,
EHlpDatabaseInTransaction,
EHlpDatabaseNotInTransaction,
EHlpNoCriterion,
EHlpNoCategoryList,
EHlpNoPictureFactory,
EHlpNoPictureStore,
EHlpNoHelpList,
EHlpNoItem,
EHlpNoTopic,
EHlpNoView,
EHlpAsynchSearchError,
EHlpTopicNoRowsInView,
EHlpFault,
EHlpUnlocatedHelpPicture,
EHlpNotEnoughZoomRatios,
EHlpNoHelpModelPointer,
//
EHlpLast
};
Even though the Hundredth-monkey effect has been proven to be wrong multiple times, followers of Forum Nokia likely thought about it quite a bit recently – tens of developers suddenly wondered how to implement background music loops using MP3 files. I eventually got it up and running – but had to use low-quality WAV files in the process…
The Chinese news service wanwann.com now claims to have created a solution of its own:
…
Well, here provides a solution to you, that you can decode your mp3 to raw music datas, and then mixing then play(by using a single streamming player) these decoded raw datas. However, this solution is an opensource project which is licenced under the GPL licence, please agree to the license before you use the sourcecodes.
…
If you would have asked me about tetaphobia a few weeks ago, I would have flipped you the finger. Carbide 2.4 tought me better, and Mike Trujillo has just replied to my articles.
His reply contains material which I consider of common interest – here goes:
Tam,
Thank for flagging this. Please be sure to log any bugs in Bugzilla and send the bug numbers to me.
Here are known issues that I think are fixed/being fixed.
* Update site – early reports from users who had problems updating from v2.3 to v2.4. I believe this was isolated and now works.
* New WINSCW compiler. For most users this compiler is fine. Some older DLL in AVKON apps don’t work with the old compiler so you need to revert to the old compiler. We don’t think this will affect community users but if it does please log a bug.
* Qt – Qt build and project system is different than Symbian. v2.5 should have some usability improvements with Qt awareness in Carbide. I know that we have problems when the .PRO file is touched.
Version 2.5 is nearly done – you can take a look at:
The first bug most developers will stumble upon is one related to the Qt integration – Forum Nokia claims that it has been improved in Carbide 2.4.
Unfortunately, the improvement means that you must now manage your .pro file by hand. When adding a file to the project, a screen like the one below spells doom. It means that the resource you just added to the project will be ignored by the compiler:
Fortunately, finding a solution is simple. Right-click the .pro file and select Open with -> Text editor. Then look at the structure below to familiarize yourself with how such a file is structured: TEMPLATE = app
TARGET = QtTypeGun
QT += core \
gui
HEADERS += QtStatsCharForm.h \
QtStatsTimeForm.h \
..
QtGameWinnerForm.h
SOURCES += QtStatsCharForm.cpp \
QtNextPlayerForm.cpp \
...
QtGameWinnerForm.cpp
FORMS += QtStatsCharForm.ui \
QtStatsTimeForm.ui \
...
QtNextPlayerForm.ui
RESOURCES += images.qrc
symbian: {
TARGET.UID3 = 0x2002E49F
LIBS += -lcone \
-leikcore \
-lefsrv \
...
-lcentralrepository
myFiles.sources = rsc\*.wav
DEPLOYMENT += myFiles
}
In general, a .pro file is made up of lists which are “connected by /’s at the end of each line – adding an element of your own is simple. When adding a form, keep in mind that you must add all three files: the .h, the .cpp and the .ui!
Even though this is likely to make me the most-hated person in the Nokia world, all developers should read this PSA carefully before updating to Carbide.c++ 2.4.
I have just updated to the product, and have to report that it is extremely unreliable and has loads of errors. I will post more about some of them in the next few hours – in the mean time, PLEASE stick to Carbide.c++ 2.3 and Qt 4.6.1…
When it comes to keeping Carbide updated, some consider it a 24/7 job. Some updates are easy, others are difficult – Carbide 2.4 will be especially difficult.
Mike Trujillo, the product manager, has shared the following instructions:
Make sure that you have Carbide.c++ v2.3 installed. Check Help > About. Go to the Carbide.c++ page for Carbide v2.3.
Carbide.c++ v2.4 does not have a separate installer – users update from inside their Carbide installation.
* Click Help > Check for Updates
o Install all components. Please select the ADT updates when asked.
o You can restart the IDE if you wish
* Click Help > Install New Software
o Select the Carbide Update in the pull down menu
o Select the 2.4 ADT Features
* Restart the IDE
As of now, I didn’t have the time to update – the improvements are said to be non-critical (aka WINSCW compiler patches). But if anyone of you has time, let us know how it went…
Symbian developers know and loathe Carbide – its that Eclipse-based bloatware we all have to use for hours on end in order to create our applications. Carbide’s development always goes along two lines: one stable, and one beta.
AllAboutSymbian now claims the following roadmap for the product:
…
The next version of Carbide.c++ (2.4) is in beta testing and could be released soon. This version will bring support for up to 50 concurrent builds and further improvement to support for Qt applications development. 2.4 will only be available through the p2 update process, so upgrading to 2.3 is a must.
Beyond that there will be a 2.5 release, with further Qt related improvements and support for new ARM RVCT 4.0 compiler, again only available through p2.
By the middle of the year Carbide.c++ will gain a version 3.0 (which should be available as a full installer). This will bring changes to the debugger, more Qt related improvements, tools for capturing or sharing the development environment, and tools to discover SDKs. This version is expected to enter beta testing during March.
…
Even though this has not been confirmed so far, it sounds sensible to me…
Given that Symbian’s AVKON UI system is essentially dead, there is little reason not to start with Qt. OK, the development tools are rudimentary ATM – but Qt really is fun.
Unfortunately, the Carbide error message below is likely to spoil the fun for some of you:
No SDK’s were found that contain Qt support
Most of the times, this error occurs due to stupidity on your part. The QT you need to install is called qt-symbian-opensource-4.6.0.exe – files like the infamous qt-sdk-win-opensource-2009.05.exe distribution lead to the issue above.
if you already have the problem, solving it is easy – kick the old Qt off, reinstall the new one and you are set to go…
Whenever a SDK changes its owner, hilarity ensues. For example, the folks at Access’s never quite managed to sort out the terms Palm OS and Garnet OS in their latest developer tool. The folks at Symbian’s seem to have similar issues with the names Carbide and ADT – but who am I to bicker?
The real reason why I am writing this is different: your Carbide is likely to stop working on the 31st. In order to avoid the issue, you need to update to the version with the miraculously strange splashscreen below:
Step 1 – download ADT
The first step involves signing up at the Symbian Foundation and downloading the ADT. This 300MB download will take some time…
Step 2 – Back up your stuff
…which you will use to load your source code into a CVS. Alternatively, copy the workspace folder onto an USB stick.
Step 3 – Uninstall CARBIDE
The next step involves removing Carbide.c++. Just remove Carbide.c++ – leave compilers, perl, SDKs, etc ALONE!
Step 4 – Install ADT
By now, your file should be downloaded. Just install it.
Step 5 – Start ADT, point it at the old workspace
This is the point where the Eclipse architecture of workspace folders pays out. Just point your ADT at the old workspace of Carbide, and in 99.995% of the time, you will be up and running again.
Step 6 – wait for ADT to ask for a restart
When ADT asks you to restart it, agree – the upgrade should be done.
By the way: except for the weird design, I didn’t note too many changes in the new version. The license manager is gone, compiles are now handled by four threads by default, and a “news reader” pops up when you start ADT fior the first time…
Don’t ask me why, but the folks at Nokia’s have apparently decided to give us a little Christmas gift in the form of the error message pictured below:
According to Luciano Tomulta from Forum Nokia, this is our own stupidity as we forgot to install updates:
There are no Carbide.c++ versions anymore, you must have run into a glitch of Carbide.c++’s licensing engine. Download and install Carbide.c++ 2.3 from http://developer.symbian.org (the product is called ADT 1.4)
I have already tried to take a shortcut by running the Carbide updater, and am sad to report that it doesn’t help one bit. The only way to get up and running again is getting a Symbian ID, downloading the ADT and installing it…
LocaNote is almost done – done except for the boring default S60 application icon which is dog ugly. On most platforms (even on the Palm), changing application icons is easy…not so on S60. Follow the steps below to create good-looking application icons without having to resort to SVG files.
Create the graphics
S60 needs differently-sized icons. Icons tend to be used in the three scenarios outlined below – if you use the icon size next to each picture, you should be safe from distortions:
Icon view – 86×70
List view, small – 39×39
Running app list – 70×50
Furthermore, create 1-bit mask images. This means that everything which is transparent is white, the rest is black.
Create a new MBM file
Once you have all these bitmaps, it’s time to generate a new MBM file. MBM or MIF files are like image archives – in order to create them, open your MMP file in Carbide and navigate to the Sources tab. Then open the bitmap tree and click Add.
Set up the MBM file you would do with any other, and add the three images. When done, your MBM should look somewhat like this:
Add to PKG file
This MBM file must then be deployed to your handset. Edit the .pkg file in the /sis/ solder to add a line simkilar to the bolded one below:
;Files to install
;You should change the source paths to match that of your environment
;
"$(EPOCROOT)Epoc32\release\$(PLATFORM)\$(TARGET)\LocaNote.exe" -"!:\sys\bin\LocaNote.exe"
"$(EPOCROOT)Epoc32\data\z\resource\apps\LocaNote.r01" -"!:\resource\apps\LocaNote.r01"
"$(EPOCROOT)Epoc32\data\z\private\10003a3f\apps\LocaNote_reg.r01" -"!:\private\10003a3f\import\apps\LocaNote_reg.r01"
"$(EPOCROOT)epoc32\data\z\resource\apps\LocaNote_aif.mif" -"!:\resource\apps\LocaNote_aif.mif"
"$(EPOCROOT)epoc32\data\z\resource\apps\LocaNote.mbm" -"!:\resource\apps\LocaNote.mbm"
"$(EPOCROOT)epoc32\data\z\resource\apps\LocaNote_aif.mbm" -"!:\resource\apps\LocaNote_aif.mbm" "$(EPOCROOT)epoc32\data\z\resource\apps\LocaNote_icons.mbm" -"!:\resource\apps\LocaNote_icons.mbm"
"C:\Symbian\Carbide\workspace\LocaNote\help\LocaNoteLiteHelp.hlp" -"!:\resource\help\LocaNoteLiteHelp.hlp"
Reference the MBM file
The final step to icon heaven involves finding the following (bolded) passage in your /data/ files: RESOURCE LOCALISABLE_APP_INFO r_localisable_app_info
{
short_caption = STR_LocaNoteApplication_5;
caption_and_icon = CAPTION_AND_ICON_INFO
{
caption = STR_LocaNoteApplication_4;
number_of_icons = 2;
};
}
and editing it to look like this (just add the bold line, let everything else be):
RESOURCE LOCALISABLE_APP_INFO r_localisable_app_info
{
short_caption = STR_LocaNoteApplication_5;
caption_and_icon = CAPTION_AND_ICON_INFO
{
caption = STR_LocaNoteApplication_4;
number_of_icons = 2; icon_file="\\Resource\\Apps\\LocaNote_icons.mbm";
};
}
In case anybody of you read the relevant passage on the Forum Nokia wiki (which advocates MIF files): forget it. When using bitmaps, you need to reference an MBM file…it works just fine on the emulator and on my XM5800!
Developing for S60 is not exactly easy – there is an awful lot of things you simply have to figure out all by yourself. One of these lovelies involves renaming folders – according to the documentation, it can be accomplished with the following snippet of code:
CFileMan* fileMan = CFileMan::NewL(CCoeEnv::Static()->FsSession());
fileMan->Rename(completePath, newPath);
delete fileMan;
Unfortunately, it is not as easy as it may look – the paths need to match the following scheme 1:1:
completePath: L"C:\\Private\\20022533\\Zeiss"
newPath: L"C:\\Private\\20022533\\Zeiss"
Easy enough if you know how to do it …
P.S: For all who always wonder why the Carbide debugger insists on putting L before almost all strings…it stands for literal!
Just in case anyone of you doesn’t do source control yet: start doing so now. A CVS server literally keeps your ass covered when you try something out and goof up…and can be made up of any machine you happen to have at home. Tamoggemon’s CVS machine is an underclocked ex workstation running NT4 and being stripped of RAM and drives except for one…and has worked flawlessly for a few years now.
Unfortunately, Carbide’s CVS behavior is not too nice: the product insists on adding generated SIS files into the CVS at every commit. This is highly annoying, as SIS files are large and clog up the CVS server significantly…let’s see what we can do to eliminate them.
The first step involves starting a CVS Commit where the SIS files are affected:
Then, right-click your SIS or SISX file and select add to cvsignore:
Carbide will pop a dialog, where you must enter either *.sis or *.sisx:
Then, click OK. The sis or sisx file will disappear from the list, and will be replaced by a .cvsignore file in the first commit.
From now on, this workstation won’t bug your CVS anymore…which means that your 4GB disk will last about as long as it would have for a Palm OS developer .
Users of Carbide’s user interface designer probably know about the – um – lackluster quality of this particular Nokia product. Nevertheless, a group of people have contributed bug reports and feature requests to the Carbide team…which have now led to a new release.
The update can be installed via Carbide.c++’s integrated updating tool (Help -> Software Updates -> Find and Install). I have attempted to install it on my Wind with in and succeeded…but had to wait over half an hour as dependencies were checked at minimal CPU load.
Cutting a long story short: don’t do this if you are in a hurry…but do hit that update button before you go and check your email…
P.S. The image on the left is from an iGoogle plug-in called Carbide Update Manager. Click this link to use it…
I have recently asked myself where the Symbian OS emulator actually places its files – and how to access them in order to analyze them for debugging purposes. A bit of system searching solved the problem – they can be found here: C:\S60\devices\S60_5th_Edition_SDK_v0.9\epoc32\winscw\
Just go to SDK folder, hit the epoc32 folder, click winscw and off you go!