I loaded weewx into a Ubuntu 20 vitrual machine I created just to run weewx.
I created a Linux user called weewx, so the /home/weewx directory exists.
I installed the rtl-sdr and rtl-433 using apt-get (DEB packages).
For weewx, I followed the instructions for the "Installation using setup.py" method, where you download the source, make and install it.
That process appeared to work ok - no errors shown during the process.
I'm following the weewx-sdr driver install process and it's falling flat in several places.
Are the instructions incomplete, or out of date?
Is there an incompatibility with python 3.8? (the current version)
Installation
1) download the driver
wget -O weewx-sdr.zip
https://github.com/matthewwall/weewx-sdr/archive/master.zip
WORKED 2) install the driver
sudo wee_extension --install weewx-sdr.zip
FAILS with:
weewx@Ubuntu20-WEEWX:~/Downloads$ sudo wee_extension --install weewx-sdr.zip
sudo: wee_extension: command not found
If I remove the sudo, the command runs, but bombs because of permission errors!FAILS WITH:
weewx@Ubuntu20-WEEWX:~/Downloads$ wee_extension --install weewx-sdr.zip
Request to install 'weewx-sdr.zip'
Extracting from zip archive weewx-sdr.zip
Traceback (most recent call last):
File "/home/weewx/bin/wee_extension", line 88, in <module> main()
File "/home/weewx/bin/wee_extension", line 80, in main
ext.install_extension(options.install)
File "/home/weewx/bin/weecfg/extension.py", line 125, in install_extension
self.install_from_dir(extension_dir)
File "/home/weewx/bin/weecfg/extension.py", line 183, in install_from_dir
shutil.copy(source_path, destination_path)
File "/usr/lib/python3.8/shutil.py", line 415, in copy
copyfile(src, dst, follow_symlinks=follow_symlinks)
File "/usr/lib/python3.8/shutil.py", line 261, in copyfile
with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
PermissionError: [Errno 13] Permission denied: '/home/weewx/bin/user/sdr.py'
CAN'T GO ANY FARTHER. HELP REQUESTED.
3) configure the driver
sudo wee_config --reconfigure --driver=user.sdr --no-prompt
4) run the driver directly to identify the packets you want to capture
cd /home/weewx
sudo PYTHONPATH=bin python bin/user/sdr.py --cmd="rtl_433 -M utc -F json"
5) modify the [SDR] section of weewx.conf using a text editor
- create a [[sensor_map]] for the data you want to capture
- possibly modify the 'cmd' parameter
6) start weewx
sudo /etc/init.d/weewx start