Skip to content

Instantly share code, notes, and snippets.

@DerBroader71
DerBroader71 / code.py
Created June 19, 2022 18:54
Mouse Jiggler with CircuitPython (Adafruit Trinkey QT2040) with enable/disable
import board
import neopixel
import usb_hid
import touchio
import time
from time import sleep
from adafruit_hid.mouse import Mouse
from random import randint
HOW_LONG = 10 # How long between jiggles in seconds
@DerBroader71
DerBroader71 / code.py
Created June 19, 2022 18:50
Adafruit Neokey 1x4 4-layer / 12 Macro Keypad
# import all required libraries
import board
import neopixel
from adafruit_neokey.neokey1x4 import NeoKey1x4
import usb_hid
from adafruit_hid.keyboard import Keyboard
from adafruit_hid.keyboard_layout_us import KeyboardLayoutUS
from adafruit_hid.keycode import Keycode
import time
@DerBroader71
DerBroader71 / worklog
Last active June 18, 2022 19:58
Bash script for logging time to a Jira task
#!/bin/bash
####based on https://gist.github.com/patrick-blom/593dd02338490941f4ba09f714e821c3 with API support instead of basic auth####
####Jira cloud doesn't support basic auth####
####add a worklog to a specific jira issue####
####get API token from https://id.atlassian.com/manage/api-tokens####
#arguments:
#-i: issue or ticket number
#-t: time in minutes
#-c: comment for the worklog