Node 6.2.9260 problems

Madsonic Node 6.x

Node 6.2.9260 problems

Unread postby IrishMLK » 27 Feb 2017, 07:41

I am running the standalone linux version 9260 on r-pi3.

After chmod 0777 the transcode folder and forcing java 8 I have gotten to this point... I have verified via banshee that my hifiberry is functional by testing an mp3.
I feel like i am THIS close to a working node... thanks for any help!

Below is an excerpt from the madsonic-node.sh.log

[2017-02-27 06:05:46] [DEBUG] [qtp33407056-15] NodeController - Set new Madsonic server credential.
[2017-02-27 06:05:46] [DEBUG] [qtp33407056-15] NodeController - Host: http://192.168.xx.xx:4040/default
[2017-02-27 06:05:46] [DEBUG] [qtp33407056-15] NodeController - Username: node
[2017-02-27 06:05:46] [DEBUG] [qtp33407056-15] NodeController - Password: enc:pw hash
[2017-02-27 06:05:50] [INFO ] [qtp33407056-12] PlaylistController - Playing stream - http://192.168.xx.xx:4040/rest2/stream. ... e&p=enc:pw hash&id=29313 offset: 0
[2017-02-27 06:05:50] [INFO ] [/var/madsonic-node/transcode/ffmpeg InputStreamLogger] InputStreamReaderThread - (/var/madsonic-node/transcode/ffmpeg) /var/madsonic-node/transcode/ffmpeg: 1: /var/madsonic-node/transcode/ffmpeg: Syntax error: ")" unexpected
[2017-02-27 06:05:50] [DEBUG] [qtp33407056-12] LocalAudioPlayer - Opened line com.sun.media.sound.DirectAudioDevice$DirectSDL@cf6a09
[2017-02-27 06:05:50] [DEBUG] [qtp33407056-12] PlaylistController - changeState: PLAYING
[2017-02-27 06:05:50] [DEBUG] [Thread-13] PlaylistController - changeState: EOM
[2017-02-27 06:05:50] [DEBUG] [Thread-13] LocalAudioPlayer - CLOSED line com.sun.media.sound.DirectAudioDevice$DirectSDL@cf6a09
[2017-02-27 06:11:25] [INFO ] [qtp33407056-14] PlaylistController - Playing stream - http://192.168.xx.xx:4040/rest2/stream. ... e&p=enc:pw hash&id=29315 offset: 0
[2017-02-27 06:11:25] [INFO ] [/var/madsonic-node/transcode/ffmpeg InputStreamLogger] InputStreamReaderThread - (/var/madsonic-node/transcode/ffmpeg) /var/madsonic-node/transcode/ffmpeg: 1: /var/madsonic-node/transcode/ffmpeg: Syntax error: ")" unexpected
[2017-02-27 06:11:25] [DEBUG] [qtp33407056-14] LocalAudioPlayer - Opened line com.sun.media.sound.DirectAudioDevice$DirectSDL@1e3f986
[2017-02-27 06:11:25] [DEBUG] [qtp33407056-14] PlaylistController - changeState: PLAYING
[2017-02-27 06:11:25] [DEBUG] [Thread-14] PlaylistController - changeState: EOM
[2017-02-27 06:11:25] [DEBUG] [Thread-14] LocalAudioPlayer - CLOSED line com.sun.media.sound.DirectAudioDevice$DirectSDL@1e3f986
[2017-02-27 06:26:37] [INFO ] [qtp33407056-16] PlaylistController - Playing stream - http://192.168.xx.xx:4040/rest2/stream. ... e&p=enc:pw hash&id=29315 offset: 0
[2017-02-27 06:26:37] [INFO ] [/var/madsonic-node/transcode/ffmpeg InputStreamLogger] InputStreamReaderThread - (/var/madsonic-node/transcode/ffmpeg) /var/madsonic-node/transcode/ffmpeg: 1: /var/madsonic-node/transcode/ffmpeg: Syntax error: ")" unexpected
[2017-02-27 06:26:37] [DEBUG] [qtp33407056-16] LocalAudioPlayer - Opened line com.sun.media.sound.DirectAudioDevice$DirectSDL@9d8d7d
[2017-02-27 06:26:37] [DEBUG] [qtp33407056-16] PlaylistController - changeState: PLAYING
[2017-02-27 06:26:37] [DEBUG] [Thread-15] PlaylistController - changeState: EOM
[2017-02-27 06:26:37] [DEBUG] [Thread-15] LocalAudioPlayer - CLOSED line com.sun.media.sound.DirectAudioDevice$DirectSDL@9d8d7d
IrishMLK
Contributor
Contributor
 
