2-way communication with Android app (through intent?) #5470
Replies: 1 comment
-
Posted at 2022-07-08 by Mark_M
Posted at 2022-07-08 by TheLastProject
Well, it'll be small, but I'd hope so. I am carefully optimistic seeing how clear the screen is.
I'm not completely sure what you mean here, could you elaborate? Posted at 2022-07-08 by Mark_M do you really need to send barcodes from Android to Bangle each time a user wants to show a barcode in a store? Posted at 2022-07-08 by @thyttan Here are some links! :) Gadgetbridge Bangle.js flavor documentation - intents. Maybe you want to do something with http-requests? There's some info about that here as well. Sending intents from android to Bangle.js is possible. Sending intents from Bangle.js to android is possible. Posted at 2022-07-08 by TheLastProject
Well, it seems like the best user experience as it allows you to keep managing your loyalty cards on your phone instead of having to duplicate the cards you care about.
That is an option, but intents are the more "native Android" option. With intents I wouldn't have to have a long-running webserver process and Android natively supports shielding intents behind permissions so only apps you've given the relevant custom permission can call the intent (Gadgetbridge would be one of those apps).
Thanks, I had trouble finding anything like this in the documentation. So, This could work, thank you :) Lot of work and I have other tasks to complete first, but I have a route to explore now :) Posted at 2022-07-09 by Mark_M
Sending bitmaps via BLE each time may be not a best way to do it. Posted at 2022-07-09 by TheLastProject Well, the "standard" barcodes are. But Aztec, Data Matrix, PDF 417 and QR codes are not. So this optimization would only be possible for some barcode types. Posted at 2022-07-09 by Mark_M Hmm, all cards I have have "standard" barcodes. :) Posted at 2022-07-11 by @gfwilliams Hi! Adding support for Bangle.js in your app sounds great! Hopefully That way it'd 'just work' without needing a specific app installed on the Bangle first. Posted at 2022-07-11 by @thyttan Oh, that's cool! Posted at 2022-07-12 by TheLastProject Hmm, well, I guess I can start with a "Send to smartwatch" feature maybe, to keep it simple. But it still feels incorrect for Catima to contain the logic for Bangle.js' UI. Useful for prototyping though! Posted at 2022-07-13 by @gfwilliams
Since the menus are in Bangle.js already, the UI logic is probably just sending Up to you what you want to do, but if you have a separate app then you've also probably got to add extra logic in there to check that the Bangle.js app is installed and the version matches your Android app (in case at some point you need to change the protocol). Personally, I think it would be nice to be able to use the Bangle to display barcodes without needing the phone connected (while still using the phone to actually manage everything). If that's the case then a Bangle.js app would make far more sense though - and you could use Catima to just sync the barcode data that's on the Bangle... Posted at 2022-12-11 by glemco Any news on this? I once had the crazy idea of wanting Opentasks tasks on the bangle without the need of modifying open tasks at all. Didn't dig into it too much for lack of knowledge on the android layer, but my idea was to use the share button which would produce a text, send it to gadgetbridge as a FW/App (the menu is there but I'm not sure it works, it didn't when I tried) and maybe have it ask what name should the file have on the bangle. Posted at 2022-12-11 by glemco . Posted at 2022-12-11 by TheLastProject I haven't made any progress on this myself. However, the Gadgetbridge team passed by and started doing https://codeberg.org/Freeyourgadget/Gadgetbridge/pulls/2953, which hopefully helps. Posted at 2022-12-13 by glemco Good to know, looks promising! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2022-07-08 by TheLastProject
Hey everyone,
I'm the developer of Catima, an Open Source loyalty card app for Android. People have been asking for WearOS support, but I am kinda not looking forward to supporting only proprietary platforms, so I've been trying to figure out if I can support Bangle.js instead.
Specifically, I want to support getting a list of your loyalty cards and when clicking a card show the barcode. This would need at least some kind of 2-way communication and I was wondering if it's possible to:
Is this possible? And if data is sent back somehow, is it possible to send an image file back so that the Bangle.js won't need any code to render barcodes itself?
Thanks in advance for any answer :)
P.S.: Is there any reason why the forum doesn't have a valid SSL certificate? Could this be fixed by any chance?
Beta Was this translation helpful? Give feedback.
All reactions