# Background image in custom panel

**URL:** <https://community.tempest.earth/t/background-image-in-custom-panel/27067>\
**Category:** WeatherFlow PiConsole\
**Created:** [April 14, 2025, 12:42am UTC](https://community.tempest.earth/t/background-image-in-custom-panel/27067 "2025-04-14T00:42:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![stevecody](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@stevecody](https://community.tempest.earth/u/stevecody)\
**Post date:** [April 14, 2025, 12:42am UTC](https://community.tempest.earth/t/background-image-in-custom-panel/27067/1 "2025-04-14T00:42:32Z")

</div>

Hi @peter, any thoughts on this?

Awhile back, when I was first working on the Big Temp mod, I had a custom background of an animated gif. This worked for me for quite awhile until I upgraded my version of the Raspbian OS. I’m on Bookworm now, and can’t get a gif to load. I can load a png, but not the animated gif.

Here is the code I’m using for the png. When I replace the file with a .gif, I get the error.

The error just says “[ERROR] [Image] Error loading \<user/RadarGIF/radar.gif\>”

The file is present and when it can’t find the file, it says Not found.

customPanels.kv  
:  
PanelBackground:  
\_panelTitle: ‘RadarGIF’  
Image:  
id: RadarGIFBackground  
source: ‘user/RadarGIF/radar.png’  
size\_hint: (1,1)  
keep\_ratio: 1  
allow\_stretch: 0

:  
PanelButton:  
text: ‘RadarGIF’  
on\_release: app.CurrentConditions.switchPanel(self)

customPanel.py  
class RadarGIFPanel(panelTemplate):  
def **init** (self, \*\*kwargs):  
super(). **init** (\*\*kwargs)  
Clock.schedule\_interval(self.updateImage, 600)

```
def updateImage(self,dt):
    self.ids.RadarGIFBackground.reload()

```

class RadarGIFButton(RelativeLayout):  
pass

-rw-r–r-- 1 pi pi 414744 Apr 13 16:40 radar.gif

---

<div class="post-metadata">

**Author:** ![peter](https://sea2.discourse-cdn.com/flex020/user_avatar/community.tempest.earth/peter/32/1365_2.png) [@peter](https://community.tempest.earth/u/peter)\
**Post date:** [April 14, 2025, 7:42am UTC](https://community.tempest.earth/t/background-image-in-custom-panel/27067/2 "2025-04-14T07:42:16Z")

</div>

Take a look at this thread here: [https://groups.google.com/g/kivy-users/c/isIwfZrfyH0](https://groups.google.com/g/kivy-users/c/isIwfZrfyH0)

It sounds like there may be an issue loading gif files in particular formats. A suggested workaround in the second post is to animate a zip file containing the individual images

---

<div class="post-metadata">

**Author:** ![stevecody](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@stevecody](https://community.tempest.earth/u/stevecody)\
**Post date:** [April 14, 2025, 9:26am UTC](https://community.tempest.earth/t/background-image-in-custom-panel/27067/3 "2025-04-14T09:26:39Z")

</div>

Thank you for the thread. I’ll use that to explore some options.

I ended up creating my own animation process. I download the weather radar gif every 10 minutes and extract the frames into 10 png files. I set the background image to radar.png, and in the background, a script is updating a symlink to the radar.png every 2 seconds to iterate through the frames. I set the refresh rate on the panel reload image to every 2 seconds. It gives the appearance of animation pretty well.
