- expert install - "Load installer components from CD. From here, you want to select crypto-dm-modules and rescue-mode." - ctrl+alt+f2 to jump into a shell - depmod -a - cryptsetup luksOpen /dev/sda3 debian-crypt - vgchange -ay - ls /dev/mapper control debian-crypt debian-home debian-root debian-swap - "Hit ctrl+alt+f1 to return to the Debian installer and continue to Partition disks. Select Manual." - setup partitions/mount points - stop before Install the GRUB bootloader to a hard disk. ctrl+alt+f2 to jump into a terminal. - blkid - nano /target/etc/crypttab debian-crypt UUID=98...eaa none luks - "Continue to the end of the installation. When the generating initramfs step appears, the image will be built using the crypttab file you just modified."
Monday, October 13, 2025
Install debian on encrypted volume
See
https://www.blakecarpenter.dev/installing-debian-on-existing-encrypted-lvm/
The main points:
Saturday, October 11, 2025
USB Audio not detected after resume. Edifier M60.
Sometimes USB audio device (e.g. Edifier M60 speakers via usb-c connection) is not detected after resume, or after repluging, although
aplay -llists the device, the pipewire server does not add it. Restart pipewire:
systemctl --user restart pipewireIf the former does not help, try the following instead:
systemctl --user restart pipewire pipewire-pulse wireplumber
Tuesday, July 29, 2025
Sunday, July 13, 2025
8bitdo pro 2 hall joysticks calibration issue
8bitdo pro 2 gamepad with hall effect joysticks has an issue that after pressing
the left stick it extends (recalibrates) it's value range beyond the range in
the unpressed state, so (in my case) ultimate UP (forward) direction does not
register as 100%, so e.g. running mode in games becomes unreachable with the
extreme stick position (until you push it). There's an undocumented firmware
recalibration mode:
https://www.reddit.com/r/8bitdo/comments/1dtkoqx/sticks_are_not_aligned_anyway_to_calibrate_this/
From 8bitdo support about the Pro 2: L1+R1+SELECT Hold 10sec start calibration Rotate both joysticks 3turns *Simultaneously clockwise Fully press both triggers 3times Press all combination keys again to complete the calibration Turn-off the controller then turn on again
Sunday, April 27, 2025
Sunday, February 11, 2024
Transcoding with intel quicksync (qsv) h264 -> hevc
Convert on hardware from h264 to h264 full hd, also compress audio to AAC to make a common .mp4 file.
#!/bin/env bash # usage: enc.sh <source_file> <quality, e.g. 25, 1..51> # https://trac.ffmpeg.org/wiki/Hardware/QuickSync # accepts h264 and transcodes on hardware, tested. ffmpeg -hwaccel qsv -c:v h264_qsv -i "$1" -init_hw_device qsv:hw -vf 'scale_qsv=1920:1080' -c:a aac -b:a 192K -c:v h264_qsv -global_quality:v $2 -preset:v 1 -profile:v 77 "$1-h264-aac-qsv-1080p-$2.mp4"Convert to hevc/h265:
#!/bin/env bash # usage: enc.sh <source_file> <quality, e.g. 25, 1..51> # https://trac.ffmpeg.org/wiki/Hardware/QuickSync # accepts h264 and transcodes on hardware, tested. ffmpeg -hwaccel qsv -c:v h264_qsv -i "$1" -c:v hevc_qsv -global_quality:v $2 -preset:v 1 -profile:v 1 -c:a libopus -b:a 96K "$1-hevc-qsv-$2.mkv"Encode to VP9 (in software):
#!/bin/env bash # usage: enc.sh <source_file> <quality, e.g. 30, 0..63> # https://trac.ffmpeg.org/wiki/Encode/VP9 ffmpeg -i "$1" -c:a libopus -b:a 96K -c:v libvpx-vp9 -b:v 0 -crf $2 -pass 1 -an -f null /dev/null ffmpeg -i "$1" -c:a libopus -b:a 96K -c:v libvpx-vp9 -b:v 0 -crf $2 -pass 2 "`basename $1`_vp9tp_$2.webm"
Saturday, September 9, 2023
Kensington Expert Mouse Linux config
#!/bin/bash
#
LEFT_HANDED=""
show_help() {
echo "Usage: [--left]"
echo "--left = use lefthanded config"
exit 1
}
parse_args() {
while [[ $# -gt 0 ]]; do
case $1 in
--left)
LEFT_HANDED="yes"
shift
;;
*)
show_help
;;
esac
done
}
parse_args $@
MOUSE_NAME="Kensington Expert Mouse"
CHECK=$(xinput | grep "$MOUSE_NAME")
set -e
echo "check=$CHECK"
if [[ -z "$CHECK" ]]; then
echo "Cannot find the device: $MOUSE_NAME"
exit 1
fi
TRACKBALL_ID=$(xinput | grep "$MOUSE_NAME" | sed 's/^.*id=\([0-9]*\)[ \t].*$/\1/')
LEFT_TOP=2
LEFT_BOTTOM=1
RIGHT_TOP=8
RIGHT_BOTTOM=3
SCROLL_CLOCKWISE=5
SCROLL_COUNTERCW=4
# LB, LT, RB, SCCW, SCW, 6, 7, RT
MOUSE_LEFT=1
MOUSE_MIDDLE=2
MOUSE_RIGHT=3
# ---
# make scrolling with the ball smooth
SCROLLING_PIXEL_DISTANCE=50
# X clients receive events with logical button numbers, where 1, 2, 3 are usually interpreted as left, middle, right and logical buttons 4, 5, 6, 7 are usually interpreted as scroll up, down, left, right. The fourth and fifth physical buttons on a device will thus send logical buttons 8 and 9. The ButtonMapping option adjusts the logical button mapping, it does not affect how a physical button is mapped to a logical button.
if [[ -n $LEFT_HANDED ]]; then
echo "using lefthanded config"
SCROLLING_BUTTON=$RIGHT_TOP
# LB, LT, RB, SCCW, SCW, 6, 7, RT
BUTTON_MAP="$MOUSE_MIDDLE $MOUSE_RIGHT $MOUSE_LEFT 4 5 6 7 8"
else
# right hand settings
SCROLLING_BUTTON=$LEFT_TOP
# LB, LT, RB, SCCW, SCW, 6, 7, RT
BUTTON_MAP="$MOUSE_LEFT 8 $MOUSE_MIDDLE 4 5 6 7 $MOUSE_RIGHT"
fi
# -------
xinput set-prop $TRACKBALL_ID "libinput Scrolling Pixel Distance" $SCROLLING_PIXEL_DISTANCE
xinput set-prop $TRACKBALL_ID "libinput Button Scrolling Button" $SCROLLING_BUTTON
xinput set-prop $TRACKBALL_ID "libinput Scroll Method Enabled" 0, 0, 1
xinput set-button-map $TRACKBALL_ID 1 2 3 4 5 6 7 8 9
echo $BUTTON_MAP
xinput set-button-map $TRACKBALL_ID $BUTTON_MAP
Subscribe to:
Comments (Atom)