Developing in OPL for the Nokia 92x0 can be done in two different ways:
- Firstly using the PC based SDK (software development kit), with an extra OPL Devkit installed in addition to the C++ / Java SDK. This method uses the 92x0 emulator. Code is written within the OPL program in the emulator and programs can be translated and tested in the emulator. This method is entirely PC based.
- Secondly using either a Nokia 9210, 9290 or 9210i device itself. In this case the OPL editor and OPL runtime must be installed on to the phone. Programs are written in the editor on the phone, translated via the editor in the phone and can be run on the phone using the OPL runtime.
This tutorial guides you through firstly PC based development (obtaining and installing the SDK and configuring it for OPL development use) and Device based development (installing the OPL editor and runtime). It is recommended that you have both option available when developing as both have their own advantages and disadvantages:
|Device based||Feeling for how program will work on actual target device, mobile development solution (program on the way to work)||Small keyboard means inputting lots of code can be tricky, smaller screen is harder on the eyes.|
|PC based||Large keyboard and screen allow for easy inputting of code and is easier on the eyes. Emulator (depending on speed of computer) is often faster than 92x0.||Not as mobile as the 92x0, not the actual device so difficult to get a feel for how things will actually work. The computer which the emulator is installed on must be sufficiently powerful to run the emulator (Pentium 200 64MB Ram minimum). Emulator is a Windows only program (despite being intended for NT it will generally run on any Windows Installation of 96 and above).|
Obtaining the SDK and Devkit
The Nokia 9200 SDK can be obtained from Forum Nokia. You must be a member of Forum Nokia in order to obtain the SDK. Joining Forum Nokia is free (some personal information is collected), and is worthwhile as it give you access to documentation and other useful tools for all Nokia Symbian devices.
The SDK can be ordered on a CD (allow upto 3 weeks for it to arrive), or it is available as a download within the Symbian section. The download is large and is therefore recommended only for people who have a fast internet connection. This SDK is for C++ and Java development. In order to use it for OPL development and OPL Devkit must be obtained.
The OPL Devkit contains the files necessary to add OPL to the C++/Java SDK and the files to allow for OPL development on the Nokia 92x0. The OPL Devkit is available from the Developer section of the Symbian website. There is a download for both the OPL runtime and the OPL Devkit. The second of these is for developers, but the first will be needed by users to run your OPL program on their machine. In addition Symbian have also made available on this page some updated OPX's, it is recommended you also download this file.
It should be noted that Symbian expressly warn you that installation is at your own risk and that OPL is unsupported (but we're here to help!). However there have been no reported problems from anyone installing the SDKs. You should download the SDK from the page above as it allows Symbian to track interest in OPL development.
Installing the SDK and Devkit on a PC
Full documentation comes with the Nokia C++/ Java SDK including installation instructions. You should follow these. In summary it as simple as installing any other program. (To install run setup.exe). After installation you will have a working Nokia 92x0 Emulator. In order to use this emulator for OPL development the OPL Devkit must be installed.
Once you have downloaded the ZIP file containing the OPL Devkit you should unzip it and read the readme.txt file. This contains instructions for installing the OPL Devkit. They may look long and complicated, but they are in fact very clear. Following the instructions takes around 10 minutes and adds the OPL runtime and OPL Editor to the Emulator.
It will also add the DemoOPL Program which is a Symbian version of the FreEPOC Event Core (although more complex and less easy to understand). DemoOPL is written in OPL and as can be seen from the screenshot below it demonstrates that OPL programs look and feel like the inbuilt applications and can used to create both complex and useful programs.
The OPL Devkit Zip file also contains some useful documents such as the OPL Porting Guide and OPL Documentation. The OPL Devkit ZIP file contains another ZIP file which contains documentation on OPL from Epoc Release 5 (the previous OPL release to that for the Nokia 92x0) and is very useful in understanding OPL as changes between the two versions are relatively minor.
Installing the Devkit on the 92x0 device
To be able to develop OPL on the Nokia 92x0 device both the OPL runtime and the OPL Editor and associated files must be installed. The instructions for doing this are in the same readme.txt file referenced above. If you have installed a previous version of the OPL runtime please pay careful attention to the note in the readme.txt file (just above the installation instruction for OPL on the 92x0 device) otherwise the OPL Devkit may not work.
One stage that may not be clear is the following: 'Install any of the OPX files in \Binaries\SIS Files\Target\OPX\ which you require'. OPX files are extension of the OPL language. It is recommended that you install all such files available (including the ones available in the updated ZIP file available from the Symbian site).
Once you have successfully installed the files you should be able see the OPL Editor (called Program) which will enable you to write and translate files on the 92x0 itself.
So now you are all set to get going? If you need more help you can follow Ewan's OPL tutorials which will take you though every step of learning about OPL and teach you how to use the OPL Event Core to write your own program...