Weather App #3808
Replies: 1 comment
-
Posted at 2020-04-04 by @gfwilliams Hi! Sounds like a great idea - I'm pretty sure the weather support for Bangle.js is already in Gadgetbridge, so you'd just need to extend what we have at the moment to make use of it. I think Gadgetbridge needs a second app installed to grab weather, but then the format data comes to the watch in is: http://www.espruino.com/Gadgetbridge Posted at 2020-04-04 by Purple-Tentacle See here:
I do not know if GB sends that regularly or how you can trigger that. Posted at 2020-04-04 by Purple-Tentacle So the second app obtains the data and then sends it through GB to the Bangle? Posted at 2020-04-04 by NebbishHacker Nice! That sounds a lot more straightforward than I was expecting. Posted at 2020-04-04 by NebbishHacker Sounds like it. See here: https://codeberg.org/Freeyourgadget/Gadgetbridge/wiki/Weather Posted at 2020-04-06 by NebbishHacker I've been having fun making a sort of mock up in the emulator with randomly generated weather :) https://gist.github.com/nebbishhacker/cde2bef286bffa1a7e3b523180402c89 Posted at 2020-04-06 by Purple-Tentacle Wow, looks great. Posted at 2020-04-06 by @MaBecker I like the fact that you use draw and fill to create the weather conditions instead of using images. Posted at 2020-04-06 by Old_account Stunning! I wants it. Posted at 2020-04-06 by @gfwilliams That looks great! While we have the Image Converter I wonder whether we couldn't make one that created a bunch of Espruino draw calls from an SVG? Posted at 2020-04-06 by NebbishHacker That would be super handy - I actually created SVG versions of most of the weather symbols while I was contemplating how to render them, so an SVG to Espruino draw call converter would have been perfect. I imagine you'd have to pick a subset of the SVG spec to support, though. Another possibility would be to create a simple web-based vector editor with the limitations of the Graphics API in mind. Posted at 2020-04-08 by Francesco_C Hi NebbishHacker, did you prepare the app with this solution? Thank you for dedicating your time to the issue and I hope that it will appear on the repository. Consider that, thanks to the great Gordon's idea, I am now approaching for the first time js and I really need a "tutorial for dummy" for using your codes as fully enjoyable apps. Cheers Posted at 2020-04-08 by NebbishHacker I'm afraid this isn't a full app yet. My smartwatch hasn't arrived, so all I can do right now is experiment with the emulator. When it arrives I will for sure keep working on this and try to get it included in the app loader. Posted at 2020-04-08 by Francesco_C I guess if the watch had been in your hands earlier than in mine it would have been more fruitful 😄 Posted at 2020-04-11 by DerGuteWolf there are also some animated svg weather icons available here: https://github.com/ghys/org.openhab.ui.iconset.climacons/tree/master/icons Posted at 2020-04-14 by Francesco_C Thank you Dergutewolf. I hope some guys of you could share a working application. I'm not yet able to write a working code 🙄 Posted at 2020-04-21 by rigrig
Thanks! That looked pretty amazing, and it seemed like a shame to let all that hard work to to waste. The way you draw those images also made it really easy to use a smaller version for a widget :-) Posted at 2020-04-21 by NebbishHacker Ah, cool! I'll likely contribute some more changes to this myself when my watch finally arrives, but in the meantime it's great to see this turned into something people can actually use :) Posted at 2020-04-25 by jpoles1 Hi all! I just received my watch a couple days ago and I've been working on porting over a watchface that I had written for the Pebble Time way back when I first got that watch. I also hope to incorporate weather updates into my watchface. As far as I can tell, there's no good way to request a weather report right now from the bangle.js, seems like we can only passively receive updates from the gadgetbridge weather app? I think it would be really great if there was a way to execute any sort of arbitrary API request from bangle.js apps. Is this possible? Posted at 2020-04-25 by Robin Sat 2020.04.25
Good Morning @jpoles1, a discussion about this very topic was started last week: Please review for ongoing updates. As this is recent content and may not have been indexed yet, for future searches, load a Google page instance and type a concise request using the 'site:' keyword qualifier. See examples in: Posted at 2020-04-25 by jpoles1 Amazing work with this watch app, really cool how you were able to use the gadgetbridge notifications. And very clever to save the weather to settings for persistence of the weather data when the app is not open! Posted at 2020-04-25 by Robin
If I'm not mistaken, the you that is referred to, as stated #18 post by rigrig in reply to @nebbishhacker, gives credit #22 post to the wrong individual. See emulator link from three weeks ago in #7 post. Even stated as such in the actual pull request. Posted at 2020-04-25 by jpoles1 Apologies if I'm mistaken, but I think @rigrig wrote the code to accept gadgetbridge weather notifications while using @nebbishhacker hacker's lovely code for displaying the weather itself. Not sure who wrote the code to persist to storage... I didn't think it was that important to be so specific in an informal forum post. Posted at 2020-04-25 by NebbishHacker
For this specific case you could look into adding a new "requestweather" message to the Bangle.js <-> GadgetBridge protocol, which is documented here and implemented by GadgetBridge here. I don't think there's any way of doing completely arbitrary API requests at the moment, though.
This is correct, I only contributed the mock up in the emulator. @rigrig deserves all the credit for making it into an actual app :) Posted at 2020-04-25 by Robin Sat 2020.04.25 Thanks for the clarification @nebbishhacker. While you both deserve credit, merging isn't quite the same as developing and presenting the concept, that credit earned.
@BobFrankston has made progress here, see #21 post. Posted at 2020-04-25 by BobFrankston Alas, not much headway on the weather part until I get simple connectivity. Working on it. Posted at 2020-04-27 by @gfwilliams As @nebbishhacker says - right now you can't request weather from Gadgetbridge. It's possible we could work on a way to request it, but it may be that actually all Gadgetbridge would do in that case is push the last known weather info. I guess it might be possible to add some kind of universal on-Bangle storage for Gadgetbridge - so like is done for the weather app, but just irrespective of what app is installed Posted at 2020-04-27 by Purple-Tentacle
That would make sense. You could store all kinds of stuff like weather info, music state and info etc. Posted at 2020-05-07 by user112261 Any way that I can contact gadgetbridge for the weather app? I am new to this watch and need as much help as I can get. Thank you, Hank Posted at 2020-05-07 by Raik Hi Hank, you can start by reading the readme from the weather app³ itself: https://github.com/espruino/BangleApps/tree/master/apps/weather It has also linked a guide how to setup the weather app² for GB: https://codeberg.org/Freeyourgadget/Gadgetbridge/wiki/Weather To summarize:
Hope the helps to get started. foot notes: Posted at 2022-01-12 by user133684 Was there ever a message devised to request updated/new weather from Gadgetbridge? I have been digging through documentation but haven't found any. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2020-04-04 by NebbishHacker
When my watch arrives I was thinking I might see about creating a simple app or widget to tell me the current weather. Has anyone else started on anything like that?
Also, if I were to create such an app, what would be the most straightforward way to get current weather information onto the watch? I see that GadgetBridge supports weather for some other models of smart watches, would it be possible to take advantage of that?
Beta Was this translation helpful? Give feedback.
All reactions