Posts: 5
Joined: 21 Jan 2014, 04:45
Has thanked: 1 time
Been thanked: 3 times

Re: Node 6.2.9260 problems

Unread postby IrishMLK » 28 Feb 2017, 06:59

Got it working this evening using the link below to add libx264 and clean ffmpeg.

http://engineer2you.blogspot.com/2016/10/rasbperry-pi-ffmpeg-install-and-stream.html

I followed the instructions for first two steps and then renamed the ffmpeg file in the /var/madsonic-node/transcode/ folder. I then copied the new ffmpeg from /usr/src/ffmpeg/ to the transcode folder above using the command below:

Code: Select all
sudo cp ffmpeg /var/madsonic-node/transcode/


I didn't even need to restart the Pi before things started working. I tested mp3 and flac streaming successfully. Now if only the madsonic android app had a node control option... :thumbsup:

Also, is there a way to update the node local webgui to be more user friendly like the node control frame in the main madsonic webgui? I can't stand the XML tab that opens in Chrome everytime you click a command. This may facilitate using a small touch screen with the Pi to control playback.

XML tab content from clicking "Start" on the node local webgui:
Code: Select all
This XML file does not appear to have any style information associated with it. The document tree is shown below.
<madsonic-response xmlns="http://madsonic.org/restapi" status="ok" version="2.5.0" type="node">
<nodeStatus currentIndex="15" playing="true" gain="0.75" position="0" registered="false"/>
</madsonic-response>


Node webgui code:
Code: Select all
<HTML><title>Madsonic-Node</title><HEAD><link rel='shortcut icon' href='img/fav.ico' type='text/css'></HEAD><STYLE>@import url('http://fonts.googleapis.com/css?family=Montserrat:400,700');body {background-image:url('img/back.png');background-repeat:no-repeat;background-position:top left;background-size:cover;margin:0 0 0 0;padding:20px;font-size:13px;} body, form, h1, h2, label, table, a, select, input {font-family: 'Montserrat', arial, sans-serif !important;}a {font-weight:700;}</STYLE><BODY><div style='width:280px'><img src='img/node.png'style='width:100px'></img><h2><B>MADSONIC NODE REST API 2.5.0</B></h2>see <a href='http://www.madsonic.org'>online</a> for more details.<br><br><hr><b>USR:</b> node<br><b>SRV:</b> http://192.168.10.15:4040<br><hr><br><a href='rest/node.view/setCredential/admin/admin/false/localhost:4040/default' target='new'>/setCredential ...</a><br><br><a href='rest/node.view/register' target='new'>/register</a><br><a href='rest/node.view/unregister' target='new'>/unregister</a><br><br><a href='rest/node.view/status' target='new'>/status</a><br><a href='rest/node.view/set/1,2,3' target='new'>/set/1,2,3 ...</a><br><a href='rest/node.view/get' target='new'>/get</a><br><br><a href='rest/node.view/start' target='new'>/start</a><br><a href='rest/node.view/skip' target='new'>/skip</a><br><a href='rest/node.view/skip/0/0' target='new'>/skip/?/?</a><br><a href='rest/node.view/pause' target='new'>/pause</a><br><a href='rest/node.view/resume' target='new'>/resume</a><br><a href='rest/node.view/stop' target='new'>/stop</a><br><a href='rest/node.view/clear' target='new'>/clear</a><br></div></body></html>


