Skip to content

Instantly share code, notes, and snippets.

View Erhannis's full-sized avatar

Erhannis

View GitHub Profile
@Fingercomp
Fingercomp / nn.lua
Last active September 8, 2022 21:01
OpenComputers Nanomachines control program [Minecraft]
local CONF = "/etc/nn.conf"
local m = require("component").modem
local event = require("event")
local ser = require("serialization")
local fs = require("filesystem")
local unicode = require("unicode")
_G.port = _G.port or 27091
_G.max = _G.max or 15
_G.effects = _G.effects or {}
@boredzo
boredzo / skew.scad
Created January 5, 2016 06:02
Skew operator for OpenSCAD
/*skew takes an array of six angles:
*x along y
*x along z
*y along x
*y along z
*z along x
*z along y
*/
module skew(dims) {
matrix = [
@MightyPork
MightyPork / usb_hid_keys.h
Last active June 30, 2024 10:41
USB HID Keyboard scan codes
/**
* USB HID Keyboard scan codes as per USB spec 1.11
* plus some additional codes
*
* Created by MightyPork, 2016
* Public domain
*
* Adapted from:
* https://source.android.com/devices/input/keyboard-devices.html
*/
@zjhmale
zjhmale / waitgroup.py
Created April 25, 2020 07:28
Python WaitGroup (like Go sync.WaitGroup)
import threading # :(
class WaitGroup(object):
"""WaitGroup is like Go sync.WaitGroup.
Without all the useful corner cases.
"""
def __init__(self):
self.count = 0
self.cv = threading.Condition()