Discussion Board

Results 1 to 2 of 2
  1. #1
    Regular Contributor
    Join Date
    Mar 2006

    Runtime Platform


    I have written a script in Python for my PC and I now want it to run on my N70 aswell taking advantge of the S60 user interface. I know the S60 extensions are not available on the PC. How can the check what platform it is running on before executing some code such as "import appuifw"?



  2. #2
    Super Contributor
    Join Date
    Oct 2007
    Deva, Romania

    Re: Runtime Platform

    If you want to know the name of the os, you could do this:
    import platform
    print platform.system()
    This will return 'Symbian' on the phone and 'Windows' on the PC (assuming you're using Windows, of course).

    Another technique is to try to import appuifw and if it fails, you're most likely not on Symbian:
        import appuifw
        print "On Symbian"
    except ImportError:
        print "Not on Symbian"

Similar Threads

  1. detecting S60 platform edition during runtime?
    By nicholso in forum Mobile Java General
    Replies: 19
    Last Post: 2010-09-11, 20:43
  2. Replies: 4
    Last Post: 2010-02-25, 16:35
  3. Retreiving the Platform Version at Runtime
    By preethi in forum Symbian
    Replies: 1
    Last Post: 2008-01-29, 13:57
  4. getting platform uid in runtime
    By mopa in forum Symbian
    Replies: 3
    Last Post: 2007-06-05, 11:54
  5. identify at runtime the platform I am on
    By tal.shahar@mobile-mx.com in forum Symbian
    Replies: 5
    Last Post: 2006-10-17, 10:57

Posting Permissions

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