quick_recipes (Symbian Books), страница 4

PDF-файл quick_recipes (Symbian Books), страница 4 Основы автоматизированного проектирования (ОАП) (17703): Книга - 3 семестрquick_recipes (Symbian Books) - PDF, страница 4 (17703) - СтудИзба2018-01-10СтудИзба

Описание файла

Файл "quick_recipes" внутри архива находится в папке "Symbian Books". PDF-файл из архива "Symbian Books", который расположен в категории "". Всё это находится в предмете "основы автоматизированного проектирования (оап)" из 3 семестр, которые можно найти в файловом архиве МГТУ им. Н.Э.Баумана. Не смотря на прямую связь этого архива с МГТУ им. Н.Э.Баумана, его также можно найти и в других разделах. Архив можно найти в разделе "книги и методические указания", в предмете "основы автоматизированного производства (оап)" в общих файлах.

Просмотр PDF-файла онлайн

Текст 4 страницы из PDF

. . \epoc32\winscw\ is where you will find the emulator drives.. . . \epoc32\release\winscw\udeb\ is where you will find the binaries for the emulator, particularly epoc.exe which launches theemulator.. . . \epoc32\release\gcce\urel is where you will find the ARMlibraries your code will compile against.The code examples are split between the generic Symbian OS examplesand the examples using APIs specific to the S60 or UIQ platform.SDK documentation is mainly in the form of CHM or PDF files.

Itcontains information related to all the APIs publicly available in SymbianOS, along with information about the tools included in the SDK.POST-INSTALLATION71.3.3 EmulatorsThe DOS command line to start the emulator is always:. . . \epoc32\release\winscw\udeb\epoc.exeOn a UIQ 3.1 emulator, it is recommended to lower the color depthby replacing WINDOWMODE COLOR16MU by WINDOWMODE COLOR64K inthe file. . . \epoc32\release\winscw\udeb\z\system\data\wsini.iniIn the Symbian OS file system, the Z: drive represents the phone’s ROM.2Quick StartThis chapter explains how to create a Hello World application forSymbian OS and deploy it to a smartphone.

You will also learn how tomake a small modification to the Hello World application.2.1 Hello World Project TemplateCarbide.c++ includes several project templates, that you can use todevelop a Hello World application. There are project templates to createS60 GUI applications and UIQ GUI applications.This book provides an additional template of the Hello World application for Carbide.c++. Our template creates a Hello World projectthat can be compiled for both S60 3rd Edition and UIQ 3 platforms.The template can be downloaded from the web page for this book(developer.symbian.com/quickrecipesbook).To install the Hello World template from this book, extract the ZIP fileto the plug-ins folder of Carbide.c++.

For example, the default plug-infolder for Carbide.c++ v1.3 is c:\apps\carbide.c++ v1.3\plugins.You may have a different folder name depending on where you installedCarbide.c++. Note that the Carbide.c++ IDE has to be restarted after thenew template is copied.2.2 Running Carbide.c++ IDECarbide.c++ can be run from the Start menu or Windows Desktop. Whenfirst launched, it will ask for the workspace (see Figure 2.1). A workspaceis a folder where your projects are stored.

Note that a workspace pathshould not contain spaces, because of limitations of the tool chain (you10QUICK STARTFigure 2.1 Selecting a Workspace in Carbide.c++will get a compilation error when using a workspace with a path thatcontains spaces).After selecting a workspace, you will see the main window of Carbide.c++ (Figure 2.2), which is also known as a ‘perspective’.

This bookdoes not explain the user interface of Carbide.c++. Please refer to Carbide.c++ Help to learn about it, or refer to the Symbian Press booklet atdeveloper.symbian.com/carbide booklet wikipage.Figure 2.2 Main Window of Carbide.c++2.3 Generating the Hello World ProjectFollow the instructions below to create a new Hello World project.GENERATING THE HELLO WORLD PROJECT111.

