Skip to content

Instantly share code, notes, and snippets.

View shortword's full-sized avatar

Mike Bergeron shortword

View GitHub Profile
@shortword
shortword / gist:4ad2fb8fcc7ee6de3dfea3d43608a627
Created October 1, 2018 03:20
Initial Rock64 Armbian SSH Login
ssh root@rock64.lan
@shortword
shortword / update_reboot.sh
Created October 1, 2018 03:23
Update your Armbian system the easy way (as root, on first boot)
apt update
apt dist-upgrade -y
apt autoremove -y
reboot
@shortword
shortword / osmocom_prereq.sh
Created October 2, 2018 01:12
Steps to install osmocom driver prerequisites
sudo apt update
sudo apt install -y build-essential cmake git libusb-1.0-0-dev
@shortword
shortword / build_osmocom.sh
Created October 2, 2018 01:22
Download and build osmocom
mkdir -p $HOME/local/src
cd $HOME/local/src
git clone git://git.osmocom.org/rtl-sdr.git
cd rtl-sdr/
mkdir build
cd build
# PLEASE NOTE that with the flag below, devices will be available to non-root users!
cmake ../ -DINSTALL_UDEV_RULES=ON
# The next command includes '-j`nproc`' which will help utilize all of the cores on your device (AKA faster build)
make -j`nproc`
@shortword
shortword / blacklist_modprobe.sh
Created October 2, 2018 01:30
Blacklist rtl28xxu
echo "blacklist dvb_usb_rtl28xxu" | sudo tee /etc/modprobe.d/blacklist-rtlsdr.conf
@shortword
shortword / run_rtltest.sh
Created October 2, 2018 01:39
Run rtl_test
rtl_test -t
@shortword
shortword / udev_gps_output.txt
Created October 6, 2018 23:28
udevadm monitor USB GPS Output
KERNEL[1654.154728] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2 (usb)
KERNEL[1654.180457] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0 (usb)
KERNEL[1654.188490] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/ttyUSB0 (usb-serial)
KERNEL[1654.192137] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/ttyUSB0/tty/ttyUSB0 (tty)
UDEV [1654.272291] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2 (usb)
UDEV [1654.281351] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0 (usb)
UDEV [1654.287403] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/ttyUSB0 (usb-serial)
UDEV [1654.322383] add /devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/ttyUSB0/tty/ttyUSB0 (tty)
@shortword
shortword / usb_gps_udev_info.txt
Created October 6, 2018 23:33
USB GPS udev info
Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.
looking at device '/devices/platform/soc/20980000.usb/usb1/1-1/1-1.2/1-1.2:1.0/ttyUSB0/tty/ttyUSB0':
KERNEL=="ttyUSB0"
SUBSYSTEM=="tty"
DRIVER==""
@shortword
shortword / usb_gps_udev_query.sh
Created October 6, 2018 23:35
USB GPS udev query command
udevadm info -a -p $(udevadm info -q path -n /dev/ttyUSB0)
@shortword
shortword / 85-gps-usb.rules
Created October 6, 2018 23:48
USB GPS udev rules
ACTION=="add", KERNEL=="ttyUSB[0-9]*", SUBSYSTEM=="tty", SUBSYSTEMS=="usb", ATTRS{idProduct}=="2303", ATTRS{idVendor}=="067b", SYMLINK+="gps"