Skip to content

Instantly share code, notes, and snippets.

Avatar

Richard Osterloh rosterloh

View GitHub Profile
@jfurcean
jfurcean / COVID-19-Vaccine-MatrixPortal.py
Last active Jan 21, 2021
Display COVID-19 Vaccine Data on a Adafruit MatrixPortal
View COVID-19-Vaccine-MatrixPortal.py
# SPDX-FileCopyrightText: 2021 John Furcean
# SPDX-License-Identifier: MIT
import board
import busio
from digitalio import DigitalInOut
import adafruit_requests as requests
import adafruit_esp32spi.adafruit_esp32spi_socket as socket
from adafruit_bitmap_font import bitmap_font
from adafruit_esp32spi import adafruit_esp32spi
@kongmunist
kongmunist / face_tracking_ppg.py
Last active Dec 28, 2020
Webcam Photoplethysmyography
View face_tracking_ppg.py
# Must be run in console to work properly
import numpy as np
import cv2
import time
from scipy import signal
import matplotlib.pyplot as plt
import matplotlib
import threading
import scipy.signal as sig
@jfurcean
jfurcean / mute-button.py
Last active Nov 23, 2020
CircuitPython Mute Button
View mute-button.py
# SPDX-FileCopyrightText: 2020 John Furcean
# SPDX-License-Identifier: MIT
import time
import board
from digitalio import DigitalInOut, Direction, Pull
import usb_hid
from adafruit_hid.keyboard import Keyboard
from adafruit_hid.keyboard_layout_us import KeyboardLayoutUS
@dglaude
dglaude / Things_to_do.txt
Last active Nov 27, 2020
EnviroPlus-FeatherWing TODO
View Things_to_do.txt
Idea about the example
----------------------
simpletest example could be only present in each individual library.
More complex example that use the plotter could be in the main library for EnviroPlus-FeatherWing.
Move from gas to MICS6814
-------------------------
Replace gas.py from library with the new library https://github.com/pimoroni/Pimoroni_CircuitPython_MICS6814
@jfurcean
jfurcean / COVID-19-RGB-Matrix.py
Created Nov 9, 2020
COVID-19 Data - RGB Matrix
View COVID-19-RGB-Matrix.py
# SPDX-FileCopyrightText: 2020 John Furcean
# SPDX-License-Identifier: MIT
import board
import busio
from digitalio import DigitalInOut
import adafruit_requests as requests
import adafruit_esp32spi.adafruit_esp32spi_socket as socket
from adafruit_bitmap_font import bitmap_font
from adafruit_esp32spi import adafruit_esp32spi
View alab-ph-sensor.js
/* eslint-disable */
const zigbeeHerdsmanConverters = require('zigbee-herdsman-converters');
const getKey = (object, value) => {
for (const key in object) {
if (object[key] == value) return key;
}
};
const bind = async (endpoint, target, clusters) => {
for (const cluster of clusters) {
@jfierstein
jfierstein / check_mail.py
Created Apr 22, 2019
Python script for scraping Gmail inbox for Amazon package emails with today as delivery date (written for Home Assistant)
View check_mail.py
import sys, smtplib, time
import datetime
import imaplib
import email
import json
EMAIL = "<YOURADDRESS>@gmail.com"
PWD = "<YOURSECRETPASSWORD>"
SMTP_SERVER = "imap.gmail.com"
SMTP_PORT = 993
@mcfrojd
mcfrojd / Shield_Intents.MD
Last active Jan 24, 2021
Working INTENTS to use with Community Hass.io Add-ons: Android Debug Bridge for your Nvidia Shield TV
View Shield_Intents.MD

Latest Update 2020-11-05 : Added @clapbr way to add search (Netflix & others) to HA Gui

Credits and thanks: Home Assistant Forum users & Github users: @ocso, @wiphye, @teachingbirds, @tboyce1, @simbesh, @JeffLIrion @ff12 @rebmemer @siaox @DiederikvandenB @Thebuz @clapbr


Starts specific Twitch stream (If stream is live)

{"entity_id" :"media_player.shield", "command": "am start -a android.intent.action.VIEW -d twitch://stream/frenck"}
{"entity_id" :"media_player.shield", "command": "am start -a android.intent.action.VIEW -d twitch://stream/drzzs"}

Start apps on your Shield from Home Assistant

@rsnk96
rsnk96 / multiprocessing_cv.py
Last active Sep 9, 2020
Outline of a parallelized video processing code
View multiprocessing_cv.py
def process_video(group_number):
cap = cv2.VideoCapture("input_file.mp4")
cap.set(cv2.CAP_PROP_POS_FRAMES, frame_jump * group_number)
proc_frames = 0
out = cv2.VideoWriter("output_{}.avi".format(group_number), ...)
while proc_frames < frame_jump:
ret, frame = cap.read()
# ... DO SOME STUFF TO frame ... #
proc_frames += 1
out.write(frame)