pierr3 / VectorAudio

An Audio-For-VATSIM ATC Client for macOS, Linux and Windows
GNU General Public License v3.0
48 stars 11 forks source link

Linux: API and Voice stays Red, connect button not working #23

Closed flymia closed 2 years ago

flymia commented 2 years ago

When using VectorAudio on Linux I am not able to connect to the audio servers. The API and Voice indicators stay red and the connect button does nothing.

However, it notices that I'm connected to VATSIM, so the API is working.

screenshot-2022-10-09-01-17-28

I've attached the log, so you can see what's happening while launching.

OS: Arch Linux Compiled by myself.

before paHostApiInitializers[0].
ALSA version (build): 1.2.7.2
ALSA version (runtime): 1.2.7.2
BuildDeviceList: Found device [0]: HDA Intel PCH: ALC892 Analog (hw:0,0)
BuildDeviceList: Found device [1]: HDA Intel PCH: ALC892 Alt Analog (hw:0,2)
BuildDeviceList: Found device [2]: HDA NVidia: MSI MP271Q    (hw:1,3)
BuildDeviceList: Found device [3]: HDA NVidia: ROG PG278QR   (hw:1,7)
BuildDeviceList: Found device [4]: HDA NVidia: HDMI 2 (hw:1,8)
BuildDeviceList: Found device [5]: HDA NVidia: HDMI 3 (hw:1,9)
BuildDeviceList: Found device [6]: HDA NVidia: HDMI 4 (hw:1,10)
BuildDeviceList: Found device [7]: HDA NVidia: HDMI 5 (hw:1,11)
BuildDeviceList: Found device [8]: HDA NVidia: HDMI 6 (hw:1,12)
BuildDeviceList: Found device [9]: Sennheiser 3D G4ME1: USB Audio (hw:2,0)
BuildDeviceList: Ignoring ALSA plugin device [hw] of type [hw]
BuildDeviceList: Ignoring ALSA plugin device [plughw] of type [plug]
BuildDeviceList: Ignoring ALSA plugin device [plug] of type [plug]
BuildDeviceList: Ignoring ALSA plugin device [shm] of type [shm]
BuildDeviceList: Ignoring ALSA plugin device [tee] of type [file]
BuildDeviceList: Ignoring ALSA plugin device [file] of type [file]
BuildDeviceList: Ignoring ALSA plugin device [null] of type [null]
BuildDeviceList: Ignoring ALSA plugin device [cards] of type [unknown]
BuildDeviceList: Found plugin [default] of type [unknown]
BuildDeviceList: Found plugin [sysdefault] of type [unknown]
BuildDeviceList: Found plugin [front] of type [unknown]
BuildDeviceList: Found plugin [rear] of type [unknown]
BuildDeviceList: Found plugin [center_lfe] of type [unknown]
BuildDeviceList: Found plugin [side] of type [unknown]
BuildDeviceList: Found plugin [surround21] of type [unknown]
BuildDeviceList: Found plugin [surround40] of type [unknown]
BuildDeviceList: Found plugin [surround41] of type [unknown]
BuildDeviceList: Found plugin [surround50] of type [unknown]
BuildDeviceList: Found plugin [surround51] of type [unknown]
BuildDeviceList: Found plugin [surround71] of type [unknown]
BuildDeviceList: Found plugin [iec958] of type [unknown]
BuildDeviceList: Found plugin [spdif] of type [unknown]
BuildDeviceList: Found plugin [hdmi] of type [unknown]
BuildDeviceList: Found plugin [dmix] of type [unknown]
BuildDeviceList: Ignoring ALSA plugin device [dsnoop] of type [unknown]
BuildDeviceList: Found plugin [modem] of type [unknown]
BuildDeviceList: Found plugin [phoneline] of type [unknown]
BuildDeviceList: Filling device info for 28 devices
FillInDevInfo: Filling device info for: HDA Intel PCH: ALC892 Analog (hw:0,0)
GropeDevice: collecting info ..
GropeDevice: collecting info ..
Default input device: HDA Intel PCH: ALC892 Analog (hw:0,0)
Default output device: HDA Intel PCH: ALC892 Analog (hw:0,0)
FillInDevInfo: Adding device HDA Intel PCH: ALC892 Analog (hw:0,0): 0
FillInDevInfo: Filling device info for: HDA Intel PCH: ALC892 Alt Analog (hw:0,2)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA Intel PCH: ALC892 Alt Analog (hw:0,2): 1
FillInDevInfo: Filling device info for: HDA NVidia: MSI MP271Q    (hw:1,3)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: MSI MP271Q    (hw:1,3): 2
FillInDevInfo: Filling device info for: HDA NVidia: ROG PG278QR   (hw:1,7)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: ROG PG278QR   (hw:1,7): 3
FillInDevInfo: Filling device info for: HDA NVidia: HDMI 2 (hw:1,8)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: HDMI 2 (hw:1,8): 4
FillInDevInfo: Filling device info for: HDA NVidia: HDMI 3 (hw:1,9)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: HDMI 3 (hw:1,9): 5
FillInDevInfo: Filling device info for: HDA NVidia: HDMI 4 (hw:1,10)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: HDMI 4 (hw:1,10): 6
FillInDevInfo: Filling device info for: HDA NVidia: HDMI 5 (hw:1,11)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: HDMI 5 (hw:1,11): 7
FillInDevInfo: Filling device info for: HDA NVidia: HDMI 6 (hw:1,12)
GropeDevice: collecting info ..
FillInDevInfo: Adding device HDA NVidia: HDMI 6 (hw:1,12): 8
FillInDevInfo: Filling device info for: Sennheiser 3D G4ME1: USB Audio (hw:2,0)
OpenPcm: Failed to open busy device 'hw:2,0'
OpenPcm: Failed to open busy device 'hw:2,0'
FillInDevInfo: Skipped device: Sennheiser 3D G4ME1: USB Audio (hw:2,0), all channels == 0
FillInDevInfo: Filling device info for: sysdefault
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
FillInDevInfo: Adding device sysdefault: 9
FillInDevInfo: Filling device info for: front
GropeDevice: collecting info ..
FillInDevInfo: Adding device front: 10
FillInDevInfo: Filling device info for: rear
ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
OpenPcm: Opened device 'rear' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: rear, all channels == 0
FillInDevInfo: Filling device info for: center_lfe
ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
OpenPcm: Opened device 'center_lfe' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: center_lfe, all channels == 0
FillInDevInfo: Filling device info for: side
ALSA lib pcm.c:2664:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
OpenPcm: Opened device 'side' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: side, all channels == 0
FillInDevInfo: Filling device info for: surround21
ALSA lib pcm_route.c:877:(find_matching_chmap) Found no matching channel map
OpenPcm: Opened device 'surround21' ptr[(nil)] - result: [-22:Invalid argument]
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
FillInDevInfo: Adding device surround21: 11
FillInDevInfo: Filling device info for: surround40
GropeDevice: collecting info ..
FillInDevInfo: Adding device surround40: 12
FillInDevInfo: Filling device info for: surround41
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
FillInDevInfo: Adding device surround41: 13
FillInDevInfo: Filling device info for: surround50
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
FillInDevInfo: Adding device surround50: 14
FillInDevInfo: Filling device info for: surround51
GropeDevice: collecting info ..
FillInDevInfo: Adding device surround51: 15
FillInDevInfo: Filling device info for: surround71
GropeDevice: collecting info ..
FillInDevInfo: Adding device surround71: 16
FillInDevInfo: Filling device info for: iec958
OpenPcm: Opened device 'iec958' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: iec958, all channels == 0
FillInDevInfo: Filling device info for: spdif
OpenPcm: Opened device 'spdif' ptr[(nil)] - result: [-2:No such file or directory]
OpenPcm: Opened device 'spdif' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: spdif, all channels == 0
FillInDevInfo: Filling device info for: hdmi
OpenPcm: Opened device 'hdmi' ptr[(nil)] - result: [-2:No such file or directory]
OpenPcm: Opened device 'hdmi' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: hdmi, all channels == 0
FillInDevInfo: Filling device info for: modem
OpenPcm: Opened device 'modem' ptr[(nil)] - result: [-2:No such file or directory]
OpenPcm: Opened device 'modem' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: modem, all channels == 0
FillInDevInfo: Filling device info for: phoneline
OpenPcm: Opened device 'phoneline' ptr[(nil)] - result: [-2:No such file or directory]
OpenPcm: Opened device 'phoneline' ptr[(nil)] - result: [-2:No such file or directory]
FillInDevInfo: Skipped device: phoneline, all channels == 0
FillInDevInfo: Filling device info for: default
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
GropeDevice: collecting info ..
GropeDevice: Limiting number of plugin channels to 128
Default input device: default
Default output device: default
FillInDevInfo: Adding device default: 17
FillInDevInfo: Filling device info for: dmix
GropeDevice: collecting info ..
FillInDevInfo: Adding device dmix: 18
BuildDeviceList: Building device list took 0.284094 seconds
after paHostApiInitializers[0].
before paHostApiInitializers[1].
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
JackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock
PaJack_Initialize: Couldn't connect to JACK, status: 17
after paHostApiInitializers[1].
TerminateHostApis in 
TerminateHostApis out
jonaseberle commented 2 years ago

Last week it worked for me.

Now it gets green but turns red after 10s or so.

But my logs look differently. I don't have your

Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel

I think that is API related.

My problem looks rather like a local audio problem:

JackXRunCb: JACK signalled xrun
PaUnixThread_New: Waited for 0.0129411 seconds for stream to start
ContinuePoll: Stopping poll for capture
CallbackThreadFunc: Input underflow
CallbackThreadFunc: Input underflow
CallbackThreadFunc: Input underflow
Stopping callback
PaUnixThread_Terminate: Joining thread 1870304960
...

(Manjaro Linux)

flymia commented 2 years ago

OK, I've seen new log messages in the afv.log, which point out the error:

Sun Oct  9 01:14:24 2022: APISession: /home/marc/git/vectoraudio/VectorAudio/extern/afv-native/src/afv/APISession.cpp(208): got error from API server: Response Code 403
Sun Oct  9 01:14:24 2022: afv_native::ATCClient: /home/marc/git/vectoraudio/VectorAudio/extern/afv-native/src/core/atcClient.cpp(208): Got error from AFV API Server.  Disconnecting session
flymia commented 2 years ago

Alright, I've found the error. For some reason a wrong password was set...I'm sorry for the inconvenience. 🙈