Madsonic frame buttons:
Code: Select all
 <table class="indent" id="nodesTable" >
        <tr>
            <th colspan="8" style="padding-left:1em"></th>
            <th>Node URL</th>
            <th>Node Name</th>
            <th style="padding-left:15px">Online</th>
            <th style="padding-left:5px">Enabled</th>
            <th style="padding-left:5px">Delete</th>
        </tr>
       
            <tr>
                <td><input type="submit" name="open[2]" value="open" onclick="window.open('http://192.168.10.246:8181','_blank')"/></td>
                <td><input type="button" name="start[2]" value="start" onclick="controlNode('http://192.168.10.246:8181','start')"/></td>
                <td><input type="button" name="pause[2]" value="pause" onclick="controlNode('http://192.168.10.246:8181', 'pause')"/></td>
                <td><input type="button" name="resume[2]" value="resume" onclick="controlNode('http://192.168.10.246:8181', 'resume')"/></td>
                <td><input type="button" name="skip[2]" value="skip" onclick="controlNode('http://192.168.10.246:8181', 'skip')"/></td>
                <td><input type="button" name="stop[2]" value="stop" onclick="controlNode('http://192.168.10.246:8181', 'stop')"/></td>
                <td><input type="button" name="transfer[2]" value="transfer" onclick="send2Nodes('http://192.168.10.246:8181')"/></td>
                <td><input type="button" name="config[2]" value="config" onclick="configNode('http://192.168.10.246:8181')"/></td>
                <td><input type="text" name="url[2]" size="25" value="http://192.168.10.246:8181"/></td>
                <td style="padding-right:10px"><input type="text" name="name[2]" size="20" value="NODE-192.168.10.246"/></td>
                <td align="center" class=online><input disabled type="checkbox" checked name="online[2]" class="checkbox"/></td>
                <td align="center" class=online><input type="checkbox" checked name="enabled[2]" class="checkbox"/></td>
                <td align="center" style="padding-left:1em"><input type="checkbox" name="delete[2]" class="checkbox"/></td>
            </tr>
       
        <tr>
            <th colspan="8" style="padding-left:1em"></th>
            <th align="left" style="padding-top:1em">Add Node device</th>
        </tr>
       
        <tr>
            <td colspan="8"> </td>
            <td ><input type="text" name="url" size="25" placeholder="Node URL"/></td>
            <td><input type="text" name="name" size="20" placeholder="Node Name"/></td>
            <td align="center" class="online"><input name="online" checked type="checkbox" class="checkbox"/></td>
            <td align="center" class="online"><input name="enabled" checked type="checkbox" class="checkbox"/></td>
            <td/>
        </tr>
        <tr>
     
            <td style="padding-top:1.5em" colspan="8"></td>
        </tr>
    </table>


Hope this helps someone.
IrishMLK
Contributor
Contributor
 
Posts: 5
Joined: 21 Jan 2014, 04:45
Has thanked: 1 time
Been thanked: 3 times

Re: Node 6.2.9260 problems

Unread postby IrishMLK » 28 Feb 2017, 15:34

Got to work today with my node and hooked it up to the stereo in my office and was able to set the server credentials via REST. Only problem now is that the API does not allow to force registration from a remote network. It looks like it is limited to a broadcast subnet.

log detail:
Code: Select all
[2017-02-28 14:17:18] [DEBUG] [qtp33407056-16] NodeController - Set new Madsonic server credential.
[2017-02-28 14:17:18] [DEBUG] [qtp33407056-16] NodeController - Host: http://XXXX.xxx:xxxx/default
[2017-02-28 14:17:18] [DEBUG] [qtp33407056-16] NodeController - Username: admin
[2017-02-28 14:17:18] [DEBUG] [qtp33407056-16] NodeController - Password: enc:pw hash
[2017-02-28 14:19:04] [DEBUG] [Thread-16] BroadcastRegister - Request packet data: REGISTER_MADSONIC_NODE_REQUEST_31302e37362e352e32393a38313831
[2017-02-28 14:19:04] [DEBUG] [Thread-16] BroadcastRegister - Request packet sent to: 10.xx.xx.xx; Interface: eth0
[2017-02-28 14:19:04] [DEBUG] [Thread-16] BroadcastRegister - Done looping over all network interfaces. Now waiting for a reply!


Will remote nodes be possible?

