Skip to content

Instantly share code, notes, and snippets.

View ktemkin's full-sized avatar

Kate Temkin ktemkin

View GitHub Profile
@ktemkin
ktemkin / roli_fw_extract.py
Created April 29, 2023 07:03
WIP script to unpack Roli firmware files
#!/usr/bin/python3
import math
import mido
FIRMWARE_IN = "firmware.syx"
FIRMWARE_OUT = "firmware.bin"
FIRMWARE_PUSH_COMMAND = 0x04
@ktemkin
ktemkin / maschine_mk3.md
Created May 18, 2023 00:26
Maschine Mk3 RE Notes

Display Format

The device has a "vendor defined interface" (5) with a single bulk OUT endpoint (4). This accepts commands that will set the screen value, with the following format:

Byte Meaning
0 const 0x84, command
1 const 0x00
2 screen number; 0 for left, 1 for right
3 const 0x60
#!/usr/bin/env python2.7
import asyncore
import evdev
import signal
import re
#Stores the product names for each device which can be used as a vim-clutch.
COMPATIBLE_NAME_REGEX = "RDing FootSwitch.*";
@ktemkin
ktemkin / quote-for-nixos.xsh
Created May 3, 2024 14:52
hack to let you use unquoted flake attr refs in xonsh
""" Input transformer that automatically quotes mid-word #s for e.g. nix. """
from xonsh.events import events
@events.on_transform_command
def _autoquote_for_nix(cmd):
new_command = []
# Process each word individually.
words = cmd.strip().split(" ")
@ktemkin
ktemkin / README.md
Last active May 26, 2025 05:58
script to grab garmin maps from Express without waiting for them to transfer

Proof I'm Terminally Impatient

Tired of waiting for Garmin to transfer those map files to your GPS over its incredible 12Mbps full speed USB? Tired of waiting for two hours for it to copy, only for the cable to be jostled just enough for it to fail early -- and then you're stuck with a bunch of map files but none of the gods-forsaken unlock codes that you need to use them?

Well, I am, and since this is my README, you don't get to judge me. That's just the way it is.

Usage

  • Start Garmin Express, and tell it to download the target maps to your device.
  • Wait for the message to change from "downloading files" to "copying files".