Skip to content

A PowerShell script that automatically downloads the latest satellite image from Himawari-8 (Japan's weather satellite) and sets it as your desktop wallpaper. The image is fetched based on the current UTC date and hour.

Notifications You must be signed in to change notification settings

shawnleehere/wallpaper-setter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Wallpaper Setter

A PowerShell script that automatically downloads the latest satellite image from Himawari-8 (Japan's weather satellite) and sets it as your desktop wallpaper. The image is fetched based on the current UTC date and hour.

Features

  • Fetches satellite images from the Himawari-8 satellite.
  • Downloads the image based on the current UTC date and time.
  • Saves the image to a specified directory on your computer.
  • Automatically updates your desktop wallpaper.
  • Logs each wallpaper change, including the image size and any errors, to a log file.

Requirements

  • PowerShell: The script is written for PowerShell (available on Windows by default).
  • Internet connection: The script fetches satellite images from the Himawari-8 API, requiring internet access.

Usage

  1. Install it:

    • Open PowerShell.

    • Navigate to the script directory.

    • Run the script by executing:

      .\install.ps1
  2. What the script does:

    • Downloads the latest satellite image based on the current UTC date and hour from Himawari-8.
    • Saves the image in a subdirectory under Pictures\himawari\yyyy\MM\dd\HH.png.
    • Sets the downloaded image as your desktop wallpaper.
    • Logs all activities (successful downloads, errors, etc.) to a log file (wallpaper_change_log.txt).

Customizing

  • Log File Location: The log file is saved under $env:USERPROFILE\Pictures\himawari\wallpaper_change_log.txt. You can modify this path in the script if you prefer a different location for the log.
  • Minimal Image Size: The script only downloads images if the Content-Length (image size) is above the defined threshold (5,000 bytes by default). You can change the $minimalContentLength variable to set a different threshold.

Troubleshooting

  • No image downloaded: If the image is too small (below the minimal size threshold), the script will log this and not update the wallpaper.
  • Network Errors: If there is an issue downloading the image, the error message will be logged.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

A PowerShell script that automatically downloads the latest satellite image from Himawari-8 (Japan's weather satellite) and sets it as your desktop wallpaper. The image is fetched based on the current UTC date and hour.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published