Development help - ram / event usage

Posted on
  • Hey together,

    currently i am trying to develop an App, that checks for updates on other apps and notifys, if there are any.
    This is done with the new Bangle.js Gadgetbride version and internet access.
    Later i would like to automate that with the schedular lib.

    I have the thing up and running, and everything works fine, if i upload it directly from the IDE into the RAM.
    But when i install the app from the App loader, i dont get the Event, that GB sends to me.

    I think it has something to do with how functions are stored, triggered, and so on. I just don't fully understand how it works.
    Also when i trigger the download from the app, the first download works. But when i trigger the same function from the Settings app, it doesn't. Think that has also something todo with that.

    Would be thankfull for an explanation of how the functions are stored in memory/ram, so on.

    If you want to check my code:­ree/master/apps/updateNotifier
    And here is the App:­=update%20notefier

    Thanks for your help.

  • Hi - the settings js file is a standalone bit of code that's run from the settings app. It looks like you're trying to call startDownload from the settings app - but it won't work because your app isn't loaded at that point... If you want to do it from both places I guess it's best to make it a library...

    It feels like what you're doing there should work though - maybe you can use the Web IDE's Storage menu to look at the files when you upload them via the IDE and the files when they're uploaded via the app loader and see if there's any difference?

    Just a note - you're overwriting the GB event handler there, and so you'll stop any other Gadgetbridge functionality from working while the app is running. Maybe that's not a big deal though.

    I do hope to build an http function into the android app very soon though, so hopefully you won't have to mess around with the GB function - you can just change to doing http(url)...

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview

Development help - ram / event usage

Posted by Avatar for _pasi @_pasi