#3519 BLOC Untriag: csound server broken in 581 due to misconfigured alsa kernel flag

Zarro Boogs per Child bugtracker at laptop.org
Mon Sep 17 12:32:33 EDT 2007


#3519: csound server broken in 581 due to misconfigured alsa kernel flag
----------------------+-----------------------------------------------------
 Reporter:  csounder  |       Owner:  dilinger 
     Type:  defect    |      Status:  new      
 Priority:  blocker   |   Milestone:  Untriaged
Component:  kernel    |     Version:           
 Keywords:            |    Verified:  0        
----------------------+-----------------------------------------------------
 581 release doesn't include the lfloat plugin any more (Build 542 was
 fine). This breaks csound server, and about 7 people are blocked on csound
 work because of it. Details below.

 ----

 From: Greg Thompson <greg at rhythmicdesign.com>
 Date: September 15, 2007 7:46:52 PM EDT
 To: "Dr. Richard Boulanger" <rboulanger at csounds.com>
 Subject: Re: Server not working correctly

 well - im pretty sure the problem lies with the new version of ALSA in
 that it doesn't support the lfloat plugin.


 Discussion about the problem:
 http://www.nabble.com/ALSA-FLoat-sample-format-t4278009.html

 potential fix:
 http://hg-mirror.alsa-project.org/alsa-lib/rev/917d1281c93f


 Flipo_ on IRC said, "that might be the reason why tamtam wasn't working
 after the alsa update"

 I pointed out the line in TamTam

 Flipo_ on IRC said, "yes, that was the line that broke, not sure how it
 was fixed"



 TamTam's code (shown using floats):
 http://dev.laptop.org/git?p=projects/tamtam;a=blob;f=Util/Clooper/aclient.cpp;h=c9e298b32c81bab11845cdb378a07253e32b4c00;hb=cd59da6d5a86c553c2184ba9c7db1a6f939d91a3


 So I'm not sure what they did - if anything - to fix it...  One of the
 many problems that is out of my hands.

 Awaiting a response from Jean...

 greg

 ----

 From: "James Bergstra" <james.bergstra at gmail.com>
 Date: September 16, 2007 3:53:23 PM EDT
 To: "Jean Piché" <jean at piche.com>
 Cc: "Dr. Richard Boulanger" <rboulanger at csounds.com>, "Olivier Bélanger"
 <olivier.belanger at umontreal.ca>, "Nathanael Lécaudé"
 <nat at studioimaginaire.com>, tamtam <tamtam at studioimaginaire.com>, "Greg
 Thompson" <greg at rhythmicdesign.com>, "Wu-Hsi Li" <wuhsi at media.mit.edu>,
 "Richard A. Smith" <richard at laptop.org>, "Jim Gettys" <jg at laptop.org>
 Subject: Re: New version of ALSA - seems to have busted our Csound Server
 - Can you Advise-Help

  I can explain the story behind the diff Jean posted in the previous
 message (the diff is incomplete).

 First, I changed the code to open ALSA in signed short mode:

 snd_pcm_hw_params_set_format(handle, hw, SND_PCM_FORMAT_S16).

 Second, you can see near line 650 in aclient.cpp that I convert csound's
 floating-point output to short samples.  Some of you will know how to
 evaluate the consequences of this algo on audio quality, and maybe have a
 better idea of how to do it.

 This is the current aclient.cpp file:
 http://dev.laptop.org/git?p=projects/tamtam;a=blob;f=common/Util/Clooper/aclient.cpp;h=1146c3b543a84c2e81c45921e3da1f80e097e5fa;hb=HEAD

 - James Bergstra

 On 9/16/07, Jean Piché <jean at piche.com> wrote:
 >
 >
 >
 >
 > Richard et al,
 >
 >
 > I cant recall offhand what it is we did to make that problem go away
 last month. James will know but I bleieve he is away for the weekend.
 We'll have a meeting tomorrow with Olivier and Nat and see what we can do.
 In the meantime, did you look at this:
 >
 >
 >
 http://dev.laptop.org/git?p=projects/tamtam;a=commitdiff;h=bfbc01dd88974b2cc1a143ca8269c4601a285348
 >
 >
 > News tomorrow.
 >
 >
 > j
 >
 >
 >
 >
 >
 > _________________________________
 > http://jeanpiche.com
 >
 >
 >
 >
 >
 >
 >
 >
 >
 > On 16-Sep-07, at 11:56 AM, Dr. Richard Boulanger wrote:
 >
 > Dear Jean, Olivier, Nathanael, and members of the TamTam Team....
 >
 >
 > Hello.  Hope you are all having a productive weekend.
 >
 >
 > I have been working with Greg Thompson, Wu-Hsi Li. and Richard Smith to
 get
 > Greg's Csound Server running with the latest build (581) - so that I can
 run and demo
 > the newest TamTam and also continue to develop and explore Greg's New
 Csound Server and Server Activities.
 >
 >
 > Presently, I have a working version of The Csound Server on one of my B4
 XOs.  It is running perfectly
 > alongside the Summer Version of Tam Tam... (build 542)
 >
 >
 > But...   After Walter's cool demo of the new Tam Tam this past Friday, I
 asked Walter and Jim to give me another B4 to
 > flash with the newest build and begin TamTam Jammin and Network Csound
 Serving...  They said OK... And so,
 > I spent the rest of Friday flashing, installing, and testing....
 >
 >
 > As you know already - and from a previous email from me.....
 > Your new Tam Tam is GREAT and running super on it.   Measure - as you
 also probably know, is very cool too, but
 > kills ALL sound once it is used and so you need to reboot in order to
 use Tam Tam again.
 >
 >
 > Greg's Csound Server, My General MIDI player, and Wu-Shi's MusicPainter
 Activity are all showing up
 > and launching, but they are making NO sound.....
 >
 >
 > Greg has been looking into it....  and it seems that the problem might
 be....
 >
 >
 > that  the new version of ALSA seems to have busted our Csound Server or
 at least floating point audio playback?
 >
 >
 > I think that Greg has been in touch with some of you about this
 yesterday....
 > He seems to think that  the problem lies with the new version of ALSA -
 in that it doesn't support the lfloat plugin.
 >
 >
 > He sent me the following links:
 >
 >
 >
 > A Discussion about the problem:
 > http://www.nabble.com/ALSA-FLoat-sample-format-t4278009.html
 >
 >
 > A potential fix:
 > http://hg-mirror.alsa-project.org/alsa-lib/rev/917d1281c93f
 >
 >
 > Some IRC chat about the problem:
 >
 >
 >
 > Flipo_ on IRC said, "that might be the reason why tamtam wasn't working
 after the alsa update"
 >
 >
 > He pointed out the line in TamTam:
 >
 >
 > Flipo_ on IRC said, "yes, that was the line that broke, not sure how it
 was fixed"
 >
 >
 > Finally,  Greg sent me this link - in which I believe - you have your
 fix to this ALSA problem?
 > It seems that you have solved the problem for tam tam - and we could
 really use your help.
 >
 >
 > TamTam's code (shown using floats):
 >
 http://dev.laptop.org/git?p=projects/tamtam;a=blob;f=Util/Clooper/aclient.cpp;h=c9e298b32c81bab11845cdb378a07253e32b4c00;hb=cd59da6d5a86c553c2184ba9c7db1a6f939d91a3
 >
 >
 >
 >
 > Can you assist, advise?  Hope so...
 >
 >
 > ==
 >
 >
 > Why?  Well.... I am trying to hand off Greg's Csound Server  with his
 model activities to all the Csound5 Developers that Jim Gettys has shipped
 B4 machines in
 > the past week -
 >
 >
 > Victor Lazzarini, Rory Walsh, Steven Yi, John ffitch, Andres Cabrera,
 and a few others...
 >
 >
 > Greg and I are hoping to send them links and instructions so that they
 can flash their machines - get and enjoy and be inspired by the newest Tam
 Tam, Memorize and Measure - all which use sound and two which use Csound5!
 and also get going with the new Csound Server too - which should help them
 to develop their own activities quickly.
 >
 >
 > Here is Greg's Csound Server Code and Models  for you to check out:
 >
 >
 > http://wiki.laptop.org/go/Music
 >
 >
 > ==========
 >
 >
 > So....
 >
 >
 > Any advice you could offer today, tonight, tomorrow would be huge.  I am
 meeting with Jim Gettys tomorrow (Monday) to brainstorm some projects and
 focus for these Csound5 Developers.  I want to be able to hand off Greg's
 work to them.  And so... I will be working with Wu-Hsi (and possibly even
 with Richard some) and Greg
 > too... (online at least - he is now back on Baton Rouge, LA) to solve
 this problem and get closure on this phase of development.
 >
 >
 > Thanks for your time.  Have a great day.  Hopefully you have already
 solved the problem and can pass along to Greg and Richard especially - the
 fix.
 >
 >
 > Dr. B.

 ----

 From: wuhsi at media.mit.edu
 Date: September 17, 2007 2:24:06 AM EDT
 To: "Dr. Richard Boulanger" <rboulanger at csounds.com>
 Subject: Re: New version of ALSA - seems to have busted our Csound Server
 - Can you Advise-Help


 Hey,

 Since I saw the problem you found in the latest build, so I first tried
 csoundserver in my B4 (build 546) without updating it.

 The error message is:
 ALSA lib pcm.c:7142(snd_pcm_set_params) Sample format not available for
 PLAY BACK: Invalid argument

 In the attachment is the musicpainter project folder.

 One special feature is that, you can always run the musicpainter without
 running sugar by executing "python musicpainter.py" (It is because the way
 I sugarize the program make it runnable with/without sugar. )

 Sometimes I found it difficult to track all the error message running
 activities in sugar and therefore, I always first use terminal mode to run
 musicpainter. Hope this will be helpful in some occasion.

 Regards,

 Wu-Hsi

 Quoting "Dr. Richard Boulanger" <rboulanger at csounds.com>:


 Excellent.  Glad to hear.  I will continue working and look forward to
 seeing you tomorrow.

 -dB

 On Sep 17, 2007, at 2:06 AM, wuhsi at media.mit.edu wrote:


 Hi,

 Please ignore the previous mail since I found a precious backup  version
 in my laptop.

 Regards,

 Wu-Hsi

 Quoting "Dr. Richard Boulanger" <rboulanger at csounds.com>:


 I will bring along BOTH XO machines and so we can backup and get your
 code to run on the Macine in the lab too - hopefully, we will be able
 to get it
 working with build 581 as well.

 -dB

 On Sep 17, 2007, at 1:30 AM, wuhsi at media.mit.edu wrote:


 Hi,

 I was trying to make my b4 sing through the musicpainter, but how
 weird....

 My only copy of Musicpainter is the same corrupted version, in   which one
 of the file(csound5agent.py) is truncated in the  middle.  It seems that
 the only complete version on earth is the  one on your  green machine.

 well, I'll need that green machine tomorrow for the file
 "csound5agent.py" or I'll have to rewrite my csoundagent (which
 originally works for csoundxt) again.

 regards,

 wu-hsi

 Quoting "Dr. Richard Boulanger" <rboulanger at csounds.com>:


 See you tomorrow... Greg is working on the ALSA problems...  Seems they
 had to hack ALSA to get TamTam to work!

 -dB

 On Sep 17, 2007, at 12:42 AM, Wu-Hsi Li wrote:


 Hi,

 Thank you for letting me know that my game can create some    obssesion
 for a kid:)
 Sorry I was out all day yesterday and pretty much the same  today.  It
 seems that there
 are so many things for me to catch up, anyway, I'll see you    tomorrow in
 OLPC and we'll
 try to find the SOP for users to run all the csound stuff (and    maybe
 fix the problem
 of the latest build hopefully).

 Regards,

 Wu-Hsi

-- 
Ticket URL: <https://dev.laptop.org/ticket/3519>
One Laptop Per Child <https://dev.laptop.org>
OLPC bug tracking system



More information about the Bugs mailing list