Background

“Bad Apple!!” is a popular Japanese song originally released in 2007 as part of the Touhou soundtrack, which later gained widespread recognition through an iconic fan-made music video released in 2009. The video is completely in black-and-white, which then inspired hackers across the world to "remix" the video by playing it in unconventional places. Here's an example played on Desmos and on YouTube captions

My humble offering to the many, many Bad Apple remixes out there is this version played across 4-6 windows on Google Calendars. Given that each day has 24 hours, and each week has 7 days, 6 windows will grant a 21 x 48 resolution screen to render the music video on.

So, can your calendar play Bad Apple? It'll take 20 in-calendar years (at 5 fps), but the answer is "of course".

How we built it

The program is written mostly in Python. I used the Google Calendar API to add calendar events across 6 different calendars, then the video is recorded in one-shot by using Playwright to open and position 6 windows and click the "Next week" button on the calendars repeatedly.

Because all we are doing is scrolling through weeks in the calendar, the program can actually be played at near real-time at lower resolutions (ie 4 calendar screens, 2 fps). The sacrifice is definitely the resolution and smoothness of the video, but in theory anyone can download my code, authenticate into Google, and they can now run Bad Apple on their computer too.

Challenges we ran into

Sending too many calendar API requests. One of my Google accounts got blocked at some point. It also takes a long time for all the calendar events to get added (Adding events and then recording took 6-7 hours of the hackathon alone)

Reflection

Despite the horrible task of waiting, this was a fun project to work on. I hope the end result looks as beautiful as it does to me.

What's next for Calendar Apple

Clean up the scripts I used, potentially make them more accessible and portable so that other people can run this too.

Built With

Share this project:

Updates