Re: Allstar & DMR | piping audio from talkgroup into USB soundcard


Steve N4IRS
 

You can disable the on-board sound device by editing /boot/config.txt
add to the bottom of the file:
dtparam=audio=off

On 09/09/2018 10:33 PM, Lou Michaels wrote:
Thank you

I follow the steps, installed pyaudio and ran the script. 

Recieved:

ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.front.0:CARD=0'
ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM front
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
ALSA lib confmisc.c:1281:(snd_func_refer) Unable to find definition 'cards.bcm2835_alsa.pcm.surround51.0:CARD=0'
ALSA lib conf.c:4528:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:5007:(snd_config_expand) Evaluate error: No such file or directory


On Sun, Sep 9, 2018 at 10:04 PM Steve N4IRS <szingman@...> wrote:
run it from the command line python usrpaudio.py
you may also need pyaudio
apt-get install python-pyaudio

Steve

On 09/09/2018 10:00 PM, Lou Michaels wrote:
That doesn't seem to have an effect, unless I'm running the py script incorrectly. ( using Thonny)

On Sun, Sep 9, 2018 at 9:53 PM Lou Michaels <w2lmm.qsl@...> wrote:
Sure. 

So return:

outputAudioDevice = /dev/null           ; Audio device /dev/null, /dev/dsp1, po$
inputAudioDevice = /dev/null            ; Only used for dongle mode

And I believe this is stock, save for the last four lines

[USRP]
server = 127.0.0.1                          ; IP address of Allstar/Asterisk
toASLPort = 32001                        ; Analog_Bridge <-- ASL
fromASLPort = 34001                    ; Analog_Bridge --> ASL
aslAudio = AUDIO_USE_GAIN     ; Audio to ASL (AUDIO_UNITY, AUDIO_U$
agcGain = -5                                  ; Gain (in db) of the AGC filter
dmrAudio = AUDIO_USE_GAIN    ; Audio from ASL (AUDIO_UNITY, AUDIO$
dmrGain = 0.6                                ; Gain factor of audio from ASL (0.0-1.0)

Trying the script now. 






On Sun, Sep 9, 2018 at 9:43 PM Mike Zingman - N4IRR <mike.zingman@...> wrote:
Lou,

If you want to help us and play a little:
- Grab the python code in this message: https://dvswitch.groups.io/g/main/message/1340?p=,,,20,0,0,0::relevance,,USRPAudio,20,2,0,19300038
- Return your Analog_Bridge.ini audio section back to stock (turn off AB local audio)
- Make sure your SignalLink is the default audio device
- Make sure your USRP ports in AB.ini are set to the defaults
- Run the python app above and it should get USRP packets from AB and turn them into audio which is output to the default audio device.
- The SL vox should take over the ptt processing.

If you hear audio come out of your radio, then transmit on a local FM radio and press the space bar on the python app (it was ment for another purpose).  If that works, I can port some simple vox code into USRPAudio.py


Join main@DVSwitch.groups.io to automatically receive all group messages.