41 lines
1.1 KiB
Bash

#!/bin/bash
# Arch Linux Lab Equipment Module
arch_install_lab_tools() {
if ! role_enabled "LAB"; then
return 0
fi
log SECTION "Installing lab and measurement tools"
local section_start=$(date +%s)
if confirm "Install lab equipment software?"; then
# PicoScope and related tools from AUR
local lab_aur=(
ps7_libpicoipp ps7_libpicocv picoscope7
ps7_libps2000a ps7_libps3000a
nrf-udev nrfconnect-appimage
)
install_aur_packages "${lab_aur[@]}"
# System packages for lab work
local lab_packages=(tk python-pyserial)
install_packages "${lab_packages[@]}"
# Download SPM6103 viewer
cd ~ && wget -O spm6103_viewer.py \
"https://git.cmtec.se/cm/spm6103_viewer/-/raw/main/spm6103_viewer.py?ref_type=heads&inline=false"
log SUCCESS "Lab tools installed $(show_timer $section_start)"
fi
}
arch_setup_lab() {
arch_install_lab_tools
}
if [ -z "$ARCH_LAB_LOADED" ]; then
ARCH_LAB_LOADED=true
fi