Skip to content

Instantly share code, notes, and snippets.

View RavuAlHemio's full-sized avatar

Ondřej Hošek RavuAlHemio

View GitHub Profile
@RavuAlHemio
RavuAlHemio / FritzBox_Adapter_058.svg
Last active February 13, 2024 20:08
FRITZ!Box Austrian/Swiss adapters (plugs are oriented towards the user!)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@RavuAlHemio
RavuAlHemio / run.ps1
Last active May 2, 2022 06:26
automates inserting and removing USB drives backed by a VHDX image from a QEMU VM
& "C:\Program Files\qemu\qemu-system-i386.exe" `
-cpu pentium3 `
-m 1024 `
-vga cirrus `
-drive "if=ide,bus=0,unit=0,media=disk,file=w2k_de.qcow2" `
-drive "if=ide,bus=1,unit=0,media=cdrom" `
-device sb16 `
-device "usb-ehci" `
-device "usb-tablet" `
-qmp "tcp:127.0.0.1:6969,server,wait=off" `
@RavuAlHemio
RavuAlHemio / Encrypt-SpanishWord.ps1
Last active October 12, 2022 09:19
encrypt and decrypt Spanish Wordle solutions
[CmdletBinding()]
Param (
[Parameter(Position=1,Mandatory=$true)]
[string]
$Word,
[Parameter(Position=2)]
[byte[]]
$FixedSalt
)
@RavuAlHemio
RavuAlHemio / github-deploy.py
Created January 31, 2022 00:07
script that downloads the newest Github artifact, unpacks it and deploys its contents
#!/usr/bin/env python3
import base64
from fnmatch import fnmatch
import io
import os
import sys
import subprocess
import tempfile
import time
import urllib.parse
@RavuAlHemio
RavuAlHemio / USB_Mini-B_KLS1-229-5FA.kicad_mod
Created May 30, 2021 17:17
KiCad work-in-progress footprint for the KLS1-229-5FA through-hole Mini-USB connector
(module USB_Mini-B_KLS1-229-5FA (layer F.Cu) (tedit 60B3C276)
(descr https://img80002547.weyesimg.com/uploads/www.klselectronic.com/addon/15705980428308.pdf)
(tags "usb mini receptacle")
(fp_text reference REF** (at 0 -5.35) (layer F.SilkS)
(effects (font (size 1 1) (thickness 0.15)))
)
(fp_text value %R (at 0 1.05) (layer F.Fab)
(effects (font (size 1 1) (thickness 0.15)))
)
(fp_line (start -4.65 6.775) (end -4.65 -3.875) (layer F.CrtYd) (width 0.05))
# released under CC0: https://creativecommons.org/publicdomain/zero/1.0/
from decimal import Decimal
DEFAULT_TOLERANCE = "20"
COLOR_ALIASES = {
# alternative names/spellings
"grey": "gray",
"purple": "violet",
@RavuAlHemio
RavuAlHemio / cisco-section.awk
Created April 6, 2021 20:55
awk script that does similar filtering to Cisco's "section" filter (show running-config | section ^interface Vlan)
/^[^ ]/{printage = 0;} /PATTERN/{printage = 1;} { if (printage) { print $0; } }
Example:
awk '/^[^ ]/{printage = 0;} /^interface Vlan/{printage = 1;} { if (printage) { print $0; } }' configfile

Der Strom

  • Strom ist sehr dünn. Deshalb braucht man für Strom auch keinen Schlauch.

    Er geht durch einfachen Draht, so dünn ist er.

  • Mit Holz kann man keinen Strom übertragen. Wahrscheinlich saugt Holz ihn auf. Mit Kunststoff ist es genauso.

  • Wenn Strom nicht gebraucht wird, ist er nicht dünn. Im Gegenteil: er scheint

@RavuAlHemio
RavuAlHemio / Evva4KSKeyCap.scad
Created November 17, 2019 00:52
key cap for a standard EVVA 4KS key (SL)
// unit: 1mm
key_thickness = 2.25;
bow_width = 25.5;
bow_corner_radius = 6.0;
bow_corner_advance = 12.25;
bow_curve_advance = 10.0;
bow_curve_radius = 3.0;
bow_curve_outer_offset = 3.25;
stop_width = 13.0;
stop_advance = 5.517;
@RavuAlHemio
RavuAlHemio / Evva4KSBowAndStop.scad
Created November 16, 2019 21:07
the bow and stop of a standard EVVA 4KS key (SL)
// unit: 1mm
key_thickness = 2.26;
bow_width = 25.5;
bow_corner_radius = 6.0;
bow_corner_advance = 12.25;
bow_curve_advance = 10.0;
bow_curve_radius = 3.0;
bow_curve_outer_offset = 3.25;
stop_width = 13.0;