Skip to content

Instantly share code, notes, and snippets.

$ emerge -pvuDU @world
These are the packages that would be merged, in order:
Calculating dependencies ... ... ..... done!
Dependency resolution took 42.83 s (backtrack: 1/20).
[ebuild NS ] dev-lang/rust-1.92.0_p1-r1:1.92.0::gentoo [1.91.0:1.91.0::gentoo] USE="system-llvm (-big-endian) -clippy -debug -dist -doc (-llvm-libunwind) -lto -rust-analyzer -rust-src -rustfmt -test -verify-sig" ABI_X86="(64) -32 (-x32)" CPU_FLAGS_X86="sse2" LLVM_SLOT="(21)" LLVM_TARGETS="(X86) -AArch64 -AMDGPU -ARC -ARM -AVR -BPF -CSKY -DirectX -Hexagon -Lanai -LoongArch -M68k -MSP430 -Mips -NVPTX -PowerPC -RISCV -SPIRV -Sparc -SystemZ -VE -WebAssembly -XCore -Xtensa" RUST_SYSROOTS="-bpf -wasm" 0 KiB
[ebuild U ~] dev-util/android-studio-2025.3.1.8::gentoo [2025.2.3.9::gentoo] USE="(-selinux)" 0 KiB
@Cheaterman
Cheaterman / aptar-rfid-firmware.ino
Created September 17, 2025 16:36
aptar-rfid-firmware.ino
#include <SoftPWM.h>
#include <SPI.h>
#include "MFRC522.h"
#include "demux.h"
#define DEBUG false
//#define DEBUG true
#define MAX_UIDS 12
#define MAX_ATTEMPTS 3
@Cheaterman
Cheaterman / aptar-rfid-firmware.ino
Created September 17, 2025 16:28
aptar-rfid-firmware.ino
#include <SoftPWM.h>
#include <SPI.h>
#include "MFRC522.h"
#include "demux.h"
#define DEBUG false
//#define DEBUG true
#define MAX_UIDS 12
#define MAX_ATTEMPTS 3
@Cheaterman
Cheaterman / calib.py
Created July 24, 2025 13:52
calib.py
import math
from kivy.core.window import Window
from kivy.graphics.transformation import Matrix
from kivy.vector import Vector
CALIBRATION_MATRIX = Matrix()
# Calibration angle: -1.5758043422592645
# Calibration scale: [1.373241596109775, -1.040252303237079]
@Cheaterman
Cheaterman / calib.py
Created July 24, 2025 12:25
calib.py
import math
from kivy.graphics.transformation import Matrix
from kivy.vector import Vector
CALIBRATION_MATRIX = Matrix()
# Calibration angle: -1.5758043422592645
# Calibration scale: [1.373241596109775, -1.040252303237079]
touches = [
@Cheaterman
Cheaterman / lighttpd.full.conf
Created April 25, 2025 10:17
lighttpd.full.conf
# This is the output of "sudo lighttpd -f /etc/lighttpd/lighttpd.conf -p > /tmp/lighttpd.full.conf"
# With website domain name replaced with <website> (subdomain preserved for debugging purposes)
config {
var.CWD = "/var/www/erp"
var.PID = 1056149
mimetype.assign = (
".cwl.json" => "application/cwl+json",
".sarif.json" => "application/sarif+json",
".sarif-external-properties.json" => "application/sarif-external-properties+json",
".spdx.json" => "application/spdx+json",
@Cheaterman
Cheaterman / .vimrc
Created March 11, 2025 15:37
.vimrc
set completeopt=popup,menuone
set incsearch
set modeline
set mouse=a
set omnifunc=syntaxcomplete#Complete
set scrolloff=999
set shell=/bin/bash
set showcmd
set signcolumn=yes
set tags+=,.git/tags,~/Dev/Kivy/kivy/tags
@Cheaterman
Cheaterman / utilsfile.ts
Created February 21, 2025 09:43
utils/file.ts
export function selectFile(mimeTypes: string[] = [], multiple: boolean = false) {
return new Promise<FileList | null>((resolve, reject) => {
const input = document.createElement('input')
input.type = 'file'
input.multiple = multiple
if (mimeTypes.length) {
input.accept = mimeTypes.join(', ')
}
@Cheaterman
Cheaterman / main.py
Created August 24, 2024 16:33
A radial progress bar with a gradient!
from kivy.animation import Animation
from kivy.app import App
from kivy.lang import Builder
from kivy.properties import AliasProperty, ColorProperty, NumericProperty
from kivy.uix.effectwidget import AdvancedEffectBase, EffectWidget
class TangentGradient(AdvancedEffectBase):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
@Cheaterman
Cheaterman / main.py
Created April 4, 2024 18:29
main.py
import collections
import re
text = '''
20. Miguel ReC FIN 30,39 31
21. Mz FIN 30,40 29,5
21. kuiva FIN FIN 30,40 29,5
23. MozMan H K GBR 30,48 27,5
23. oizo! SWE 30,48 27,5
25. Jalli FBE NOR 30,49 25,5