Side note - I am so glad I moved to Madsonic from Subsonic. It is features like the node and common-sense GUI variations that make me wish I had switched much earlier. Thanks for all your efforts!
IrishMLK
Contributor
Contributor
 
Posts: 5
Joined: 21 Jan 2014, 04:45
Has thanked: 1 time
Been thanked: 3 times

Re: Node 6.2.9260 problems

Unread postby IrishMLK » 06 Mar 2017, 04:12

In case this will help

=========================================================================================
VERSION: MADSONIC-NODE 6.2 | BUILD: 9260
SERVLET: JETTY
SERVER: VM ESXI: 4cores | ARCH: X64 | MEMORY: 4GB
OS: Raspbian Jessie w\ Pixel
SYSTEM: RASPBERRY PI
INSTALLER: STANDALONE
JAVA: ORACLE JDK 1.8
BROWSER: CHROME 56
DESCRIPTION: Cannot register node from remote network
REPRODUCIBLE: YES
=========================================================================================
IrishMLK
Contributor
Contributor
 
Posts: 5
Joined: 21 Jan 2014, 04:45
Has thanked: 1 time
Been thanked: 3 times

Re: Node 6.2.9260 problems

Unread postby piretro999 » 29 May 2017, 14:56

Hello, I just installed my node on a raspberry pi zero w, running the last raspbian with pixel.
the installation went good and the node is accessing the server. However I am not able to play any music/playlist. :(
Here is the log of the exception thrown by the node.
Can anyone explain what does it means? should I have to modify something?
(In the meantime I am also following the way indicated by IrishMLK)

--------------------------HERE IS THE LOG--------------------------

[2017-05-29 11:53:50] [INFO ] [qtp16769923-16] PlaylistController - Playing stream - http://fortemedia.madsonic.org/rest2/st ... &id=168254 offset: 0
[2017-05-29 11:53:50] [INFO ] [/var/madsonic-node/transcode/ffmpeg InputStreamLogger] InputStreamReaderThread - (/var/madsonic-node/transcode/ffmpeg) /var/madsonic-node/transcode/ffmpeg: 1: /var/madsonic-node/transcode/ffmpeg: Syntax error: Unterminated quoted string
java.lang.RuntimeException: javax.sound.sampled.LineUnavailableException
at org.madsonic.controller.PlaylistController.createPlayer(PlaylistController.java:177)
at org.madsonic.controller.PlaylistController.play(PlaylistController.java:61)
at org.madsonic.controller.NodeController.start(NodeController.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$TypeOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:185)
at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302)
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
at com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108)
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
at com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409)
at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409)
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:558)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:927)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:875)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:829)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1487)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:499)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:427)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
at org.eclipse.jetty.server.Server.handle(Server.java:370)
at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)
at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:973)
at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1035)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:641)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:231)
at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:696)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:53)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
at java.lang.Thread.run(Thread.java:745)
Caused by: javax.sound.sampled.LineUnavailableException
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:714)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
at org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:94)
at org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
at org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:90)
at org.madsonic.service.jukebox.LocalAudioPlayer.<init>(LocalAudioPlayer.java:64)
at org.madsonic.controller.PlaylistController.createPlayer(PlaylistController.java:174)
... 46 more
piretro999
 
Posts: 15
Joined: 10 Oct 2013, 15:09
Has thanked: 0 time
Been thanked: 4 times

Re: Node 6.2.9260 problems

Unread postby piretro999 » 29 May 2017, 18:15

HI, even after the installation of ffmpeg as it did not worked.
but something changed...
Now I don't really know what to do. Please HELP


