X10 Community Forum

📱🖥️PiX10Hub => 💬General Discussion => 📝User created HG Scripts (programs/macros/widgets) => Topic started by: soxfan1966 on February 19, 2020, 02:04:08 PM

Title: Stock Ticker Widget
Post by: soxfan1966 on February 19, 2020, 02:04:08 PM
I have been playing around with creating a new widget - originally it was going to be an RSS feed (i.e. news or sports) and ended up with a stock market ticker widget (I plan on doing the news and/or sports one next).

This Stock Widget uses an external script to get the data (and there are multiple version which you can create / customize): https://widgets.tc2000.com/

I have attached a screen show of what my stock widget looks like and also the program and widget code (you will need to rename them from .txt to the appropriate extension).
Title: Re: Stock Ticker Widget
Post by: bkenobi on February 19, 2020, 02:43:53 PM
Looks awesome!  You should share this on the HG repository or your own GitHub repository so others that use HG but don't visit this board can see it.   #:)
Title: Re: Stock Ticker Widget
Post by: soxfan1966 on February 19, 2020, 04:17:44 PM
I have also posted it on the HomeGenie Club forum - once I get it polished up a bit more, and maybe the sports one done, I can put them on GitHub too
Title: Re: Stock Ticker Widget
Post by: Tuicemen on February 19, 2020, 04:47:14 PM
Nice work thus far on this soxfan1966. #:)

I always think of a stock ticker as those scrolling ticker tapes you see on TV.
Your previous works could easily be converted to that so I may play with this as well, even though I'm not a stock guy.
 >!
Title: Re: Stock Ticker Widget
Post by: soxfan1966 on February 19, 2020, 04:51:43 PM
The site I mentioned where I get the content does have a scrolling ticker too - it's just a matter of defining what you want to show.  Then they give you a widget id - you put that in the widget option field (and there are fields for height and width too) and it should display.
Title: Re: Stock Ticker Widget
Post by: Tuicemen on February 19, 2020, 04:57:20 PM
Awesome  when I get some free time I will play with it.
Title: Re: Stock Ticker Widget
Post by: petera on February 19, 2020, 06:08:21 PM
I have been playing around with creating a new widget - originally it was going to be an RSS feed (i.e. news or sports) and ended up with a stock market ticker widget (I plan on doing the news and/or sports one next).

This Stock Widget uses an external script to get the data (and there are multiple version which you can create / customize): https://widgets.tc2000.com/

I have attached a screen show of what my stock widget looks like and also the program and widget code (you will need to rename them from .txt to the appropriate extension).

It really is the only way to get to know HG. You’ve taken to it quite easily. As @bkenobi suggested post these efforts on the HomeGenie.Club forum. You may not get instant feedback but it will be quite constructive when you do.

With your interest in weather have a look at the Pi Sense Hat weather projects. Imagine your own personal weather station with local weather data. Great for automations in HG. You can do similar with the Arduino and use the Serial Helper to feed data back to HG
Title: Re: Stock Ticker Widget
Post by: Tuicemen on February 19, 2020, 07:06:48 PM
Soxfan1966 has shared his efforts on this on the homegenie.cub forum. Posting his creations here helps show the x10 community that even new users to the PiX10Hub and HG can create cool widgets. Sharing creations on all fourms with HG info that Soxfan1966 belongs to would benifit users that don't frequent here.
Title: Re: Stock Ticker Widget
Post by: petera on February 19, 2020, 07:22:00 PM
Soxfan1966 has shared his efforts on this on the homegenie.cub forum. Posting his creations here helps show the x10 community that even new users to the PiX10Hub and HG can create cool widgets. Sharing creations on all fourms with HG info that Soxfan1966 belongs to would benifit users that don't frequent here.

Indeed but coding would be a bit beyond your basic user here. Hopefully his coding skills can be used to exploit some of the more advanced protocols HG provides. There’s a number of closed Discourse groups using HG in more advanced projects he could avail of.
Title: Re: Stock Ticker Widget
Post by: soxfan1966 on February 20, 2020, 06:35:03 AM
Thanks for the feedback all.  I will indeed take a look at the Pi Sense Hat weather project, that is something I have been thinking about (a personal weather station).   I will also play around with the widgets some more and be sure to share my results here and on the HomeGenie Club forums as well.
Title: Re: Stock Ticker Widget
Post by: soxfan1966 on March 02, 2020, 01:37:59 PM
I made some tweaks to the Stock Widget while I was working on the sports scores widget


Title: Re: Stock Ticker Widget
Post by: soxfan1966 on March 07, 2020, 09:45:43 AM
Here is an updated version, 1.1 of the program and widget