Working with Carbide.vs

Note: These instructions provide an overview of the most important Carbide.vs features that you need when using this IDE with the SDK. For more detailed information and instruction, please refer to the IDE's own documentation by selecting Help > Help Contents from the Carbide.vs menu bar.

Creating a project

Carbide.vs provides a number of different ways in which to get started with application development.

Importing an existing S60 3rd Edition project

Carbide.vs allows you to import an existing S60 3rd Edition project based on its .mmp or bld.inf file. The import process does not move the project files, it creates a Visual Studio project that maps the existing files into Visual Studio. The project structure of the created Visual Studio project corresponds to the physical directory structure of the imported project, with the exception of files referred to by the .mmp file that do not reside in the source project directory hierarchy. These files appear under an External dependencies folder in the project.

Select either the .mmp or bld.inf file of an existing S60 3rd Edition project to import it into Microsoft Visual Studio. If you select an .mmp file, a single project is imported. If you select a bld.inf file, projects are created in the same solution for each .mmp file pointed to in that bld.inf file.

To import an existing S60 3rd Edition project, open the Import Symbian Project Wizard by selecting File > Import Symbian Project from the menu bar.

For more detailed information, please refer to the following topic in the Carbide.vs Help:

  • Using Carbide.vs > Importing an Existing Symbian OS Project

Cloning an existing S60 1st or 2nd Edition project

Carbide.vs allows you create an S60 3rd Edition project (i.e. Symbian OS 9.1 and later) based upon an existing S60 1st or 2nd Edition (i.e. earlier than Symbian OS 9.1, "Symbian Classic") project. In this cloning process, Carbide.vs:

  • creates a second project called <project_name>_V9 under the same Visual Studio solution

  • creates a new .mmp file called <project_name>_V9.mmp based on the old .mmp file

  • creates a new Carbide.vs properties file for the Symbian 9 project

  • adds links to the source files (.cpp and .h) of the Symbian Classic project

  • adds the new <project_name>_V9.mmp file to the new project

  • adds links to the .bmp files of the Classic project - the .cpp files in both projects point to the same physical files so that just one copy of each file exists

  • creates and adds a <project_name>_V9.iud.cpp file to the new project

Note: A cloned project is not complete, as some files are missing and others need to be modified

Note: When you make changes to the .cpp and .h files in your new Symbian 9 project, the changes also appear in the source Classic project because both project link to the same physical files.

For more detailed information on how to clone an existing S60 1st or 2nd Edition project, please refer to the following topic in the Carbide.vs Help:

  • Using Carbide.vs > Cloning a Symbian OS Project

Creating a new Symbian OS project

Carbide.vs provides various project templates, which allow you to create new skeleton Symbian OS projects. The templates also include a skeleton for creating an S60 3rd Edition project.

To create a new Symbian OS project, select File > New > Project from the Carbide.vs menu bar and enter the needed information in the New Project wizard that opens.

For more detailed information on how to create a new Symbian OS project, please refer to the following topic in the Carbide.vs Help:

  • Using Carbide.vs > Creating a Symbian OS Project

Working with a project

Once you have created or imported a project you can start working on it in Carbide.vs. Carbide.vs makes extensive use of task tools and wizards, which guide and assist you in your development tasks.

For more detailed information on how to create a new Symbian OS project, please refer to the following topic in the Carbide.vs Help:

  • Using Carbide.vs > Modifying a Symbian OS Project

  • Using Carbide.vs > How Tos

Building a project for the S60 emulator

In order to run a Carbide.vs project on the S60 emulator, you need to create a WINSCW debug build of it. Notice, that you cannot install this build onto a real S60 device; for this you will need to create a GCCE release build.

To create a WINSCW build of a project in Carbide.vs , do the following:

  1. Select the appropriate debug (WINSCW indicated by Deb_#, in this case "Deb_S60_32_WINSCW") build configuration from the Configuration drop-down menu in Visual Studio.

  2. Start the build. You can use the following methods:

    • click Build > Build <project_name>

    • right-click the name of the project and select Build from the drop-down menu.

The build starts. You can follow the progress of the build in the Output window.

Note: Once you start a build, wait until it has completed before continuing to work on the project. Do not select or click on any commands.

Once the build has completed, a "Done" message appears.

For more detailed information on how to create S60 3rd Edition builds in Carbide.vs, please refer to the following topic in the Carbide.vs Help:

  • Using Carbide.vs > Building a Symbian 9 Project

  • Using Carbide.vs > How Tos

Running and debugging an application in the S60 emulator

To run an application on the S60 emulator from Carbide.vs do the following:

  1. Choose whether you would like to debug or not.

    • If you would like to debug, click Debug > Start.

    • If you do not want to debug, click Debug > Start Without Debugging.

  2. If the build configurations are not up-to-date, the Microsoft Development Environment dialog appears, asking you if you would like to build your project(s).

    • If you would like to build, click Yes. The build runs as per normal for the project type, and the emulator then appears automatically.

    • If you would not like to build, click No. The emulator appears anyway.

    • If you decide not to run your application in an emulator, click Cancel. The dialog disappears and nothing happens.

If the build configurations are correct, the S60 emulator appears. (See Using Carbide.vs with the SDK for instructions on how to configure the S60 emulator for Carbide.vs.)

Debug mode

In debug mode, Microsoft Visual Studio opens debugging tools: Autos, Locals, Watch, Call Stack, Break Points, and Command Window. It also runs the command Debug in the Output window.

You can open your .cpp files and place breakpoints in them. The breakpoints provide an easy way to localise bugs by temporarily halting your program.

Building an application for an S60 target device

In order to be able to install an application to a real S60 device, you need to create a GCCE release build of it.

To create a GCCE build with Carbide.vs, do the following:

  1. Select the GCCE build configuration for your SDK from the list of possible build configurations in the toolbar.

  2. Select a default certificate in the Security Properties of Carbide.vs Properties - the certificate must have been defined for Carbide.vs using the Tools > Manage certificates wizard.

    Alternatively, deselect Auto signing in the Security Properties of Carbide.vs Properties and manually sign the .sis file at the end of the build.

  3. Start the build. You can use the following methods:

    • click Build > Build <project_name>

    • right-click the name of the project and select Build from the drop-down menu.

You can follow the progress of the build in the Output window.

Note: Carbide.vs creates a <project_name>.uid.cpp file for the project under the group folder, which is compiled with the other source files to identify the application in the environment. After the first build, this file appears in the group directory.

Carbide.vs:

  • Creates a .pkg file, If there is no .pkg file and if Update .pkg file is selected in Carbide.vs Properties.

  • Compiles a .sis file, if Generate .sis file is selected in Carbide.vs Properties.

  • sSigns the .sis file, if Auto signing is selected in Carbide.vs Properties. Note that if you select Generate .sis file, then you should also select Update .pkg file to make sure the .pkg file is up-to-date.

The .pkg, .sis, and <project_name>_<certificate_name>.sis files are placed in project directories. For more information on the contents of the .pkg file after build generation, see Auto-managing the .pkg file in the Carbide.vs Help.

Once the build has completed, a "Done" message appears.

Notice, that in S60 3rd Edition all applications need to be signed before installing them to a real S60 device. Please refer to Mandatory Signing of Applications for more information on this.