×

Discussion Board

Results 1 to 8 of 8
  1. #1
    Registered User
    Join Date
    Jun 2008
    Posts
    37

    How to Reboot phone?

    Hi,

    is it possible to make the phone reboot with a command from qt? didnt find any code to do that?

    Would help me a lot!

    Thanks!

  2. #2
    Nokia Developer Champion
    Join Date
    Nov 2009
    Location
    Minnesota, USA
    Posts
    3,209

    Re: How to Reboot phone?

    Nope. Maybe using some Symbian code, but not (intentionally) with vanilla Qt.

  3. #3
    Regular Contributor
    Join Date
    Dec 2010
    Posts
    142

    Re: How to Reboot phone?

    The trick lies in killing a system process, system will reboot. You can do this with symbian code.
    One wiki link for your refrence:
    http://wiki.forum.nokia.com/index.ph...eSelect=German

  4. #4
    Super Contributor
    Join Date
    Mar 2004
    Location
    Singapore
    Posts
    9,968

    Re: How to Reboot phone?

    I donot suggest killing phoneapp to restart ... i suggest you post the problem in Symbian.C++ to get a proper re-start APIs

  5. #5
    Registered User
    Join Date
    Dec 2006
    Posts
    2,280

    Re: How to Reboot phone?

    Yes, there is a Symbian API to request a reboot nicely. Don't go killing system critical processes to force it to happen.

    I'd strongly suggest deleting that wiki page if there are any wiki admins reading this.

  6. #6
    Regular Contributor
    Join Date
    Dec 2010
    Posts
    142

    Re: How to Reboot phone?

    Quote Originally Posted by dahiya.vinod View Post
    The trick lies in killing a system process, system will reboot. You can do this with symbian code.
    One wiki link for your refrence:
    http://wiki.forum.nokia.com/index.ph...eSelect=German
    Ok Ok, sorry. I was just kidding(it is just a hakish method, as no public api exists) and the wiki article is not written by me. Proper symbian api(found in my old codes, don't know from where i got this) is:
    Create this header:

    Code:
    enum TSWStartupReason
            {
        // Normal startup reasons (100..149)
    
        // Nothing set the (default value).
        ESWNone = 100,
    
        // Restore Factory Settings (Normal)
        ESWRestoreFactorySet = 101,
    
        // Language Switched
        ESWLangSwitch = 102,
    
        // Warranty transfer
        ESWWarrantyTransfer = 103,
    
        // Possibly needed for handling
        // power off & charger connected use case.
        ESWChargerConnected = 104,
    
        // Restore Factory Settings (Deep)
        ESWRestoreFactorySetDeep = 105
            };
    
    //wrapper class (hacked) to restart the system
    class SysStartup
    {
    public:
    	IMPORT_C static TInt ShutdownAndRestart( const class TUid& aSource, TSWStartupReason aReason);
    };
    include sysutil.lib in your mmp
    or
    lsysutil in your qt pro file.

    and use this code to reboot:

    Code:
    //reboot system
    TUid t={0x01020534};  
    SysStartup::ShutdownAndRestart(t,ESWLangSwitch );

  7. #7
    Regular Contributor
    Join Date
    Sep 2008
    Posts
    286

    Re: How to Reboot phone?

    You won't be able to call reboot functions nor kill processes without PowerManagement capability.

  8. #8
    Registered User
    Join Date
    Jun 2008
    Posts
    37

    Re: How to Reboot phone?

    thanks for all your replies, killing system process is the easiest way - will have a look at the api solution now!

    Thanks!

Similar Threads

  1. How to reboot phone programmatically?
    By manpacker in forum Python
    Replies: 1
    Last Post: 2010-08-20, 09:41
  2. How to auto reboot the phone?
    By suiying0792 in forum Symbian C++
    Replies: 11
    Last Post: 2009-10-18, 14:52
  3. Reboot phone
    By manugarrote in forum [Archived] Flash Lite on Nokia Devices
    Replies: 3
    Last Post: 2008-03-28, 14:52
  4. Reboot Phone Command
    By cliveburt in forum PC Suite API and PC Connectivity SDK
    Replies: 0
    Last Post: 2005-11-08, 08:39
  5. What could cause a phone reboot?
    By bjorn.rudolfsson in forum Symbian C++
    Replies: 9
    Last Post: 2004-02-10, 11:04

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •