Discussion Board

Results 1 to 9 of 9
  1. #1
    Registered User matuslaco's Avatar
    Join Date
    Jun 2007
    Posts
    13
    Could someone please sign

    http://sourceforge.net/projects/pys6...e.SIS/download

    for this imei: 358640019988949

    thanks!

    the reason is that I need the messaging (access inbox) capability, the self-signed opensigned does not provide this capability...

  2. #2
    Nokia Developer Moderator bogdan.galiceanu's Avatar
    Join Date
    Oct 2007
    Location
    Deva, Romania
    Posts
    3,471
    If you sign it using Open Signed Online it will work. The list of capabilites that are not available is mentioned on that page, at the last point in the bullet list. The ones you need are not among them.

  3. #3
    Registered User matuslaco's Avatar
    Join Date
    Jun 2007
    Posts
    13
    what a fast response, thanks!!!

    my script does not work with open signed version.
    Same problem (another user) here: http://discussion.forum.nokia.com/fo...in-pys60/page2

  4. #4
    Nokia Developer Moderator bogdan.galiceanu's Avatar
    Join Date
    Oct 2007
    Location
    Deva, Romania
    Posts
    3,471
    Strange... I just tried it and it worked. I installed the runtime (PythonForS60_1_4_5_3rdEd.sis) and the signed version of the shell (PythonScriptShell_1_4_5_3rdEd_unsigned_testrange.sis) and ran
    Code:
    import inbox
    
    i = inbox.Inbox()
    print i.sms_messages()
    Does your script do special things that might require other capabilities?

  5. #5
    Registered User matuslaco's Avatar
    Join Date
    Jun 2007
    Posts
    13
    Here is my code (simplified).:

    Code:
    import messaging, inbox, e32, appuifw, socket, urllib, httplib, e32dbm
    
    
    run=0;
    
    
    def message_received(msg_id):
         box = inbox.Inbox()
         
         print u"Message in inbox: " + str(msg_id)
         
         if msg_id in box.sms_messages():
            msg = box.content(msg_id)
            sender = box.address(msg_id)
            if len(msg)>0:
                print u"Message received from: " + str(sender)
                #senddata(sender,msg)
                box.delete(msg_id)
            else:
                print u"Msg too short"
                box.delete(msg_id)
         else:
             box.delete(msg_id)
             print u"Could not fetch message!!!"
    
    def quit():
        print u"Exiting application"
        app_lock.signal()
    
    
    box = inbox.Inbox()
    box.bind(message_received)
    
    appuifw.app.exit_key_handler = quit
    appuifw.app.title = u"Messages(0)"
    
    menu2=[(u"Exit", quit)]
    
    appuifw.app.menu = menu2
    
    print u"Application started"
    
    app_lock = e32.Ao_lock()
    app_lock.wait()
    The problem is that the condition:

    Code:
         if msg_id in box.sms_messages():
    evaluates to false. On 2nd edition device this worked without no problem so I thought it is a capabilities issue.... might it be something else?

  6. #6
    Nokia Developer Moderator bogdan.galiceanu's Avatar
    Join Date
    Oct 2007
    Location
    Deva, Romania
    Posts
    3,471
    Then it's most likely not a capability issue. If a required capability were missing it would have resulted in a KErrPermissionDenied error.

    I can't seem to find the problem. I tried your code and it worked as expected (sent an empty message to myself and the application displayed "Msg too short").

  7. #7
    Registered User matuslaco's Avatar
    Join Date
    Jun 2007
    Posts
    13
    The problem is probably in my device

    1. changed the SMS storage from phone memmory to memory card. I got KErrPermissionDenied Error.
    2. changed the SMS storage from memmory card to phone memmory

    1st SMS - worked
    2nd SMS - the same error( if msg_id in box.sms_messages() returns fals)

    Thanks for your kind help, now I know its to the capablity problem and I can focus on debugging.... e.g. I'll try another device.

  8. #8
    Registered User matuslaco's Avatar
    Join Date
    Jun 2007
    Posts
    13
    Fixed.

    I've added

    timer.after(0.5)

    before

    if msg_id in box.sms_messages():

    and now it seems to work. Any idea why?

  9. #9
    Nokia Developer Moderator bogdan.galiceanu's Avatar
    Join Date
    Oct 2007
    Location
    Deva, Romania
    Posts
    3,471
    It could be that the operating system needs a bit of time to register the message as being in the inbox. Since you were checking that right away it probably didn't have enough time to do its job. That's just a hunch, it could be something else entirely.

Similar Threads

  1. Replies: 1
    Last Post: 2010-05-12, 11:16
  2. Python for S60 3rd Edition
    By jplauril in forum Python
    Replies: 82
    Last Post: 2008-06-04, 04:47
  3. Using a Python Extension (3rd edition)
    By workmaster2 in forum Python
    Replies: 11
    Last Post: 2008-05-30, 19:26
  4. Python for Symbian OS 3rd edition
    By biskero in forum Python
    Replies: 3
    Last Post: 2006-05-11, 11:14
  5. Python for 3rd edition?
    By Reticulatus in forum Python
    Replies: 5
    Last Post: 2006-03-28, 21:59

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved