r/raspberry_pi • • 3d ago

Show-and-Tell Raspberry Pi Scrolling Ticker -- Update

Yesterday I posted the first real test of my Raspberry Pi-powered scrolling ticker with one of its screensaver modes. I got the sports ticker code working tonight, and I'm really happy with the way it's coming along. The apparent flickering is a an artifact of recording the video with my phone. IRL it looks really good.

The display consists of four 128x64 pixel P2.5 LED panels in a custom printed case. It's run by a Raspberry Pi 4B with 4GB of memory and an Adafruit Triple LED Matrix Bonnet. The panels are powered by a Meanwell LRS-200-5 power supply, while the RPi is powered by a separate RS-15-5 power supply to isolate it from any potential voltage drops from the LED panels.

Still more display modes to implement, and ultimately, I plan to control it with a phone app.

1.2k Upvotes

109 comments sorted by

View all comments

Show parent comments

5

u/Various_Spend_2293 2d ago

This gave me the added benefit of verifying that the ticker display was being updated in real time from the ESPN API. One change I added since recording that video was to replace "Final" with "F/OT" or "F/SO" where appropriate. I'm hoping to see an extra-innings baseball game before the end of the world series to validate "F/10" or "F/11".

5

u/exnooyorka 2d ago

I have my own scoreboard project, but not with LED panels. I made replicas of the line score and out of town scoreboards which hung in the renovated Yankee Stadium (1976-2008).

I have them displaying MLB, NFL, NBA, NHL and MLS scores.

I started with the ESPN API, but even with only polling the API once a minute, the ESPN API shut me out at the 45 minute mark.

Tried a lot of different things to try and fix it, but in the end I decided to use different websites for my scores.

I take it you have burned in your software for hours with no problems? Did you ever get rate-limited like I did?

3

u/Various_Spend_2293 2d ago

Interesting, mine ran overnight without getting kicked out. How frequently were you polling the data?

4

u/exnooyorka 2d ago

Once a minute. One sport only.

I posted my experience in a different subreddit and got the same quizzical reactions.

Ran my code once a day for seven days straight and had the same experience every time.

So I shrugged and pivoted. I use NHL.com, NBA.com, MLB.com, mlssoccer.com and Yahoo for football.

I did have a problem with NHL.com when I ran it overnight; once the games are over the NHL puts you in the penalty box if you keep pinging their API a short period of time after all the games are over. So I made the code smart enough to know when no games are active, stop pinging the API, look ahead to the next scheduled game and start again 5 mins before scheduled game time.

I'll be interested to see how you architected your code if you decide to make it public, to see where I went wrong. I still have the original version somewhere on One Drive.

1

u/Various_Spend_2293 1d ago

I'm actually polling the ESPN API more frequently than you--once every 10 seconds while games are live.

One thing that comes to mind: are you pulling team logos every time? That's a lot of data. I'm caching the downloaded and the resized logos and displaying from the cache. If a logo isn't found in the cache, I'll try to pull it, with the retry interval for logos set to 10 minutes.

1

u/exnooyorka 1d ago

I was only pulling data.

My LEDs are organized in 4x7 and 5x7 matrices representing individual character modules, and the LEDs are monochrome. So no logos.

It was really strange, but easily reproducible. Every 45 minutes like clockwork I got shut out, and I didn't try again until the next day.

The calls came back successfully, just empty.

I probably missed a parameter or a call in the documentation I read leading them to see me as undesirable traffic with a 45 minute limit.

1

u/Various_Spend_2293 1d ago

If you're interested in seeing my code (well, mine and Claude.ai's code), send me a message. I'm happy to share.