Heads up - Debian 13 (Trixie) will cause issues with the depreciated textwidth calls. I have finished an updated script, but I want to test it fully before publishing. All of the manual settings I tried looked pretty good. Precipitation, Feels Like, and Severe Weather Alerts are all using new methods of centering. If everything looks good in a couple weeks, I’ll get it uploaded and toss a comments out here.
New code is up on GitHub ![]()
Does anyone sell these units for the non-talented observers.
I don’t sell my work just for liability and stuff like that. However, I would definitely help answer questions along the way as I have done here. DM me and we can chat further as to not ping everyone on the thread. I’d be happy to help you through the process and provide you with an STL for the back of the frame - that STL can be printed at most libraries for a nominal fee if you do not have a 3D printer.
Thanks for the quick reply. I don’t think I have the ambition at the moment. Rehabbing a new knee is more than project enough for this old guy and moving from a Win10 to new Win11 computer is more than enough “programming” for me.
After months of sitting on the code, I’ve finally completed the 9.7” display that integrates IQAir AQI data. Going into this project, I expected a similar experience to the 7.5” Waveshare screen. Boy was I wrong. Challenges on this setup not only include the massive ribbon cable at the bottom of the screen, the screen offset, general fragility of the screen - but also that there are no provided Python drivers. Everything that operates this screen is in C. If any of you decide to go the route of an IT9851 driven screen, this is the key: GitHub - fittingIntelligence/IT8951_python_works: Driver for the IT8951 e-paper controller on Raspberry Pi
This legend wrote a python based driver suite using a Cython wrapper. This was hands down a life saver for me, the guy who got over his head quickly ![]()
I do have a couple tweaks I plan on doing to the code, but overall I’m extremely pleased with the results and the speed of the screen.
Edit: I suck at spelling ![]()
The extra real estate sure is nice.
Can confirm. The refresh difference is insane, it’s no more than a blink of the eye.
Loosely related - I’m still using my forked version of your original nice work with my tweaks, but I thought I’d mention that I’ve run into occasional issues with the GPIO bus being in use which crashes the app. I eventually figured out how to get around this in how I call things from cron, so I thought I’d pass the info along in case you have run into this too…
2-57/5 * * * * cd /home/pi/Tempest-7.5-E-Paper-Display && timeout 60 python3 weather-cron.py >/tmp/program.out 2>&1
My variant called ‘weather-cron.py’ runs like your original one from cron. I’d previously altered mine to try to run as a program that is exec’d then sleeps between refreshes, but I went back to the simple way to do it. Redirecting the output and error output to a file definitely helps a lot when something goes wrong and I need to tweak the code a little. Most frequently it’s the forecast having changing wording that the code doesn’t figure out how to assemble the icon name from. The list of icons also misses a lot of things that the NWS forecast says is coming, so I had to do a little defensive coding around that.
No lockups or failures since I added the ‘timeout 60’ thing before calling the program with python3. Cool.
I have an interesting new logic block I’ve added to the code. I’ve found that on occasion the pi running the screen just completely drops wifi. I can’t SSH to it and the screen deathloops because of it. What I am testing out is an error counter. A variable simply increments upon a connection issue and after a defined number of attempts is hit, the system will reboot and a reboot flag is set. Upon coming back up, if the connection fails an additional number of times and the reboot flag is set, the screen will be reinitialized and the pi shutdown safely. If the screen connects properly after reboot, the flag is reset and it continues on like normal. This will hopefully prevent the deathloops and protect the screen. I’m going to test it out for a while to check for issues on both the 7.5” screen and the 9.7”. Should everything test out, I’ll get the code on GitHub updated.
All pi zero that I’ve ever seen had this issue. I used to add a script to my pi to self-help broken wifi which used to work ages ago (link) but switching to anything other than a zero made the issue go away for me, FWIW.
Hi all!
It’s been a minute. However, I have a pretty large update in the testing phase right now. I have solved the looping issues completely. I have built in a process to reboot the device in the event WLAN drops, but I have not seen this happen once in either the Pi 3B+ or Pi Zero 2. From what I have found, most of these were due to random JSON keys falling off on refresh. This caused the permanent loop. To address this, I have created a faithful nod to the Strongbad virus email from Homestar Runner. Eventually I’ll probably make this a meme mode thing, but that’s a task for another day. Anyhow, this will pop and wait 10 minutes rather than the normal 5 to decrease hits on the API.
I have also redesigned the entire setup. After building the 9.7” screen, I was really struggling with current conditions being split. As a result, I have combined all dynamic data in the left pane, and the High/Low along with newly added sunrise/sunset (more or less static data) has been moved to the center. Here’s the part I enjoy most. I have added a new API call for moon phases. The bottom right box, the black box, was completely under utilized with the exception of storm data. UPDATED time is now small at the bottom, an extremely nice US Navy astronomical API is called with coordinates to populate the current phase.
As for meme mode, I have added the Ice King from Adventure Time with a status of “Embrace the Freeze” on a configurable feels like temp. I have it currently set to -10 as it does not get crazy cold here. This value is noted at the top of the script for easy edit. All other dynamic data is still in place with NWS alerts, rain totals, and lightning data. I have also increased logging with timestamps for better troubleshooting in python.log in the display directory. In order to utilize this, you will need to run python, however you are calling it via service, script, etc, as “python -u” to not buffer. If you use the buffer, the log only updated upon process termination. I’m going to run this build for a while before uploading, I just wanted to give those who use it a preview and to solicit any feedback for what you’d like to see or if there’s something that doesn’t look quite right.
I like that left hand side just being a single column, that works really well. Looking forward to running this when you upload the code.
2.0 is live. I’ve renamed the project and added all the required files.
This does require a couple additional python modules for timezone conversion (pytz) and string replacement (re).
Going forward, I want to do some more specific error screens with meme mode integrations, but I’ll get there as I can.
Hi all!
Boy have I learned a thing or two with lunar phases ![]()
Today, at least where I live in the midwest, the APIs dropped the moonset key. I had to go digging and found this is due to moonset falling past 12am. Originally, I just added an additional lookup for T+1 to solve the issue. Well that’s not going to be a long term free solution because that will double the hits per day. While that is not an issue for people with 1 display, I am also running the 9.7” monster so 48 per screen will not remain a free option. What I did was take the backup to the US Naval Observatory and pull the moonset time from there in the event this occurs.
I also worked with the guy who runs Free Astro API to clarify the eclipse data that is bering returned. I’ve put in a new try/except block to catch when the extra keys are missing as to not immediately cause failover to the Navy Observatory.
Thanks for riding along with me on this journey, more stuff to come. v2.0.1 is out on GitHub with these fixes in place. If you’ve already updated to the 2.0, just grab weather.py and you’re good to go.
Another late night coding. Fixed a bunch of bugs specifically around moonrise/moonset. The pytz module requirement has been removed. Version 2.1 is currently up for download.
Got it up and running, one minor detail is that the “template.png” file still reflects the original layout. Which was fine with me as I was able to come up with a couple other backgrounds that I liked. I’ve attached them both here along with some photos of how they look on screen.
Template A
Template B
Those look great - thanks for keeping me honest on the template. In all the madness I had with bug fixes, apparently I forgot the biggest piece ![]()
I corrected that on git for the original - definitely like the rounded edges you came up with!
They’re fair game if you want to include them, I figured that’s the least I could do to support the work here.
I’d be down with that - do you have a github handle that I could at minimum add you as a contributor? I’ll build in some code for template options based on what you made.







