Bug 11015 - (swajime) test/sample programs of alsa-lib do not run successfully
(swajime)
: test/sample programs of alsa-lib do not run successfully
Status: RESOLVED WONTFIX
Product: Development platform
SDK
: 4.1.2 (5.2008.43-7)
: N810 Maemo
: Unspecified major with 1 vote (vote)
: ---
Assigned To: Marcell Lengyel
: sdk-bugs
: http://www.swajime.com/n810/alsa-lib_...
:
:
:
  Show dependency tree
 
Reported: 2010-07-27 06:21 UTC by john
Modified: 2010-08-04 05:08 UTC (History)
2 users (show)

See Also:


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description john (reporter) 2010-07-27 06:21:05 UTC
SOFTWARE VERSION:
5.2008.43-7

EXACT STEPS LEADING TO PROBLEM: 
(Explain in detail what you do (e.g. tap on OK) and what you see (e.g. message
Connection Failed appears))
1. apt-get source libasound2   
2. cd alsa-lib-1.0.14sa
3. ./configure
4. make
5. sudo make install
6. make check
7. test/pcm_min

EXPECTED OUTCOME:
Audio output to speaker(s).

ACTUAL OUTCOME:
Playback open error: Inappropriate ioctl for device

REPRODUCIBILITY:
always

EXTRA SOFTWARE INSTALLED:
build-essential_10.1osso1
coreutils-5.2.1-2osso2
gawk_3.1.4-2osso.2 grep
grep_2.5.1.ds1-4
tar_1.20-1maemo4

OTHER COMMENTS:
The other test programs for alsa-lib/libasound2 also fail to run.
I have a full log at http://www.swajime.com/n810/alsa-lib_1.0.14sa-2maemo2.log

Package Info:
alsa-lib_1.0.14sa-2maemo2.dsc 
Format: 1.0
Source: alsa-lib
Version: 1.0.14sa-2maemo2
Binary: lib32asound2-dev, lib64asound2, lib32asound2, libasound2-dev,
libasound2, libasound2-doc, libasound2-dbg, lib64asound2-dev
Maintainer: Debian ALSA Maintainers <pkg-alsa-devel@lists.alioth.debian.org>
Architecture: any
Standards-Version: 3.7.2
Build-Depends: debhelper (>= 4.2.32), quilt (>= 0.40), autotools-dev, doxygen,
libc6-dev-powerpc [ppc64], libc6-dev-i386 [amd64], libc6-dev-ppc64 [powerpc],
libc6-dev-s390x [s390], libc6-dev-sparc64 [sparc], lib32gcc1 [amd64 ppc64],
libc6-dev (>= 2.5) [armel]
Vcs-Browser: http://svn.debian.org/wsvn/pkg-alsa/trunk/alsa-lib/
Uploaders: Jordi Mallach <jordi@debian.org>, Mikael Magnusson
<mikma@users.sourceforge.net>, Elimar Riesebieter <riesebie@lxtec.de>,
Marc-Andre Lureau <marc-andre.lureau@nokia.com>
Vcs-Svn: svn://svn.debian.org/pkg-alsa/trunk/alsa-lib
Files: 
 5542a18a1479e4de4b9890e30e94588e 1099165 alsa-lib_1.0.14sa.orig.tar.gz
 fc02aa3dbf2f66fb090e02ada703cc1d 47455 alsa-lib_1.0.14sa-2maemo2.diff.gz

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.7)
Gecko/20100715 Ubuntu/8.04 (hardy) Firefox/3.6.7

I wish to get this working.  I will gladly provide any other information that
can help.
Comment 1 Andre Klapper maemo.org 2010-07-29 02:49:37 UTC
Thanks for your report.

Unfortunately it is a WONTFIX for Maemo4 as Maemo4 is in maintenance mode and
Nokia will only provide bugfixes for critical issues, if at all (quite
unlikely).
For your interest the Mer project aims to provide a community backport of
Fremantle for N8x0 devices. See http://wiki.maemo.org/Mer for more information.
Comment 2 john (reporter) 2010-07-29 09:09:44 UTC
The results are identical for Mer:

john@john-tablet:~/src/alsa-lib-1.0.18$ test/control
Soundcard #1:
  card - 0
  id - 'EAC'
  driver - 'EAC'
  name - 'OMAP24xx EAC'
  longname - 'OMAP24xx EAC with codec TLV320AIC33'
  mixername - 'TLV320AIC33'
  components - ''
  PCM next device error: Inappropriate ioctl for device
  RAWMIDI next device error: Inappropriate ioctl for device
john@john-tablet:~/src/alsa-lib-1.0.18$ test/pcm_min
Playback open error: Inappropriate ioctl for device
Comment 3 john (reporter) 2010-07-29 18:25:47 UTC
(In reply to comment #1)
> Thanks for your report.
> 
> Unfortunately it is a WONTFIX for Maemo4 as Maemo4 is in maintenance mode and
> Nokia will only provide bugfixes for critical issues, if at all (quite
> unlikely).
> For your interest the Mer project aims to provide a community backport of
> Fremantle for N8x0 devices. See http://wiki.maemo.org/Mer for more information.
> 

I got the same error on Mer: 
john@john-tablet:~/src/alsa-lib-1.0.18$ uname -a
Linux john-tablet 2.6.21-omap1 #2 Tue Oct 14 11:25:25 EEST 2008 armv6l
GNU/Linux
john@john-tablet:~/src/alsa-lib-1.0.18$ cat /etc/lsb-
lsb-base/            lsb-base-logging.sh  lsb-release          
john@john-tablet:~/src/alsa-lib-1.0.18$ cat /etc/lsb-release 
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=9.04
DISTRIB_CODENAME=jaunty
DISTRIB_DESCRIPTION="Ubuntu 9.04"
john@john-tablet:~/src/alsa-lib-1.0.18$ test/pcm_min 
Playback open error: Inappropriate ioctl for device

I have the full log here -> http://www.swajime.com/n810/mer-alsa-lib.log

Should I open a separate bug report?
Comment 4 Andre Klapper maemo.org 2010-07-30 13:25:39 UTC
Yes, if Mer is actively maintained.
Comment 5 john (reporter) 2010-08-04 05:08:13 UTC
After setting up these packages in my jaunty chroot ( from
http://talk.maemo.org/showthread.php?t=27735 ), and much thrashing
(log lost), I managed to get pcm.c working both in jaunty and in
diablo:

  libpci3 (1:3.0.0-4ubuntu8) ...
  lsof (4.78.dfsg.1-4) ...
  pciutils (1:3.0.0-4ubuntu8) ...
  linux-sound-base (1.0.18.dfsg-1ubuntu8) ...
  alsa-base (1.0.18.dfsg-1ubuntu8) ...
  alsa-utils (1.0.18-1ubuntu11) ...

I'm not exactly sure if that's what fixed it or if it was something I
did via diablo.
So ... based on this new evidence, I don't think it's the kernel or the driver.

Also, now that I got it working ...
If I run play-sound, it no longer works.

[1|user@Nokia-N810-43-7|~]alsa-lib-1.0.14sa/test/pcm -vD default
Playback device is default
Stream parameters are 44100Hz, S16_LE, 1 channels
Sine wave rate is 440.0000Hz
Using transfer method: write
Alsa - DSP PCM Plugin
Its setup is:
  stream       : PLAYBACK
  access       : RW_INTERLEAVED
  format       : S16_LE
  subformat    : STD
  channels     : 1
  rate         : 44100
  exact rate   : 44100 (44100/1)
  msbits       : 16
  buffer_size  : 2048
  period_size  : 1024
  period_time  : 23219
  tick_time    : 0
  tstamp_mode  : NONE
  period_step  : 1
  sleep_min    : 0
  avail_min    : 1024
  xfer_align   : 1
  start_threshold  : 2048
  stop_threshold   : 2048
  silence_threshold: 0
  silence_size : 0
  boundary     : 1073741824

[1|user@Nokia-N810-43-7|~]play-sound /usr/share/sounds/game-chess_checkmate.wav
[1|user@Nokia-N810-43-7|~]alsa-lib-1.0.14sa/test/pcm -vD default
Playback device is default
Stream parameters are 44100Hz, S16_LE, 1 channels
Sine wave rate is 440.0000Hz
Using transfer method: write

[1|user@Nokia-N810-43-7|~]