Skip to content

Instantly share code, notes, and snippets.

View twstokes's full-sized avatar
📱
LOAD "*",8,1

Tanner Stokes twstokes

📱
LOAD "*",8,1
View GitHub Profile
@twstokes
twstokes / set-brightness.py
Created November 12, 2025 01:04
Juicy Crumb DockLite G4 Brightness Setter
# set_brightness.py
# requires pyusb module
# Usage:
# python set_brightness.py 800
# python set_brightness.py 0x320
import sys, struct, usb.core, usb.util
VID, PID = 0x4A43, 0x1D8A
//
// ContentView.swift
// Moon
//
// Created by Tanner W. Stokes on 8/9/20.
//
import SwiftUI
struct ContentView: View {
@twstokes
twstokes / influx_backup.sh
Last active April 18, 2017 13:47
InfluxDB Docker backups
#!/bin/bash
mkdir ./backups
dbs=( "_internal" "telegraf" "health" "nodemcu" "sensors" )
for db in "${dbs[@]}"
do
docker run --rm -v $PWD/backups:/backups influxdb influxd backup -database $db -host influx-hostname:8088 /backups/$db
done