Skip to content

Instantly share code, notes, and snippets.

View jj1bdx's full-sized avatar
🏠
Working from home

Kenji Rikitake jj1bdx

🏠
Working from home
View GitHub Profile
@jj1bdx
jj1bdx / 000-hamsci-sunrisefest-usage.md
Last active May 5, 2022 15:12
HamSCI Sunrisefest recording scripts for Airspy HF+ Discovery
@jj1bdx
jj1bdx / get-dslite-aftr-in-asahinet.md
Created March 14, 2022 05:01 — forked from stkchp/get-dslite-aftr-in-asahinet.md
ASAHIネットのDS-Liteの終端(AFTR)を取得するメモ

ASAHIネットのDS-Liteの終端(AFTR)を取得する

ASAHIネットがDS-Lite対応したので、 自宅の適当なLinuxルーターにて設定しようとして詰まったAFTR取得に関するメモ。

Linuxルーターを使ってる人向けのニッチなものだけど、情報として残しておく。

終端の情報公開について

@jj1bdx
jj1bdx / disable-pulseaudio.md
Created January 30, 2022 08:07
Disabling PulseAudio with ALSA from Ubuntu
# symbolic link to /usr/share/alsa/alsa.conf.d/50-jack.conf
rm /etc/alsa/conf.d/50-jack.conf
# symbolic link to /usr/share/alsa/alsa
mv /usr/share/alsa/alsa.conf.d/50-jack.conf somewhere-else
@jj1bdx
jj1bdx / flac-to-alac-convert.sh
Created December 7, 2021 10:26
Convert FLAC to ALAC in batch
#!/bin/sh
# https://sound.stackexchange.com/questions/26633/free-batch-conversion-from-flac-to-apple-lossless-alac
# https://stackoverflow.com/questions/55429909/could-not-find-tag-for-codec-h264-in-stream-0-codec-ffmpeg-flac-to-alac-conver
for name in *.flac; do \
ffmpeg -nostdin -i "$name" -c:a alac -c:v copy "${name%.*}.m4a" && \
ffmpeg -nostdin -i "$name" -vf "crop=((in_w/2)*2):((in_h/2)*2)" \
"${name/%flac/jpg}" && \
AtomicParsley "${name/%flac/m4a}" --artwork "${name/%flac/jpg}" --overWrite; \
done
@jj1bdx
jj1bdx / nowtonextday.py
Last active November 26, 2021 01:17
A python script of returning the number of seconds from now to the next beginning of day in UTC
#!/usr/bin/env python3
"""
This program returns number of seconds from now
to the next beginning of day in UTC (0000UTC next day),
truncated into the nearest integer.
"""
import datetime
current = datetime.datetime.utcnow()
nextday = current + datetime.timedelta(days=1)
@jj1bdx
jj1bdx / audioif-freq-accuracy-measurement.md
Last active August 18, 2021 01:29
Measurement of frequency/timing accuracy for audio interfaces

Measurement of frequency/timing accuracy for audio interfaces

Kenji Rikitake, JJ1BDX 18-AUG-2021

Objectives

  • Finding out long-term/static frequency/timing offset of an audio interface input/output
  • To prove timing difference of real-world audio interfaces
@jj1bdx
jj1bdx / Makefile
Created July 28, 2021 08:22 — forked from trueroad/Makefile
ipsj.cls を upLaTeX 用にしてみる(源ノ明朝・源ノ角ゴシックを使う)
#
# ipsj.cls を upLaTeX 用にしてみる(源ノ明朝・源ノ角ゴシックを使う)
# https://gist.github.com/trueroad/c44312923bf02226c2274388941d0453
#
# ipsj.cls は pLaTeX 専用のようなのですが、
# 試しに upLaTeX で使えるようにした up-ipsj.cls を作ってみました。
# upLaTeX なので pLaTeX では難しかった源ノ明朝・源ノ角ゴシックの利用が
# できるようになります。
#
# 無保証です。これを使った結果何が起きても責任は取りません。
@jj1bdx
jj1bdx / basictex-config-homebrew.sh
Last active July 29, 2021 03:20
MacTeX BasicTeX config example with homebrew
#!/bin/sh
## remove TeX directories if needed
#sudo /bin/rm -rf /usr/local/texlive
#sudo /bin/rm -rf /Library/TeX
##
umask 022
brew install --cask basictex
#
sudo zsh
umask 022
@jj1bdx
jj1bdx / com.wsjtx.sysctl.plist
Created July 27, 2021 08:45
macOS system tuning for Big Sur 11.5.1 to run WSJT-X and gqrx
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.wsjtx.sysctl</string>
<key>Program</key>
<string>/usr/sbin/sysctl</string>
<key>ProgramArguments</key>
<array>