{"id":115,"date":"2005-12-04T14:15:06","date_gmt":"2005-12-04T14:15:06","guid":{"rendered":"http:\/\/www.loeda.net\/?p=115"},"modified":"2010-01-13T13:26:12","modified_gmt":"2010-01-13T12:26:12","slug":"audio-en-freebsd","status":"publish","type":"post","link":"https:\/\/www.loeda.net\/bitacora\/2005\/12\/04\/audio-en-freebsd\/","title":{"rendered":"Audio en FreeBSD"},"content":{"rendered":"<p>Un problema bastante com\u00fan durante la configuraci\u00f3n de la tarjeta de audio en FreeBSd es saber realmente que modulo se debe cargar.<\/p>\n<p>Si se lee el HandBook el proceso es claro pero cargar el modulo no tanto.<\/p>\n<p>Existe un <a href=\"http:\/\/www.freebsdwiki.net\/index.php\/Sound_card:_checking_drivers\">simple script<\/a> que tras ser ejecutado te dice que modulo debes cargar<\/p>\n<p>[sourcecode language=\u00bbbash\u00bb]<br \/>\n #!\/bin\/sh<\/p>\n<p> # Copyright (c) 2004, Romain TARTIERE &lt;romain-tartiere@astase.com&gt;<br \/>\n # All rights reserved.<br \/>\n #<br \/>\n # Redistribution and use in source and binary forms, with or without<br \/>\n # modification, are permitted provided that the following conditions<br \/>\n # are met:<br \/>\n # 1. Redistributions of source code must retain the above copyright<br \/>\n #    notice unmodified, this list of conditions, and the following<br \/>\n #    disclaimer.<br \/>\n # 2. Redistributions in binary form must reproduce the above copyright<br \/>\n #    notice, this list of conditions and the following disclaimer in the<br \/>\n #    documentation and\/or other materials provided with the distribution.<br \/>\n #<br \/>\n # THIS SOFTWARE IS PROVIDED BY THE AUTHOR \u00abAS IS\u00bb AND ANY EXPRESS OR<br \/>\n # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES<br \/>\n # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.<br \/>\n # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,<br \/>\n # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT<br \/>\n # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,<br \/>\n # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY<br \/>\n # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT<br \/>\n # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF<br \/>\n # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.<\/p>\n<p> # Root ?<br \/>\n expr `id -u` = 0 &gt; \/dev\/null || {<br \/>\n \techo &quot;Error: This utility should only be run as root.&quot;<br \/>\n \texit 1<br \/>\n }<\/p>\n<p> # Any driver loaded ?<br \/>\n kldstat | grep &#8216;snd_*&#8217; &gt; \/dev\/null 2&gt;&amp;1 &amp;&amp; {<br \/>\n \techo &quot;Error: No sound driver should be loaded.&quot;<br \/>\n \texit 1<br \/>\n }<\/p>\n<p> cd \/boot\/kernel<\/p>\n<p> Result=\u00bb;\t\t# Drivers that do something<br \/>\n Cnt=`ls snd_* | wc -l`\t# Drivers count<\/p>\n<p> echo -n &#8216;[Trying sound drivers -&#8216; $Cnt &#8216;drivers found &#8216;<br \/>\n for i in snd_*<br \/>\n do<br \/>\n \techo -n &#8216;.&#8217;<br \/>\n \tkldload $i<br \/>\n \t[ -e \/dev\/audio0.0 ] &amp;&amp; Result=&quot;$Result $i&quot;<br \/>\n \tkldunload $i<br \/>\n done<br \/>\n echo &#8216; done]&#8217;<\/p>\n<p> # Print result<br \/>\n echo &quot;===&gt; Usable sound driver(s) : $Result&quot;<\/p>\n<p> # That&#8217;s all folks !<\/p>\n<p>[\/sourcecode]<\/p>\n<p>En mi caso en IBM NetVista el resultado es<\/p>\n<p>[sourcecode language=\u00bbbash\u00bb]<br \/>\nunix# .\/audio.sh [Trying sound drivers &#8211; 25 drivers found &#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;. done] ===&gt;<br \/>\nUsable sound driver(s) : snd_driver.ko snd_maestro3.ko unix#<br \/>\n[\/sourcecode]<\/p>\n<p>El siguiente paso es f\u00e1cil, se edita el fichero \/boot\/loader.conf y se a\u00f1ade las siguientes lineas<\/p>\n<p>[sourcecode language=\u00bbbash\u00bb]<br \/>\nsound_load=&quot;YES&quot;<br \/>\nsnd_maestro3_load=&quot;YES&quot;<br \/>\n[\/sourcecode]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Un problema bastante com\u00fan durante la configuraci\u00f3n de la tarjeta de audio en FreeBSd es saber realmente que modulo se debe cargar. Si se lee el HandBook el proceso es claro pero cargar el modulo no tanto. Existe un simple script que tras ser ejecutado te dice que modulo debes cargar [sourcecode language=\u00bbbash\u00bb] #!\/bin\/sh # [&hellip;]<\/p>\n","protected":false},"author":12,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[755],"tags":[774,765,768,764,770,769],"class_list":["post-115","post","type-post","status-publish","format-standard","hentry","category-software","tag-bsd","tag-codigo-abierto","tag-freebsd","tag-open-source","tag-os","tag-sistemas-operativos","author-emilio"],"_links":{"self":[{"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/posts\/115","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/comments?post=115"}],"version-history":[{"count":0,"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/posts\/115\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/media?parent=115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/categories?post=115"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.loeda.net\/bitacora\/wp-json\/wp\/v2\/tags?post=115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}