kiwirecorder v1.5 released
Kiwirecorder v1.5 contains two new features:
* Continuous scanning. Leaving out the "threshold" parameter from the scan.yaml will cause scanning and file recording to be continuous. That is, no squelch will be applied. See the file SCANNING for detailed information.
* Camp mode. Instead of creating a new connection to the Kiwi when kiwirecorder is run it can now "camp" onto an existing connection and record whatever audio the camped user is listening to. Very similar to the camp capability that is presented via the camp/queue panel that appears when you try and connect to a Kiwi when all its channels are full. See the option --camp=CAMP_CHAN
where CAMP_CHAN is the Kiwi channel number to camp on (e.g. 0..4 for rx0..rx4).
Note that a 2-channel (stereo) file or netcat stream is always produced because you can't predict what the camped user will do. They may switch from a mono mode (e.g. USB) to a stereo mode (e.g. IQ) at any time. For mono modes the single channel audio is duplicated in both channels. Things also work when the camped user switches compression mode on and off.
Camp mode also works with the --netcat
option. For an example see the Makefile "camp" target.
Comments
Since updating kiwiclient directory to v1.5 can`t use kiwiclientd any more:
Traceback (most recent call last):
File "/home/user/kiwiclient/kiwiclientd.py", line 566, in <module>
main()
File "/home/user/kiwiclient/kiwiclientd.py", line 530, in main
opt.netcat = False
^^^
UnboundLocalError: cannot access local variable 'opt' where it is not associated with a value
Motivated by previous lines in kiwiclientd.py changed line 530 to: "options.netcat = False". Solved this error but got another:
Traceback (most recent call last):
File "/home/user/kiwiclient/kiwi/worker.py", line 48, in run
self._recorder.run()
File "/home/user/kiwiclient/kiwi/client.py", line 794, in run
self._process_ws_message(received)
File "/home/user/kiwiclient/kiwi/client.py", line 205, in _process_ws_message
self._process_message(tag, body)
File "/home/user/kiwiclient/kiwi/client.py", line 511, in _process_message
self._process_aud(body)
File "/home/user/kiwiclient/kiwi/client.py", line 672, in _process_aud
self._process_audio_samples(seq, samples, rssi, fmt)
TypeError: KiwiSoundRecorder._process_audio_samples() takes 4 positional arguments but 5 were given
too complicated for me, need help please.
Sorry about that. Please update your git clone and try again.
Thank you for quick response, updated and now have:
Traceback (most recent call last):
File "/home/user/kiwiclient/kiwi/worker.py", line 48, in run
self._recorder.run()
File "/home/user/kiwiclient/kiwi/client.py", line 794, in run
self._process_ws_message(received)
File "/home/user/kiwiclient/kiwi/client.py", line 205, in _process_ws_message
self._process_message(tag, body)
File "/home/user/kiwiclient/kiwi/client.py", line 511, in _process_message
self._process_aud(body)
File "/home/user/kiwiclient/kiwi/client.py", line 672, in _process_aud
self._process_audio_samples(seq, samples, rssi, fmt)
File "/home/user/kiwiclient/kiwiclientd.py", line 140, in _process_audio_samples
self._player.play(fsamples)
File "/home/user/.local/lib/python3.12/site-packages/soundcard/pulseaudio.py", line 786, in play
bytes = data[:nwrite].ravel().tostring()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'numpy.ndarray' object has no attribute 'tostring'
Are you using python3? What do you get when you do a
python3 --version
?After my fixes it works for me here using Python3 3.13.5 on a Mac.
python 3.12.11 on postmarketOS edge linux on PinePhone
Installed on Debian 12.11 with python 3.11.2 and plays OK. Thank you for help, must see myself what is wrong on PinePhone.
Think I found the source of last error on PinePhone. It`s numpy version 2.3.1. Debian has ver. 1.24.2 from his apt repository. When I removed it and installed new one from pip repository (also ver. 2.3.1) got the same above error on Debian. Restored previous 1.24.2 version and again all plays OK. Thanks again for help.
Okay, good. Python has the worst problems with "versionitis" of any programing language/system I've ever seen. It's just awful.