After trying the change the serial number of my 1090ES dongle, somehow the ID of the dongle got changed, so piAware no longer recognizes the dongle.
After the dongle got changed, here is what I see:
pi@piaware:~ $ rtl_eeprom -g realtek_oem
No supported devices found.
pi@piaware:~ $ lsusb
Bus 001 Device 003: ID 00a0:28a0 Realtek RTL2832U
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@piaware:~ $
How can I change the ID of the dongle back to what it was, so that piAware will recognize it?
An easier software option is to add wrong ID to file /etc/udev/rules.d/rtl-sdr.rules
(1) Create a new blank file
sudo nano add-wrong-id.sh
(2) In this newly generated file, copy-paste following code
if [[ ! -f /etc/udev/rules.d/rtl-sdr.rules ]]; then
wget -O /etc/udev/rules.d/rtl-sdr.rules https://github.com/abcd567a/temp/raw/main/rtl-sdr.rules
fi
sed -i '1i SUBSYSTEMS=="usb", ATTRS{idVendor}=="00a0", ATTRS{idProduct}=="28a0", MODE:="0666"' /etc/udev/rules.d/rtl-sdr.rules
sed -i '1i # wrong ID enabled' /etc/udev/rules.d/rtl-sdr.rules
(3) Save file
(4) Run file by following command
sudo bash add-wrong-id.sh
(5) Now open file rtl-sdr.rules by following command to check it
sudo nano /etc/udev/rules.d/rtl-sdr.rules
At top of this file you will see 2 additional lines enabling your dongle’s wrong ID 00a0:28a0 (split in 2 parts)
If ading wrong ID to rtl-sdr.rules did not make dongle visible to rtl_test, then follow the instructions given by @obj to rebuild librtlsdr & rtl-sdr from source code after modifying file rtl-sdr/src/librtlsdr.c
STEP-2: Clone source-code and modify file rtl-sdr/src/librtlsdr.c
git clone https://github.com/osmocom/rtl-sdr.git
cd rtl-sdr
sed -i '/PROlectrix/a \\t{ 0x00a0, 0x28a0, "Wrong ID" },' src/librtlsdr.c
nano src/librtlsdr.c
In file opened by last command above, scroll down to line 352 to make sure the wrong PID and VID is added.
You can also jump to this line by pressing Ctrl+w then type Wrong, and then presss Enter Key