Synology Tips

24 Dec

Docker
Prior to installing Docker, create a “docker” shared folder with data checksum disabled, as the Docker install will create a folder (if non-existent) with the checksum enabled, and this feature is not advised for virtual machines.

SABnzbd
Create a /downloads shared folder giving Read/Write access to Local Groups “users”, as this will allow the mapped docker volume to access the local volume:

Create the following folder structure.

/downloads/usenet/complete
/downloads/usenet/incomplete
/downloads/usenet/nzb

Follow these instructions, though ignore the part about creating a separate user:
https://drfrankenstein.co.uk/2021/07/30/setting-up-sabnzbd-in-docker-on-a-synology-nas/
Allow an auto-assigned port and take note as this will be need to be changed later.
Don’t forget to set the environment variables, obtaining PUID and PGID from SSH into NAS and running “id”:

PUID 1026
PGID 100
TZ America/Chicago

After SABnzb installation, map the above folders in the config.
Speed up downloads by setting server SSL Ciphers to AES128.
Note auto-assigned port. Stop container and set it manually, then re-start.

Qbittorent
Create the following folder structure.

/downloads/torrents

Allow an auto-assigned port and take note as this will be need to be changed later.
Don’t forget to set the environment variables:

PUID 1026
PGID 100
TZ America/Chicago
WEBUI_PORT 8080

Per fix https://github.com/qbittorrent/qBittorrent/issues/8095#issuecomment-472740702
Add the following line to qBittorrent.conf

WebUI\HostHeaderValidation=false

Also modify address to match IP and port:

WebUI\Address=192.168.1.20:8080

Note auto-assigned port. Stop container and set it manually, then re-start.
Update router to forward port 6881 to NAS allowing both TCP and UDP.
Warning: the default username is “admin” and the default password is “adminadmin”

Advertisement

Sceptre Tips

22 Dec

X300 MTU
Note that the USRP X300 has both 1G and 10G interfaces. Sceptre will find both IP during USRP configuration. Delete the IP for the 1G interface as UHD will query both and use the lower of the two MTU to set the frame size, possibly resulting in lower performance.

DVR RAM Disk
Using the DVR with high sample rates can chew through an SSD. Make a RAM filesystem and use that for the DVR. If the system has 128 GB RAM then 96 GB is appropriate for DVR use, which will give a 90 second DVR at 200 Msps.

Create a RAM disk in Linux



free -g
sudo mkdir /mnt/ramdisk
sudo mount -t tmpfs -o size=96G tmpfs /mnt/ramdisk
chmod 777 /mnt/ramdisk/
df -h /mnt/ramdisk/

Sceptre on Xubuntu

10 Dec

sudo apt-get install libqt5x11extras5

sudo apt-get install –reinstall libxcb-xinerama0

sudo apt-get install python2

Xubuntu 22.04 LTS Linux Install Notes

25 Nov

Initial Install
Install from USB drive with minimal software
Do not download packages when installing
Reboot and attempt login (may get black screen after login due to bad Nvidia drivers).

Nvidia Driver Fix
Boot into safe mode
sudo apt update
sudo apt upgrade
sudo reboot now

Follow instructions for Ubuntu LTS at:
https://docs.nvidia.com/datacenter/tesla/tesla-installation-notes/index.html
sudo reboot now
nvidia-smi

Boot to Console
sudo cp /etc/default/grub /etc/default/grub.backup
sudo vi /etc/default/grub

Uncomment GRUB_TERMINAL=console
Remove “quiet splash”
sudo update-grub
sudo systemctl set-default multi-user.target

Network Config
IPV4: manual
Address: 192.168.1.2
Netmask: 255.255.255.0
Gateway: 192.168.1.1
Nameserver: 192.168.1.1
IPV6: ignore

Update the System
sudo apt update
sudo apt upgrade

Install Custom Shell Scripts
cp .bash_profile ~
cp .bashrc ~
cp .profile ~
cp .vimrc ~
sudo cp .bashrc /root

Directory Permissions
sudo chmod 777 /usr/local/src

Add Library Path to Linker
sudo vi /etc/ld.so.conf.d/usrlocal.conf
add /usr/local/lib
add /usr/local/lib64
sudo ldconfig

Firewall

Printer
sudo apt install system-config-printer
sudo system-config-printer