[2017-05-29 17:06:00] [INFO ] [qtp21513864-12] PlaylistController - Playing stream - http://fortemedia.madsonic.org/rest2/st ... &id=168254 offset: 0
java.lang.RuntimeException: javax.sound.sampled.LineUnavailableException
at org.madsonic.controller.PlaylistController.createPlayer(PlaylistController.java:177)
at org.madsonic.controller.PlaylistController.play(PlaylistController.java:61)
at org.madsonic.controller.NodeController.start(NodeController.java:79)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$TypeOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:185)
at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302)
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
at com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108)
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
at com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409)
at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409)
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:558)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:927)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:875)
at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:829)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1487)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:499)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:427)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
at org.eclipse.jetty.server.Server.handle(Server.java:370)
at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)
at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:973)
at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1035)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:641)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:231)
at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:696)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:53)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
at java.lang.Thread.run(Thread.java:745)
Caused by: javax.sound.sampled.LineUnavailableException
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openImpl(PulseAudioMixer.java:714)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:588)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.openLocal(PulseAudioMixer.java:584)
at org.classpath.icedtea.pulseaudio.PulseAudioMixer.open(PulseAudioMixer.java:579)
at org.classpath.icedtea.pulseaudio.PulseAudioDataLine.open(PulseAudioDataLine.java:94)
at org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:75)
at org.classpath.icedtea.pulseaudio.PulseAudioSourceDataLine.open(PulseAudioSourceDataLine.java:90)
at org.madsonic.service.jukebox.LocalAudioPlayer.<init>(LocalAudioPlayer.java:64)
at org.madsonic.controller.PlaylistController.createPlayer(PlaylistController.java:174)
... 46 more
piretro999
 
Posts: 15
Joined: 10 Oct 2013, 15:09
Has thanked: 0 time
Been thanked: 4 times

Re: Node 6.2.9260 problems

Unread postby Madevil » 29 May 2017, 21:19

hi there,

Try to check step by step to see if all the requirements are met:

  • install your PI with latest image: https://www.raspberrypi.org/downloads/raspbian/
  • check latest updates: sudo apt update
  • install latest update: sudo apt upgrade
  • install java: sudo install openjdk-8-jdk
  • set default: sudo update-alternatives --config java
  • set default: sudo update-alternatives --config javac
  • install Madsonic-node: dpkg -i madsonic-node.deb
  • install ffmpeg: dpkg -i ffmpeg_3.1.1-1_armhf.deb
  • link to Madsonic: sudo ln -s /usr/bin/ffmpeg /var/madsonic-node/transcode/ffmpeg
  • edit script: sudo nano /usr/share/madsonic-node/madsonic-node.sh
  • insert config: -Djavax.sound.sampled.SourceDataLine='#ALSA [default]' \ (after line: -Djava.awt.headless=true \)
  • set audio mixer: sudo amixer -c 0 cset numid=1
    1 = 3.5mm jack, 2 = HDMI port, 3 = Default
  • reboot PI

That’s it! ;)

download prebuild ffmpeg for ARM:

Code: Select all
wget https://github.com/ccrisan/motioneye/wiki/precompiled/ffmpeg_3.1.1-1_armhf.deb


best regards,
The Madsonic Team
User avatar
Madevil
Administrator
Administrator
 
Posts: 940
Joined: 07 Dec 2012, 03:58
Has thanked: 1334 times
Been thanked: 963 times

Re: Node 6.2.9260 problems

Unread postby sparc » 25 Dec 2017, 19:06

Madevil wrote:hi there,

Try to check step by step to see if all the requirements are met:

  • install your PI with latest image: https://www.raspberrypi.org/downloads/raspbian/
  • check latest updates: sudo apt update
  • install latest update: sudo apt upgrade
  • install java: sudo install openjdk-8-jdk
  • set default: sudo update-alternatives --config java
  • set default: sudo update-alternatives --config javac
  • install Madsonic-node: dpkg -i madsonic-node.deb
  • install ffmpeg: dpkg -i ffmpeg_3.1.1-1_armhf.deb
  • link to Madsonic: sudo ln -s /usr/bin/ffmpeg /var/madsonic-node/transcode/ffmpeg
  • edit script: sudo nano /usr/share/madsonic-node/madsonic-node.sh
  • insert config: -Djavax.sound.sampled.SourceDataLine='#ALSA [default]' \ (after line: -Djava.awt.headless=true \)
  • set audio mixer: sudo amixer -c 0 cset numid=1
    1 = 3.5mm jack, 2 = HDMI port, 3 = Default
  • reboot PI

That’s it! ;)

download prebuild ffmpeg for ARM:

Code: Select all
wget https://github.com/ccrisan/motioneye/wiki/precompiled/ffmpeg_3.1.1-1_armhf.deb


