Skip to content

Instantly share code, notes, and snippets.

View tr00st's full-sized avatar

James Cheese tr00st

View GitHub Profile
@sandyjmacdonald
sandyjmacdonald / code.py
Last active July 2, 2025 20:02
MIDI CC knob controller example for Raspberry Pi Pico
import time
import board
import usb_midi
import adafruit_midi
from analogio import AnalogIn
from adafruit_midi.control_change import ControlChange
# MIDI CC knob controller example for Raspberry Pi Pico
#EXTM3U
#EXTINF:0,Kerrang Radio AAC 48k
https://stream-al.hellorayo.co.uk/kerrang.aac?direct=true&aw_0_1st.skey=1602676850
#EXTINF:0,Absolute Classic Rock AAC 128K
https://stream-ar.hellorayo.co.uk/absoluteclassicrock.aac?direct=true&aw_0_1st.skey=1602676850
#EXTINF:0,Radio Paradise Rock FLAC
http://stream.radioparadise.com/rock-flac
#EXTINF:0,Planet Rock AAC 48k
https://stream-mz.hellorayo.co.uk/planetrock.aac?direct=true&aw_0_1st.skey=1602676850
#EXTINF:0,KISS London Radio AAC 48k
@sandyjmacdonald
sandyjmacdonald / code.py
Created January 23, 2021 11:23
Emergency cat GIF macro example for Pimoroni RGB Keypad for Raspberry Pi Pico
import time
import board
import busio
import usb_hid
from adafruit_bus_device.i2c_device import I2CDevice
import adafruit_dotstar
from adafruit_hid.keyboard import Keyboard
from adafruit_hid.keyboard_layout_us import KeyboardLayoutUS
@gdamjan
gdamjan / README.md
Last active May 25, 2025 01:21
Setup for an easy to use, simple reverse http tunnels with nginx and ssh. It's that simple there's no authentication at all. The end result, a single ssh command invocation gives you a public url for your web app hosted on your laptop.

What

A lot of times you are developing a web application on your own laptop or home computer and would like to demo it to the public. Most of those times you are behind a router/firewall and you don't have a public IP address. Instead of configuring routers (often not possible), this solution gives you a public URL that's reverse tunnelled via ssh to your laptop.

Because of the relaxation of the sshd setup, it's best used on a dedicated virtual machine just for this (an Amazon micro instance for example).

Requirements

@zenorocha
zenorocha / README.md
Last active March 11, 2026 14:24
A template for Github READMEs (Markdown) + Sublime Snippet

Project Name

TODO: Write a project description

Installation

TODO: Describe the installation process

Usage

@maraujop
maraujop / forms.py
Created February 15, 2012 19:04
django-crispy-forms bootstrap form example
# -*- coding: utf-8 -*-
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.layout import Layout, Div, Submit, HTML, Button, Row, Field
from crispy_forms.bootstrap import AppendedText, PrependedText, FormActions
class MessageForm(forms.Form):
text_input = forms.CharField()