View weather2.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urequests as requests | |
import json | |
import network | |
import secrets | |
from picographics import PicoGraphics, DISPLAY_GALACTIC_UNICORN as DISPLAY | |
from galactic import GalacticUnicorn | |
import jpegdec, math, ntptime, time | |
import _thread | |
blink=0 |
View weather.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try: | |
import urequests as requests | |
except: | |
import requests | |
try: | |
import ujson as json | |
except: | |
import json |
View mastocloud.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import json | |
import time, argparse | |
import matplotlib.pyplot as py | |
from wordcloud import WordCloud,STOPWORDS | |
from PIL import Image | |
import numpy as np | |
parser = argparse.ArgumentParser() | |
parser.add_argument("-a", "--account", help="Handle to use", required=True) |
View main.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Based on | |
# Scroller Demo | |
# Kevin McAleer May 2022 | |
# Additional code by Vincent Willcox September 2022 | |
import network | |
import secrets | |
import time | |
import urequests | |
from scroller import Scroller |
View wordcloud.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import tweepy | |
import time | |
import matplotlib.pyplot as py | |
from wordcloud import WordCloud,STOPWORDS | |
from PIL import Image | |
import numpy as np | |
import argparse | |
parser = argparse.ArgumentParser() | |
parser.add_argument("-t", "--twittername", help="Twitter handle to use", required=True) |
View rpilocator.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from bs4 import BeautifulSoup | |
import requests | |
import re | |
headers = { | |
'User-Agent': 'your-user-agent-here' | |
} | |
class ReadRss: |
View speedtest_pg_h_round.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import json | |
import sys | |
import time | |
import pygame | |
import pygame.gfxdraw | |
import math | |
from pygame.locals import * | |
class Gauge: |
View speedtest2.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import json | |
import sys | |
import time | |
proc = subprocess.Popen(['/home/pi/speedtest -p -f json'], shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE) | |
for i in proc.stdout: | |
output = proc.stdout.readline() |
View speedtest.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import json | |
stdoutdata = subprocess.getoutput("speedtest -f json") | |
#print(stdoutdata.split()[0]) | |
results = json.loads(stdoutdata) | |
for key in results: | |
download = results["download"]["bandwidth"] | |
upload = results["upload"]["bandwidth"] |
View nasa-windows-toast-and-caption.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import requests | |
import ctypes | |
from PIL import Image | |
from PIL import ImageFont | |
from PIL import ImageDraw | |
from win10toast import ToastNotifier | |
url = "https://api.nasa.gov/planetary/apod?api_key=" | |
os.environ['NO_PROXY'] = 'nasa.gov' |
NewerOlder