Xoscope doesn't work on soundcard (No valid data sources found... exiting)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
xoscope (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
Oneiric |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Starting xoscope gives always the error.
No valid data sources found... exiting
I think the problem is located in the changed behavior in /dev/dsp. Launching with padsp -d shows:
utils/padsp.c: dsp_open()
utils/padsp.c: fd_info_new()
utils/padsp.c: dsp_open() succeeded, fd=8
utils/padsp.c: unknown ioctl 0xffffffffc0045006
utils/padsp.c: freeing fd info (fd=8)
utils/padsp.c: Draining.
No valid data sources found... exiting
xoscope version is 2.0-3.1ubuntu1 on ubuntu 11.10
[Impact]
Xoscope doesn't work at all on 64 bit architecture. The only way to make it work, is to execute on 32 bit arch only with padsp (raw dsp device was disabled in Ubuntu). The software was conceived to use raw dsp audio as fallback mechanism, but in this case, it is the only way to make it work whit a soundcard. On 64 bit arch, due to the wrong ioctl parameter, it does not work at all, nor with esd (disabled at compile time) nor with padsp.
[Development Fix]
The fix use unsigned integer to call the ioctl, calling it the right way. This solve the padsp bug. Patch enables also the esd support by adding libesd0-dev to the compiler dependency. In this way, xoscope can work as it was conceived, using the soundcard via libraries instead accessing the raw device (/dev/dsp). The patch also set the defaut client mode to record, instead of monitor, it works better in pulseaudio. This change is not desruptive because the option could be changed at runtime using a menu inside the software. The only modified package is xoscope upgraded to version 2.0-3.1ubuntu2.
[Stable Fix]
Patch accepted for the development fix it applicabile also at the stable one, because the package was at the same version number before the patch was accepted.
[Test Case]
To reproduce the bug (32 and 64 bits arch):
1) Open xoscope from the commandline.
2) the software cannot find nor the /dev/dsp nor the esd soundcard so it fails whit the error: "No valid data sources found... exiting"
On 32 bits arch:
1) Open the software from commandline with "padsp xoscope"
2) the software works as expected using the virtual /dev/dsp provided by padsp
On 64 bits arch:
1) Open the software from commandline with "padsp xoscope"
2) Software doesn't work and prints the output "No valid data sources found... exiting"
3) starting the software with "padsp -d xoscope" prints the output:
utils/padsp.c: dsp_open()
utils/padsp.c: fd_info_new()
utils/padsp.c: dsp_open() succeeded, fd=8
utils/padsp.c: unknown ioctl 0xffffffffc0045006
utils/padsp.c: freeing fd info (fd=8)
utils/padsp.c: Draining.
No valid data sources found... exiting
Please note the wrong ioctl integer (0xffffffffc004
[Regression Potential]
I think there are no regressions here because the patch changes only an unisigned integer.
Related branches
- Bhavani Shankar: Pending requested
-
Diff: 49 lines (+10/-3)3 files modifieddebian/changelog (+7/-0)
debian/control (+1/-1)
sc_linux.c (+2/-2)
- Bhavani Shankar: Pending requested
- Matthias Klose: Pending requested
-
Diff: 49 lines (+10/-3)3 files modifieddebian/changelog (+7/-0)
debian/control (+1/-1)
sc_linux.c (+2/-2)
Changed in xoscope (Ubuntu Oneiric): | |
status: | New → Triaged |
importance: | Undecided → Medium |
description: | updated |
Changed in xoscope (Ubuntu Oneiric): | |
status: | Triaged → Fix Committed |
tags: |
added: verification-done removed: verification-needed |
Ok, I found the bug, I attached the solutive patch. With this patch, xoscope could be invoked with aoss or padsp without errors.
Problem araises when ioctl value is passed on 64 bit via a signed integer in method check_status_ioctl in sc_linux.c .
I found what I think could be a second bug, xoscope is not compiled with esound support.
There is a bug on the stock Ubuntu oneiric that prevents major esound compatibility (https:/ /bugs.launchpad .net/ubuntu/ +source/ pulseaudio/ +bug/864071) and also after upgrading the package to oneiric-proposed, xoscope could not work with esound compatibility.
So I recompiled the ubuntu package (from apt-get source xoscope) enabling esound (it suffices to install the esound libesd0-dev package) and ensured that the proper configure flags was set.
After the recopilation process finished, I installed the package and it worked!
So I think the package should be recompiled with esound support (so setting the HAVE_LIBESD flag).