Skip to content

Instantly share code, notes, and snippets.

View SebastiaanDeJonge's full-sized avatar

Sebastiaan de Jonge SebastiaanDeJonge

View GitHub Profile
@SebastiaanDeJonge
SebastiaanDeJonge / keep-everything.sh
Last active June 1, 2020 13:43
A quick bash script to git-keep all subdirectories of the given directory by adding .gitkeep when no contents are present.
#!/usr/bin/env bash
files_created=0
echo_usage()
{
echo "Usage: keep-everything.sh /path/which/to/look/in"
echo ""
}
echo_green()
@SebastiaanDeJonge
SebastiaanDeJonge / wemos-d1-flash-micropython.md
Last active February 2, 2019 19:08
wemos-d1-flash-micropython.md

WeMos D1 - MicroPython Flash Guide

This little guide is meant to help you through flashing your WeMos D1 with the MicroPython firmware.

1. Download MicroPython Firmware

Go to http://micropython.org/download#esp8266 and download the latest version of the micropython firmware.

2. Enable Flash Writing

In order to write to the Flash memory of the D1, pin D3 must be connected to GND.

@SebastiaanDeJonge
SebastiaanDeJonge / arduino-super-annoyer.ino
Created June 6, 2021 19:14
arduino-super-annoyer.ino
/**
* This little projects creates random sounds through the piezo speaker. The range
* (in Hz) can be defined at the top of the code (frequencyLowerBound,
* frequencyUpperBound). The interval/duration of each tone is determined by the
* current state of the potentiometer. As the potentiometer is turned open the tone
* slows done.
*
* Requirements:
* - Arduino Nano/Uno
* - Solderless breadboard
/**
* This sketch will let three LED strips blink based on the intensity of sound input. My example
* used 12V LED strips which required an external power source and some transistors to hook up
* if you have something to hook up to the Arduino directly then you can use that instead of
* course and omit/change the transistors/resistors.
*
* Requirements:
* - Arduino Nano/Uno (or equivalent)
* - Power source for the Arduino (i.e. 9V battery or USB)
* - Digital microphone module (i.e. LM393)