From the Carbide.c++ main window, select the File | New | SymbianOS C++ Project menu.2. On the New Symbian OS C++ Project dialog, select Quick Recipeson Symbian OS > Hello World (see Figure 2.3).Figure 2.3 Create a New Project Using the Hello World Project Template3. Click Next and enter the project name (see Figure 2.4). Note that theproject name should not contain any spaces. For this example, let’suse ‘HelloWorld’ as the project name.Figure 2.4Enter a New Project Name124.QUICK STARTClick Next and select the SDK where you want to build the project(see Figure 2.5). Note that this template is compatible with S60 3rdEdition (all Feature Packs) and UIQ 3 (UIQ 3.0 and 3.1). You canchoose S60 3rd Edition or UIQ 3.x or both of them.Figure 2.55.Select SDKClick Next to enter the basic properties of the project (see Figure 2.6).The most important field on this dialog is the Application UID.

It is aunique identifier for your application.Figure 2.6Entering Basic Properties of the ProjectYou can apply for UIDs for your applications on the Symbian Signedwebsite (www.symbiansigned.com). For now, for development andBUILDING THE HELLO WORLD PROJECT13testing purposes, you can use UIDs in the range of 0xE00000000xEFFFFFFF. By default, Carbide.c++ assigns a random UID in thisrange for your project.6. Click Finish button to create the project.If successful, Carbide.c++ will have created a Hello World project thatcontains several folders (see Figure 2.7):• group contains the project files used to build the application.• src contains the source code files (.cpp files).• inc contains the header files (.h files).• data contains the resource definition files (.rss files) used to createmenus and some other UI-related components.• gfx contains the graphic files used to create icons.• sis contains the package files (.pkg files) used to create an installation file.Figure 2.7 The Folders Created for a Standard Symbian C++ Project2.4 Building the Hello World ProjectA Symbian OS project can be built for the emulator or for a smartphone(sometimes known as a device or target hardware).

Separate builds arerequired for the emulator and the smartphone; that is, an executable filefor the emulator cannot be run on the smartphone, and vice versa. Toallow you to switch easily between these builds, Carbide.c++ creates a‘configuration’ for each.Building a project from Carbide.c++ IDE can be done by selecting theProject | Build project menu. Alternatively, you can also right click theproject name and select the Build project menu.Before building a project, you can set the active configuration, tobuild for the emulator or device target.

Setting the active configurationcan be done by right clicking the project name and selecting the Buildconfigurations | Set Active configuration menu (see Figure 2.8).14QUICK STARTFigure 2.8 Selecting the Active Build Configuration on Carbide.c++ IDEThere are normally two build configurations:• Emulator Debug (WINSCW). This requires a compiler, called NokiaCodewarrior C/C++ Compiler for Windows/x86. This compiler isinstalled with Carbide.c++.• Phone Release (GCCE). This requires the GCC-E (GNU Compiler Collection for Embedded ) compiler.

The SDKs provide this free compileras part of their installation packages.(If you have the RVCT compiler installed, you may have additionalbuild configurations available for smartphone builds. For the discussionin this chapter, we will be concentrating on WINSCW and GCCE buildconfigurations only, but more information about the differences betweenthe GCC-E and RVCT compilers can be found in Chapter 6, Section 6.1.3.)Tip: At the time of writing this book, most SDKs do not supportWindows Vista.

There is a workaround available from the ForumNokia wiki (see links section at the end of this chapter) to make anSDK work on Windows Vista.2.5 Running the Hello World Application on the EmulatorSelect the Run | Run menu from the Carbide.c++ IDE to run Hello Worldon the emulator. You can select the Run | Debug menu to debug theproject. Alternatively, you can also right click the project name to selectthe same menus.Figure 2.9 shows the Hello World application running from the emulator.

The S60 3rd Edition emulator is shown on the left, and the UIQ 3emulator on the right.This Hello World application simply displays the text ‘HelloWorld’,which is the project name, on the screen, as can be seen in Figure 2.9.RUNNING THE HELLO WORLD APPLICATION ON THE EMULATOR(a) S60 3rd Edition emulatorFigure 2.915(b) UIQ 3 emulatorHello World Application Running on the EmulatorsThe application also contains a single menu item that can be selectedeither via the Option softkey on S60 or by a mouse click on the ‘HelloWorld’ title on UIQ (that area is called the title bar).

