The Photo Viewer requires an internet connection as well as an Adafruit IO username and authentication key. If you haven't already done so, follow the directions on the Create Your settings.toml File page then return here. You must have all of the following values filled in inside of the settings.toml file.
CIRCUITPY_WIFI_SSID = "your_wifi_ssid" CIRCUITPY_WIFI_PASSWORD = "your_wifi_password" ADAFRUIT_AIO_USERNAME = "your_aio_username" ADAFRUIT_AIO_KEY = "your_aio_key"
Specify Tag Search Term
By default the project searches for posts containing the "cats" hashtag on pixelfed.social. The search term can be easily modified by changing the value of the search_tag variable near the top of code.py.
For example to change it to search for "birds" instead:
# what kind of images to search for search_tag = "birds"
Display Photos
The code will download a cached copy of the JSON tag search results, then automatically begin showing photos from the results on the display. The photos are resized using the Adafruit IO image converter service to fit onto the 320x240 resolution display. The small display size was chosen to avoid memory errors from larger image files.
Every few minutes a new photo will be shown. Once per hour, it will fetch the latest search results for the specified tag. The order of the images is randomized so it won't be the same every time.
Page last edited November 05, 2025
Text editor powered by tinymce.