This Gist is about how I use PyAudio, NumPy, and Matplotlib to plot freqency spectrum of system sound or microphone.
You can read this blog post for more detail or watch this video:
""" | |
Convert every .sla to a pdf in a specified directory. | |
This script can only be run from within [scribus](http://http://scribus.net). | |
""" | |
import os | |
work_dir = #you have to explicitly tell scribus where your working directory is. | |
filenames = os.listdir(work_dir) |
This Gist is about how I use PyAudio, NumPy, and Matplotlib to plot freqency spectrum of system sound or microphone.
You can read this blog post for more detail or watch this video:
/** | |
* USB HID Keyboard scan codes as per USB spec 1.11 | |
* plus some additional codes | |
* | |
* Created by MightyPork, 2016 | |
* Public domain | |
* | |
* Adapted from: | |
* https://source.android.com/devices/input/keyboard-devices.html | |
*/ |
ConsumerKey:consumerSecret
in Base64 ; you can use https://codebeautify.org/base64-encode to encode itBASE64KEY+:+SECRET
by the generated Base64 and run the following command :curl -k -d "grant_type=client_credentials" -H "Authorization: Basic BASE64KEY+:+SECRET" https://opendata-api.stib-mivb.be/token
UPDATED 22.11.2022
It's been two years since the last update, so here's the updated working script as per the comments below.
Thanks to BryanHaley for this.
setInterval(function () {
video = document.getElementsByTagName('ytd-playlist-video-renderer')[0];
video.querySelector('#primary button[aria-label="Action menu"]').click();
#!/bin/bash | |
# Cloudflare as Dynamic DNS | |
# From: https://letswp.io/cloudflare-as-dynamic-dns-raspberry-pi/ | |
# Based on: https://gist.github.com/benkulbertis/fff10759c2391b6618dd/ | |
# Original non-RPi article: https://phillymesh.net/2016/02/23/setting-up-dynamic-dns-for-your-registered-domain-through-cloudflare/ | |
# Update these with real values | |
auth_email="email@example.com" | |
auth_key="global_api_key_goes_here" | |
zone_name="example.com" |
# Note: You really should not use this. | |
# You can easily convert your app | |
# to use Quart by using async+await | |
# and then use loop.create_task(bot.start(...)) | |
# before using app.run. | |
from threading import Thread | |
from flask import Flask | |
from functools import partial | |
from discord.ext import commands |
<!--XSL style sheet to convert EESCHEMA XML Partlist Format to grouped CSV BOM Format | |
Copyright (C) 2014, Wolf Walter. | |
Copyright (C) 2013, Stefan Helmert. | |
Copyright (C) 2018, Kicad developers. | |
Copyright (C) 2019, arturo182. | |
GPL v2. | |
Functionality: | |
Generation of JLCPCB PCBA compatible BOM |
/* | |
Motion-Sensing Warning Lights | |
This sketch will wait for a high input on D2 from the PIR motion | |
sensor, and then flash WiFi-connected lights to alert the room. | |
Circuit: | |
HC-SR501 PIR motion sensor attached, input on digital pin 2 | |
created 30 July 2020 |