Saturday, August 5, 2023

Run automatik weathex on Startup Raspberry Pi

Buat bash script untuk KLIA dahulu. namakan klia.sh

#!/bin/bash

# Change to the desired directory

cd ~/RS/weathex

# Run your command

rtl_fm -M fm -s 64k -f 401.1M | sox -t raw -r 64k -e s -b 16 -c 1 - -r 48000 -t wav - lowpass 4000 2>/dev/null | ./weathex -b

-----------------------------------------------------------------------------------------------

make the script executable

chmod +x klia.sh

-------------------------------------------------------------------------------------

Create a Desktop Entry

sudo apt update

sudo apt install lxterminal

mkdir -p ~/.config/autostart

nano ~/.config/autostart/myscript.desktop

[Desktop Entry]

Type=Application

Exec=lxterminal --command="/home/pi/klia.sh"

Hidden=false

NoDisplay=false

X-GNOME-Autostart-enabled=true

Name[en_US]=My Script

Name=My Script

Comment[en_US]=Run myscript.sh on startup

Comment=Run myscript.sh on startup

__________________________________________________________

save dan exit. Kemudian restart. jika gagal... double check pada path dan ejaan adakah  betul klia.sh ada disitu. bagi Kuantan, KB dan Bayan Lepas tu hanya perlu ganti freq sahaja.





video di atas adalah hasilnya. semoga bermanfaat. 73


Connect a GPS module to a Raspberry Pi 4

  To connect a GPS module with four wires (RST, TX, VCC, and GND) to a Raspberry Pi 4, follow these steps:  Materials Needed: 1. GPS module ...