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
#!/usr/bin/python3 | |
import RPi.GPIO as GPIO | |
import math, sys, os | |
import subprocess | |
import socket | |
GPIO.setwarnings(False) | |
GPIO.setmode(GPIO.BCM) | |
GPIO.setup(18, GPIO.IN, pull_up_down=GPIO.PUD_UP) | |
GPIO.setup(23, GPIO.IN, pull_up_down=GPIO.PUD_UP) |
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
#!/bin/bash | |
command -v pv >/dev/null 2>&1 || { echo "Dieses Script benötigt das Programm pv." >&2; exit 1; } | |
# Shell Script for creating a pi sd card iwth the latest Rasbian | |
# Author <simon.jenny@me.com> Simon Jenny | |
# | |
# ------------------------------------------- | |
if [ "$1" == "" ]; then | |
echo "Drive Folder Parameter missing!" | |
echo "Usage : create-a-pi DRIVE (eg /dev/disk2)" | |
echo "Here are all your mounted drives:" |
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
#!/usr/bin/python | |
import CHIP_IO.GPIO as GPIO | |
import math, sys, os | |
import subprocess | |
import socket | |
GPIO.setup("XIO-P7", GPIO.IN); | |
GPIO.setup("XIO-P6", GPIO.IN); | |
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
#!/usr/bin/env bash | |
ARRAY=() | |
var=1 | |
rows=$(curl --silent "https://www.lego.com//service/biservice/search?fromIndex=0&locale=en-US&onlyAlternatives=false&prefixText=${1}"|jq -r '.products[0].buildingInstructions[].pdfLocation') | |
for row in $rows; | |
do | |
ARRAY+=(${row}) | |
echo "$((var++)). ${row}" | |
done | |
echo -ne "Welche Anleitung soll ich öffnen? " |
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
#!/bin/bash | |
if [ -z "$1" ] | |
then | |
echo "Commit Reason is empty" | |
exit 0 | |
fi | |
~/Development/./clean.sh | |
git add . | |
git commit -m "$1" | |
git push |
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
# -*- coding: utf-8 -*- | |
import os, pygame, random | |
pygame.init() | |
pygame.mouse.set_visible(False) | |
BACKGROUND = (0,0,0) | |
INTERVAL = os.getenv('INTERVAL', 60) | |
IMAGEFOLDER = os.getenv('IMAGEFOLDER', 'images') |
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 explorerhat, time, random | |
import RPi.GPIO as GPIO | |
import cwiid | |
import os | |
import sys | |
speed = 50 | |
wii_connected = False | |
def connect_wii(): |
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 explorerhat, time, random | |
import RPi.GPIO as GPIO | |
import cwiid | |
mode = 0 | |
back = explorerhat.analog.three | |
front = explorerhat.analog.four | |
speed = 50 | |
wii_connected = False |
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
# -*- coding: utf-8 -*- | |
# Download c64 Font : https://www.ffonts.net/Pet-Me-64.font | |
# Install Efa : https://simonjenny.dev/efa | |
# STATION="Allschwil, zum Sporn" python c64.py | |
import time, os, pygame, subprocess | |
from datetime import datetime | |
STATION = os.getenv('STATION', 'Basel, Marktplatz') |
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
#!/bin/bash | |
/usr/bin/youtube-dl -i -f 'bestaudio[ext=m4a]' --write-thumbnail --embed-thumbnail \ | |
--metadata-from-title "%(title)s" \ | |
--metadata-from-title "%(artist)s" \ | |
--output '/%(playlist_title)s/%(title)s/%(title)s.%(ext)s' \ | |
--download-archive "$1.txt" \ | |
--write-info-json \ | |
-q https://www.youtube.com/playlist?list=$1 |
OlderNewer