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 / mikroe-click-ble-controller.md
Created August 12, 2023 18:44
MikroE BLE Click Boards usable as controller (master)
board product ID chip usable as controller?
BLE 2 Click MIKROE-1715 RN4020 no
BLE 3 Click MIKROE-2471 NINA-B1 yes?
BLE 4 Click MIKROE-3773 NINA-B312 yes?
BLE 5 Click MIKROE-4120 PAN1760A NRND?
BLE 6 Click MIKROE-4170 BlueNRG-M2 yes
BLE 7 Click MIKROE-3872 BGX13S22GA-V31 yes?
BLE 8 Click MIKROE-3674 ANNA-B112 yes?
BLE 9 Click MIKROE-4487 BGM220P yes?
@RavuAlHemio
RavuAlHemio / BaseTech_1602089.svg
Last active May 12, 2022 03:41
BaseTech telephone plug adapters (plugs are oriented towards the user!)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@RavuAlHemio
RavuAlHemio / FritzBox_Adapter_058.svg
Last active February 13, 2024 20:08
FRITZ!Box Austrian/Swiss adapters (plugs are oriented towards the user!)
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