Skip to content

Instantly share code, notes, and snippets.

Troy Dack tdack

Block or report user

Report or block tdack

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@tdack
tdack / create-ovpn.sh
Last active Aug 9, 2016
Create Feral Hosting .ovpn for iOS OpenVPN client
View create-ovpn.sh
#!/bin/bash
NAME=$1
FERAL_SERVER=$2
KEYSTORE=./keys
CA=$(< ${KEYSTORE}/ca.crt)
CERT=$(< ${KEYSTORE}/${NAME}.crt)
KEY=$(< ${KEYSTORE}/${NAME}.key)
TLS_AUTH=$(< ${KEYSTORE}/tls-auth.key)
OUTPUT=./${NAME}.ovpn
@tdack
tdack / build_kernel.sh
Last active Sep 30, 2018
Build the kernel for the Next Thing Co C.H.I.P.
View build_kernel.sh
#!/bin/bash
# Desktop build
MAKE="make -j 4 ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-"
# C.H.I.P. build
#MAKE="make"
CDIR=$PWD
LINUX=$CDIR/CHIP-linux
WIFI=$CDIR/RTL8723BS
View config
#
# Automatically generated file; DO NOT EDIT.
# Linux/arm 4.4.11 Kernel Configuration
#
CONFIG_ARM=y
CONFIG_ARM_HAS_SG_CHAIN=y
CONFIG_NEED_SG_DMA_LENGTH=y
CONFIG_ARM_DMA_USE_IOMMU=y
CONFIG_ARM_DMA_IOMMU_ALIGNMENT=8
CONFIG_MIGHT_HAVE_PCI=y
@tdack
tdack / README.md
Created Jun 12, 2016
Custom handlebars helpers for Ghost, as an app
View README.md
@tdack
tdack / readme.txt
Created May 8, 2016
Buildroot config for OrangePi Plus
View readme.txt
# board/orangepi/orangepi_plus/readme.txt
OrangePi Plus
Intro
=====
This default configuration will allow you to start experimenting with the
buildroot environment for the OrangePi PC. With the current configuration
it will bring-up the board, and allow access through the serial console.
@tdack
tdack / io.adafruit.com-bridge.conf
Last active Jul 26, 2019
Bridge Mosquitto MQTT broker to io.adafruit.com MQTT broker to use with io.adafruit.com
View io.adafruit.com-bridge.conf
# Connection name
connection adafruit
# Secure SSL/TLS
address io.adafruit.com:8883
# adjust path as approriate to point to directory with PEM encoded .crt CA files
bridge_capath /etc/ssl/certs/
# Insecure
#address io.adafruit.com:1883
@tdack
tdack / main.py
Created Jan 12, 2016
Kivy custom properties on a widget
View main.py
import kivy
kivy.require('1.9.0')
from kivy.app import App
from kivy.uix.widget import Widget
from kivy.uix.button import Button
from kivy.properties import NumericProperty, ObjectProperty
import RPi.GPIO as GPIO
@tdack
tdack / console.log
Last active Jan 10, 2016
Kivy Raspberry Pi installation
View console.log
pi@raspberrypi ~ $ sudo apt-get install libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev \
pkg-config libgl1-mesa-dev libgles2-mesa-dev \
python-setuptools libgstreamer1.0-dev git-core \
gstreamer1.0-plugins-{bad,base,good,ugly} \
gstreamer1.0-{omx,alsa} python-dev cython
pi@raspberrypi ~ $ sudo pip install git+https://github.com/kivy/kivy.git@master
pi@raspberrypi ~ $ sudo apt-get install python-{pygments,docutils}
@tdack
tdack / upgrade_ghost.sh
Last active Jan 6, 2016 — forked from anonymous/upgrade_ghost.sh
Bash script to upgrade your Ghost blog installation to the latest version
View upgrade_ghost.sh
#!/bin/bash
# Make sure only root can run our script
if [[ ${EUID} -ne 0 ]]; then
echo "This script must be run as root" 1>&2
exit 1
fi
if [[ $# -eq 0 ]]; then
echo "Usage:"
echo " $0 <systemd|sysv>"
View pendulum.cpp
ofstream fSlots;
fSlots.open(SLOTS);
fSlots << "ADAFRUIT-UART2" << std::endl;
fSlots << "PyBBIO-epwmss0" << std::endl;
fSlots << "PyBBIO-eqep0" << std::endl;
fSlots << "PyBBIO-epwmss1" << std::endl;
fSlots << "PyBBIO-eqep1" << std::endl;
fSlots.close();
You can’t perform that action at this time.