best regards,
The Madsonic Team


Thank you sir. All these people showing "java.lang.RuntimeException: javax.sound.sampled.LineUnavailableException" in their logs are probably using USB DACs, which is why your line to insert in the config should work well. Many times the OS will opt to assign ID 1 by default to your USB DAC, instead of ID 0. ID 0 is generally assigned to the built-in sound adapter. Validate this by running "cat /proc/asound/cards". This adapter can be blacklisted on the RPi3 by adding this to raspi-blacklist.conf. This will force the OS to only see your USB DAC as the only choice for audio output. Java does appear to be a bit finicky when it comes to selecting the correct sound adapter in a computer with multiple sound adapters.

Code: Select all
pi@sonic1:/var $ cat /etc/modprobe.d/raspi-blacklist.conf
blacklist snd_bcm2835
pi@sonic1:/var $


This same concept worked great for getting the Madsonic Jukebox working on Raspbian Stretch on a RPi3 with a Schiit Modi 2 Uber DAC. If you have any troubles with identifying your mixers to add to the SourceDataLine parameter in madsonic-node.sh -- reference https://gist.github.com/nsonnad/8ab51ecf840ed310c449 to create a simple Java script to identify them. For example, mine looks like this..

Code: Select all
'-Djavax.sound.sampled.SourceDataLine=#Uber [plughw:0,0]'
sparc
 
Posts: 14
Joined: 25 Oct 2017, 02:39
Has thanked: 7 times
Been thanked: 4 times

Re: Node 6.2.9260 problems

Unread postby sparc » 26 Dec 2017, 02:52

Ok, so I had some more time to tinker around. I don't think my sound configuration is the issue - I think it is actually not streaming & Node is calling a feature of Madsonic Server that is not fully implemented. Sound works properly out of aplay, and I do not see any Java errors indicating issues finding the LineOutput. I removed my USB DAC for this test & am using the on-board sound adapter on the RPi3.

