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. [solved] How to detect connected via WiFi?
Forum Updated to NodeBB v4.3 + New Features

[solved] How to detect connected via WiFi?

Scheduled Pinned Locked Moved Mobile and Embedded
8 Posts 3 Posters 5.3k Views 1 Watching
  • 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.
  • S Offline
    S Offline
    SimonJudge
    wrote on last edited by
    #1

    How can I detect, from QML, if the phone is connected via WiFi? (I need to allow the user to do different things when connected to WiFi) If not possible, how can this be done from Qt c++?

    Thanks

    Simon

    1 Reply Last reply
    0
    • T Offline
      T Offline
      tomjanssens
      wrote on last edited by
      #2

      I guess you have to do it from C++. You can watch the QNetworkConfiguration class which has a bearerType.

      1 Reply Last reply
      0
      • S Offline
        S Offline
        SimonJudge
        wrote on last edited by
        #3

        Answering my own question...

        Use import QtMobility.systeminfo 1.1 and NetworkInfo
        Documented here http://doc.qt.nokia.com/qtmobility-1.2/systeminfo.html for Mobility 1.2 but it's in 1.1 as well.

        Simon

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SimonJudge
          wrote on last edited by
          #4

          Further testing has shown that while the QML API is there, it doesn't work on the phone (Symbian^3) under Mobility 1.1.

          Simon

          1 Reply Last reply
          0
          • T Offline
            T Offline
            tomjanssens
            wrote on last edited by
            #5

            The Nokia QT SDK 1.0 contains QT 4.6. For QML you'll need the Nokia QT SDK 1.1 preview:

            http://labs.qt.nokia.com/2011/01/20/qt-sdk-1-1-technology-preview-released/

            or manually install the Symbian SDK and QT 4.7 for Symbian.

            1 Reply Last reply
            0
            • S Offline
              S Offline
              SimonJudge
              wrote on last edited by
              #6

              Thanks tomjanssens for the post but the testing I did was with Nokia Qt SDK 1.1 Tech preview and with the tech preview mobility sis installed.

              Simon

              1 Reply Last reply
              0
              • T Offline
                T Offline
                tomjanssens
                wrote on last edited by
                #7

                I haven't tried the preview yet. I installed the Symbian SDK and the QT 4.7.1 for Symbian^3 which works fine for me. However, it seems that you can no longer download QT 4.7.1 for Symbian^3 (as mentioned here: http://wiki.forum.nokia.com/index.php/Qt_4.7_for_Symbian^3_-_developer_version).

                1 Reply Last reply
                0
                • C Offline
                  C Offline
                  cmer4
                  wrote on last edited by
                  #8

                  Hmm tried to play with this one recently and problem is that the NetworkInfo.networkStatus is deemed "Undefined" for the application.

                  If I play around with the Simulator and edit Network Properties manually - I can get it work (like I am making the mode Connected manually), but how this NetworkStatus is supposed to tell my app what really status the underlying system has (in my case my N8 phone...)

                  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