Selecting theCommand1 menu item displays a notification dialog.2.5.1 Configuring the EmulatorThe S60 emulator is configurable to represent different screen resolutionsand orientations (portrait or landscape). To do this, click the buttonat the top left of the emulator’s window.

Figure 2.10 shows the sameHello World application running in the landscape mode. Notice that theOptions menu is on the bottom right of the screen and the Exit menu onthe top right of the screen.Figure 2.10 Hello World Application Running on the S60 3rd Edition Emulator in Landscape Mode16QUICK STARTThe UIQ emulator can be configured to represent different inputmodes, softkey or pen mode, as well as screen orientation. This can bedone using the uiqenv command. The following command changes theinput mode to pen mode and the screen orientation to landscape:uiqenv -ui penlandscapeThe following command changes the input mode to softkey mode:uiqenv -ui softkeyFigure 2.11 shows the same Hello World application running on theUIQ 3 emulator in softkey mode. Notice that now the application has a‘More’ softkey label at the bottom right of the screen. Pressing the rightsoftkey on the emulator will bring up the menu.Figure 2.11 Hello World Application Running on the UIQ Emulator in Softkey ModePlease refer to the SDK documentation for more information aboutvarious UI configurations.2.6 Running the Hello World Application on the DeviceRunning the Hello World application on the device requires a SIS installation file (.sis file).

The installation file is created from the PKG packagefile (.pkg file), located in the \sis folder of the project. More information about the syntax to use in a PKG file can be found in the SymbianDeveloper Library CHM documentation, found in each SDK.During the build process, the SIS file will be created automaticallyfrom the HelloWorld.pkg file. The result is HelloWorld.sis andHelloWorld.sisx.

The .sis file is an unsigned installation file andthe .sisx a signed installation file. Nothing enforces that difference inRUNNING THE HELLO WORLD APPLICATION ON THE DEVICE17filename extensions. Although it is unlikely you will ever see an unsigned.sisx file, signed .sis files are common.You can use a number of ways to transfer the SIS file from yourPC to the smartphone. For example, the phone manufacturers normallyprovide a PC application to install the SIS file to the smartphone (Nokiareleases Nokia PC Suite for S60 devices; Sony Ericsson releases PC Suitefor Smartphones for their UIQ 3 devices). So you could use the PCapplication that comes with the phone to install the SIS file or you couldsend an SMS that can be used to point the web browser of the phone tothe SIS file, so that you can download and install it.

Alternatively, you cansimply use a Bluetooth connection between a PC and the smartphone tosend it to the phone.Figure 2.12 shows the Hello World application running on S60 3rdEdition and UIQ 3 devices.(a) S60 3rd Edition device(b) UIQ 3 deviceFigure 2.12 Hello World Application Running on the DeviceWhat may go wrong when you install the SIS file:You may get an error message when you come to install the SIS file,which reads something like ‘‘Certificate error. Contact the applicationsupplier.’’This is because some devices, such as most S60 3rd Edition devices,do not allow installation of unsigned SIS files. You must self-sign theSIS file, using your own certificate (or you could get it signed by acertificate/key pair from Symbian Signed).There are also some smartphones, such as Nokia ESeries phones,that do not allow the installation of self-signed applications by default.You have to make a change in the Settings menu to enable installationof self-signed applications.On the other hand, there are some other devices, such as UIQ 3devices from Sony Ericsson, which allow installation of unsigned SISfiles.The bottom line is that each device manufacturer may have adifferent policy about installing unsigned and self-signed applications.The developer community for your platform can help you sort it all out.18QUICK START2.7 Modifying the Hello World ProjectThis section shows how to add a new menu item to display a notificationdialog.

Свежие статьи
Популярно сейчас
Как Вы думаете, сколько людей до Вас делали точно такое же задание? 99% студентов выполняют точно такие же задания, как и их предшественники год назад. Найдите нужный учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
5232
Авторов
на СтудИзбе
424
Средний доход
с одного платного файла
Обучение Подробнее