Code: Select all
root@sonic1:~# cat /var/madsonic-node/madsonic_node_sh.log
Dec 25, 2017 7:30:27 PM org.springframework.context.support.ClassPathXmlApplicationContext prepareRefresh
INFO: Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@1a71e93: startup date [Mon Dec 25 19:30:27 CST 2017]; root of context hierarchy
Dec 25, 2017 7:30:28 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions
INFO: Loading XML bean definitions from class path resource [applicationContext-deployer.xml]
Dec 25, 2017 7:30:30 PM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons
INFO: Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@f67b76: defining beans [service,org.springframework.remoting.rmi.RmiServiceExporter#0]; root of factory hierarchy
used forced Install_Dir = /var/madsonic-node
Using WAR file: /usr/share/madsonic-node/madsonic-node.war
Extracting webapp to /var/madsonic-node/jetty/6.3.9700
Using WAR file: /usr/share/madsonic-node/madsonic-node.war
2017-12-25 19:30:31.454:INFO:oejs.Server:jetty-8.y.z-SNAPSHOT
Dec 25, 2017 7:30:33 PM com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
  org.madsonic
Dec 25, 2017 7:30:34 PM com.sun.jersey.api.core.ScanningResourceConfig logClasses
INFO: Root resource classes found:
  class org.madsonic.controller.IndexController
  class org.madsonic.controller.NodeController
Dec 25, 2017 7:30:34 PM com.sun.jersey.api.core.ScanningResourceConfig init
INFO: No provider classes found.
Dec 25, 2017 7:30:34 PM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
INFO: Initiating Jersey application, version 'Jersey: 1.19.4 05/24/2017 03:20 PM'
[2017-12-25 19:30:36] [DEBUG] [main] VersionService - Resolved local Madsonic Node version to: 6.3.9700
[2017-12-25 19:30:36] [INFO ] [main] SettingsService - Java: 1.8.0_151, OS: Linux
[2017-12-25 19:30:36] [INFO ] [main] SystemService - auto register Node ...
[2017-12-25 19:30:36] [INFO ] [main] SystemService - init LocalAudioDeviceList ...
[2017-12-25 19:30:36] [DEBUG] [Thread-3] BroadcastRegister - Request packet data: REGISTER_MADSONIC_NODE_REQUEST_31302e302e302e39393a38313831
[2017-12-25 19:30:36] [DEBUG] [Thread-3] BroadcastRegister - Request packet sent to: 10.0.0.255; Interface: wlan0
[2017-12-25 19:30:36] [DEBUG] [Thread-3] BroadcastRegister - Done looping over all network interfaces. Now waiting for a reply!
[2017-12-25 19:30:36] [DEBUG] [Thread-3] BroadcastRegister - Broadcast response from server: 10.0.0.28
[2017-12-25 19:30:36] [DEBUG] [Thread-3] BroadcastRegister - Register NODE Done. /10.0.0.28
[2017-12-25 19:30:36] [INFO ] [main] SystemService - Available local audio mixers:
[2017-12-25 19:30:36] [INFO ] [main] SystemService - PulseAudio Mixer
[2017-12-25 19:30:36] [INFO ] [main] SystemService - ALSA [default]
[2017-12-25 19:30:36] [INFO ] [main] SystemService - ALSA [plughw:0,0]
[2017-12-25 19:30:36] [INFO ] [main] SystemService - ALSA [plughw:0,1]
[2017-12-25 19:30:36] [INFO ] [main] SystemService - Port ALSA [hw:0]
2017-12-25 19:30:36.693:INFO:oejs.AbstractConnector:Started @0.0.0.0:8181
Madsonic running on: http://localhost:8181/
Dec 25, 2017 7:30:36 PM org.springframework.remoting.rmi.RmiServiceExporter getRegistry
INFO: Looking for RMI registry at port '9414'
Dec 25, 2017 7:30:37 PM org.springframework.remoting.rmi.RmiServiceExporter getRegistry
INFO: Could not detect RMI registry - creating new one
Dec 25, 2017 7:30:37 PM org.springframework.remoting.rmi.RmiServiceExporter prepare
INFO: Binding service 'MadsonicDeployerService' to RMI registry: RegistryImpl[UnicastServerRef [liveRef: [endpoint:[127.0.1.1:9414](local),objID:[0:0:0, 0]]]]
[2017-12-25 19:31:45] [DEBUG] [qtp6801022-13] NodeController - Set new Madsonic server credential.
[2017-12-25 19:31:45] [DEBUG] [qtp6801022-13] NodeController - Host: http://madsonic1.jbheinz.com:4040/default
[2017-12-25 19:31:45] [DEBUG] [qtp6801022-13] NodeController - Username: node
[2017-12-25 19:31:45] [DEBUG] [qtp6801022-13] NodeController - Password: enc:3231737473696465
[2017-12-25 19:31:57] [DEBUG] [Thread-12] BroadcastRegister - Request packet data: REGISTER_MADSONIC_NODE_REQUEST_31302e302e302e39393a38313831
[2017-12-25 19:31:57] [DEBUG] [Thread-12] BroadcastRegister - Request packet sent to: 10.0.0.255; Interface: wlan0
[2017-12-25 19:31:57] [DEBUG] [Thread-12] BroadcastRegister - Done looping over all network interfaces. Now waiting for a reply!
[2017-12-25 19:31:57] [DEBUG] [Thread-12] BroadcastRegister - Broadcast response from server: 10.0.0.28
[2017-12-25 19:31:57] [DEBUG] [Thread-12] BroadcastRegister - Register NODE Done. /10.0.0.28
[2017-12-25 19:32:19] [INFO ] [qtp6801022-18] PlaylistController - Playing stream - http://madsonic1.jbheinz.com:4040/rest2/stream.view?&v=3.0.0&c=node-10.0.0.99&u=node&p=enc:3231737473696465&id=8660 offset: 0
[2017-12-25 19:32:19] [DEBUG] [qtp6801022-18] LocalAudioPlayer - Opened line com.sun.media.sound.DirectAudioDevice$DirectSDL@8ad5dd
[2017-12-25 19:32:19] [DEBUG] [qtp6801022-18] PlaylistController - changeState: PLAYING
[2017-12-25 19:32:21] [DEBUG] [Thread-14] PlaylistController - changeState: EOM
[2017-12-25 19:32:21] [DEBUG] [Thread-14] LocalAudioPlayer - CLOSED line com.sun.media.sound.DirectAudioDevice$DirectSDL@8ad5dd
[2017-12-25 19:34:25] [DEBUG] [qtp6801022-13] NodeController - Set new Madsonic server credential.
[2017-12-25 19:34:25] [DEBUG] [qtp6801022-13] NodeController - Host: http://madsonic1.jbheinz.com:4040/default
[2017-12-25 19:34:25] [DEBUG] [qtp6801022-13] NodeController - Username: node
[2017-12-25 19:34:25] [DEBUG] [qtp6801022-13] NodeController - Password: enc:3231737473696465
[2017-12-25 19:34:47] [INFO ] [qtp6801022-15] PlaylistController - Playing stream - http://madsonic1.jbheinz.com:4040/rest2/stream.view?&v=3.0.0&c=node-10.0.0.99&u=node&p=enc:3231737473696465&id=8660 offset: 0
[2017-12-25 19:34:47] [DEBUG] [qtp6801022-15] LocalAudioPlayer - Opened line com.sun.media.sound.DirectAudioDevice$DirectSDL@76cbc3
[2017-12-25 19:34:47] [DEBUG] [qtp6801022-15] PlaylistController - changeState: PLAYING
[2017-12-25 19:34:47] [DEBUG] [Thread-15] PlaylistController - changeState: EOM
[2017-12-25 19:34:47] [DEBUG] [Thread-15] LocalAudioPlayer - CLOSED line com.sun.media.sound.DirectAudioDevice$DirectSDL@76cbc3


This is the result of sending the Config to the Node, transferring the play queue & hitting Start twice. The server log does not indicate any activity. When I take the URL from the "Playing stream" excerpt, I see a problem.

Code: Select all
http://madsonic1.jbheinz.com:4040/rest2/stream.view?&v=3.0.0&c=node-10.0.0.99&u=node&p=enc:3231737473696465&id=8660


Code: Select all
<madsonic-response xmlns="http://madsonic.org/restapi" status="failed" version="2.7.0" type="madsonic">
<link type="text/css" id="dark-mode" rel="stylesheet" href=""/>
<style type="text/css" id="dark-mode-custom-style"/>
<error code="30" message="Incompatible REST protocol version. Server must upgrade."/>
</madsonic-response>


When I change the v=3.0.0 to v=2.7.0 in the URL manually in Google Chrome .. it plays successfully to the PC inside Google Chrome.

Code: Select all
http://madsonic1.jbheinz.com:4040/rest2/stream.view?&v=3.0.0&c=node-10.0.0.99&u=node&p=enc:3231737473696465&id=8660


Is REST API 3.0.0 not fully implemented on the server? Seems to me the Node should not be calling it, or it should be configurable.

Can this be changed in the madsonic-node installation to simply call a modified URL on these REST API calls? I think it needs to not call REST API 3.0.0 at this point in time.
sparc
 
Posts: 14
Joined: 25 Oct 2017, 02:39
Has thanked: 7 times
Been thanked: 4 times

Re: Node 6.2.9260 problems

Unread postby sparc » 30 Dec 2017, 14:56

Does the new build address this REST API 3.0.0 issue with Madsonic Node? Does the server support it now?

Server 6.3.9800 23/12/2017
New DLNA: new experimental implementation in courtesy of Allen Petersen
Bugfix REST: API optimization
Bugfix SONOS: fix auto connect service
Upgrade FFMPEG 3.4.1
sparc
 
Posts: 14
Joined: 25 Oct 2017, 02:39
Has thanked: 7 times
Been thanked: 4 times

Re: Node 6.2.9260 problems

Unread postby sparc » 10 Jan 2018, 02:29

@Madevil - The changelog of Node seems to reflect some sort of API fixes. Was this issue I encountered addressed, where the server is claiming it doesn't support REST API 3.0.0?
sparc
 
Posts: 14
Joined: 25 Oct 2017, 02:39
Has thanked: 7 times
Been thanked: 4 times


Return to Node 6.x

Who is online

Users browsing this forum: No registered users and 1 guest