Search for network printer at 192.168.1.4
Use DirectJet port
Choose driver for Brother HL-5170DN
Use BR-Script3

Sound
sudo usermod -a -G audio username

Sceptre on Fedora 36

17 Sep

https://github.com/unicode-org/icu/releases/download/release-70-1/icu4c-70_1-src.tgz
sudo dnf install bzip2-devel
sudo ln -s /usr/lib64/libbz2.so.1.0.8 /usr/lib64/libbz2.so.1.0
sudo dnf install python2.7

Setting up Ettus USRP X300

18 Dec

https://kb.ettus.com/USRP_Host_Performance_Tuning_Tips_and_Tricks
https://files.ettus.com/manual/page_usrp_x3x0.html
https://files.ettus.com/manual/page_transport.html

Increase Socket Buffers
sudo vi /etc/sysctl.conf
# Increase buffers for USRP
net.core.wmem_max=100000000
net.core.rmem_max=100000000
net.core.wmem_default=100000000
net.core.rmem_default=100000000

Realtime Priority
sudo vi /etc/security/limits.conf
# Add for USRP realtime priority
myusername - rtprio 99

Will require re-login

Adjust Ethernet MTU
9000

Note intervening switches need jumbo frames enabled.

Set CPU Performance
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo performance | sudo tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor

Change GRUB
sudo vi /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="pti=off spectre_v2=off l1tf=off nospec_store_bypass_disable no_stf_barrier"
sudo grub2-mkconfig -o /boot/grub2/grub.cfg

Updating Firmware and FPGA
uhd_usrp_probe --args "addr=192.168.1.13"
sudo /usr/local/lib64/uhd/utils/uhd_images_downloader.py
/usr/local/bin/uhd_image_loader --args="type=x300,addr=192.168.1.13"

Cycle power on the USRP

Benchmark
cd /usr/local/lib64/uhd/examples
./benchmark_rate --rx_rate 100E6 --tx_rate 100E6 --args "addr=192.168.1.13"

ALTAIR 8800micro Build

9 Jul

ALTAIR 8800micro kit from Briel Computers

IMG_0040IMG_0041IMG_0042IMG_0044IMG_0045IMG_0046IMG_0047IMG_0048IMG_0049IMG_0050IMG_0051IMG_0052IMG_0068

Setting up the Airspy R2

4 Jun

https://github.com/airspy/airspyone_host

Add udev Rules
sudo vi /etc/udev/rules.d/99-airspy.rules
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1d50", ATTRS{idProduct}=="60a1", MODE:="0666"
sudo udevadm control --reload-rules

CMakeLists.txt for dial_tone.cc

30 May

If you want to compile dial_tone.cc outside of either the GR source tree or OOT module, this is the minimum required CMakeLists.txt (courtesy of Johnathan Corgan)

https://github.com/gnuradio/gnuradio/blob/64a702e19d1e8e1b948e6ef76e98dff41837bb92/gr-audio/examples/c%2B%2B/dial_tone.cc


cmake_minimum_required(VERSION 2.6)
project(dialtone CXX)

find_package(Boost "1.35" COMPONENTS system)
set(GR_REQUIRED_COMPONENTS RUNTIME ANALOG AUDIO)
find_package(Gnuradio "3.7.2" REQUIRED)

include_directories(${GNURADIO_ALL_INCLUDE_DIRS})

add_executable(dialtone dial_tone.cc)
target_link_libraries(dialtone ${Boost_LIBRARIES} ${GNURADIO_ALL_LIBRARIES})

Setting up the Ettus USRP E310

29 Jun

Add udev Rules for E310 Serial Console
sudo vi /etc/udev/rules.d/99-usrp-e310.rules
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6015", MODE:="0666"
sudo udevadm control --reload-rules

Serial Console Login
Plug in power and wait a few seconds for E310 to boot, then plug in microUSB.
dmesg to figure out the assigned serial port (i.e. /dev/ttyUSB4)
screen /dev/ttyUSB4 115200
Login as root

Setting Static IP
vi /etc/network/interfaces
# Wired or wireless interfaces
auto eth0
#iface eth0 inet dhcp
iface eth0 inet static
address 192.168.1.14
netmask 255.255.255.0
gateway 192.168.1.1
iface eth1 inet dhcp


/etc/init.d/networking stop