Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Need help in making simple mobile app
Forum Update on Monday, May 27th 2025

Need help in making simple mobile app

Scheduled Pinned Locked Moved Mobile and Embedded
4 Posts 2 Posters 3.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    doforumda
    wrote on last edited by
    #1

    hi

    i am following this link "Your text to link here...":http://doc.qt.nokia.com/qtcreator-2.0/creator-mobile-example.html#declaring-the-qt-mobility-api to create a BatteryIndicator app. When i run my code it displays this error
    @
    Running build steps for project BatteryIndicator...
    Configuration unchanged, skipping qmake step.
    Starting: "C:/NokiaQtSDK2/QtCreator/bin/jom.exe"
    'cmd' is not recognized as an internal or external command,

    operable program or batch file.

    jom 0.9.4 - empower your cores

    command failed with exit code 1

    The process "C:/NokiaQtSDK2/QtCreator/bin/jom.exe" exited with code %2.
    Error while building project BatteryIndicator (target: Qt Simulator)
    When executing build step 'Make'
    @

    here is my code

    BatteryIndicator.pro
    @
    #-------------------------------------------------

    Project created by QtCreator 2010-10-20T14:42:42

    #-------------------------------------------------

    QT += core gui

    TARGET = BatteryIndicator
    TEMPLATE = app

    SOURCES += main.cpp
    batteryindicator.cpp

    HEADERS += batteryindicator.h

    FORMS += batteryindicator.ui

    CONFIG += mobility
    MOBILITY = systeminfo

    symbian {
    TARGET.UID3 = 0xecbd72d7
    # TARGET.CAPABILITY +=
    TARGET.EPOCSTACKSIZE = 0x14000
    TARGET.EPOCHEAPSIZE = 0x020000 0x800000
    }
    @

    BatteryIndicator.h
    @
    #ifndef BATTERYINDICATOR_H
    #define BATTERYINDICATOR_H

    #include <QDialog>
    #include <QtSystemInfo/QSystemInfo>

    QTM_USE_NAMESPACE

    namespace Ui {
    class BatteryIndicator;
    }

    class BatteryIndicator : public QDialog
    {
    Q_OBJECT

    public:
    explicit BatteryIndicator(QWidget *parent = 0);
    ~BatteryIndicator();

    private:
    Ui::BatteryIndicator *ui;
    void setupGeneral();

    QSystemDeviceInfo *deviceInfo;
    

    };

    #endif // BATTERYINDICATOR_H
    @

    BatteryIndicator.cpp
    @
    #include "batteryindicator.h"
    #include "ui_batteryindicator.h"

    BatteryIndicator::BatteryIndicator(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::BatteryIndicator),
    deviceInfo(NULL)
    {
    ui->setupUi(this);
    setupGeneral();
    }

    void BatteryIndicator::setupGeneral()
    {
    deviceInfo = new QSystemDeviceInfo();
    ui->batteryLevelBar->setValue(deviceInfo->batteryLevel());

    connect(deviceInfo, SIGNAL(batteryLevelChanged(int)), ui->batteryLevelBar, SLOT(setValue(int)));
    

    }

    BatteryIndicator::~BatteryIndicator()
    {
    delete ui;
    }
    @

    main.cpp
    @
    #include <QtGui/QApplication>
    #include "batteryindicator.h"

    int main(int argc, char *argv[])
    {
    QApplication a(argc, argv);
    BatteryIndicator w;
    #if defined(Q_WS_S60)
    w.showMaximized();
    #else
    w.show();
    #endif

    return a.exec&#40;&#41;;
    

    }
    @

    how can i solve this problem? please help

    1 Reply Last reply
    0
    • A Offline
      A Offline
      anselmolsm
      wrote on last edited by
      #2

      @
      'cmd' is not recognized as an internal or external command,
      @

      @
      The process "C:/NokiaQtSDK2/QtCreator/bin/jom.exe" exited with code %2.
      Error while building project BatteryIndicator (target: Qt Simulator)
      When executing build step 'Make'
      @

      Read the error outputs, this error is not related with your code - The building itself not even started!

      I think there is something wrong in your environment, essential commands seems out of the PATH environment variable (the same thing applies to your "other post":http://developer.qt.nokia.com/forums/viewthread/1364/).

      BTW, can you build anything successfully in this environment?

      Anselmo L. S. Melo (anselmolsm)

      1 Reply Last reply
      0
      • D Offline
        D Offline
        doforumda
        wrote on last edited by
        #3

        well i ran builtin examples which successfully ran. i mean when i install nokia qt sdk i first ran example which are on welcome screen and ran successfully.
        how can this problem be solved?

        1 Reply Last reply
        0
        • D Offline
          D Offline
          doforumda
          wrote on last edited by
          #4

          the path variable in env.txt is set to
          @
          Path=C:\NokiaQtSDK2\Symbian\SDK\bin;C:\NokiaQtSDK2\Symbian\SDK\perl\bin;C:\NokiaQtSDK2\Symbian\SDK\epoc32\tools;C:\NokiaQtSDK2\Symbian\SDK\epoc32\gcc\bin;C:\NokiaQtSDK2\Symbian\gcce\arm-none-symbianelf\bin;C:\NokiaQtSDK2\Symbian\gcce\bin;C:\cygwin\bin;C:\Program Files (x86)\SSH Communications Security\SSH Secure Shell
          @

          it this correct? or is there any problem with this

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved