Author Topic: XBMC Shows as offline  (Read 5760 times)

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
XBMC Shows as offline
« on: June 20, 2014, 04:47:13 am »
Hi

I recently installed the DLNA Media Controller plug-in. Everything is working apart from when I turn on my XBMC PC the DLNA device for it in Vera always says OFFLINE. I tried rebooting the XBMC PC and the DLNA device still says offline.

Only when I open the DLNA device in Vera and go to the settings tab did it change to State = ON.

I configured some scenes to send TTS notifications to XBMC however this doesn't work when the DLNA device in Vera is offline.

The XBMC PC has a static LAN IP address.

Should we enter the IP in to the IP address field in the DLNA devices Advanced tab?

Any suggestions / fixes?

Many thanks

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #1 on: June 20, 2014, 05:00:40 am »
OK adding the static LAN IP address of the XBMC PC in to the DLNA Devices IP address field in the Advanced tab seems to have improved things, its appears to be detecting that the XBMC PC has been turned on now.

Will keep an eye on it.

Great plugin btw you've done an excellent job on it!

Offline lolodomo

  • Moderator
  • Master Member
  • *****
  • Posts: 3484
  • Karma: +74/-10
Re: XBMC Shows as offline
« Reply #2 on: June 20, 2014, 06:13:14 am »
The IP attribute is not used by the plugin. What is used is the state variable "DescriptionURL".

Your problem was probably bevause you did not reload lua or you did not cleanup your WEB browser cache.

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #3 on: June 20, 2014, 06:23:10 am »
Hi

So your saying using that IP address field in the advanced tab has no effect / doesn't do anything?

It certainly appeared to fix the problem once I entered the IP address of the XBMC PC in there.

Cheers

Offline lolodomo

  • Moderator
  • Master Member
  • *****
  • Posts: 3484
  • Karma: +74/-10
Re: XBMC Shows as offline
« Reply #4 on: June 20, 2014, 06:29:08 am »
Yes, IP is not set oon my device and it works well.
And I know that I don't use this IP field in my code.
Of course, I assume that you are running the last version of the plugin (the version in the app store).

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #5 on: June 20, 2014, 09:16:56 am »
Hi

Yes I installed it from the mios app store the version is 1.0

Thanks

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #6 on: June 21, 2014, 10:18:20 am »
Hi

The problem seems to be back again. I just turned on my XBMC PC and the DLNA device in Vera still says offline.
If I open Vera UI in another browser which I don't normally use, it says offline in there as well.

It doesn't seem to be detecting then the XBMC PC has been turned on.

The XBMCState device in Vera on the other hand has no issues and says: UP meaning the XBMC PC is on etc.

Please advise

Thank you.
« Last Edit: June 21, 2014, 10:41:26 am by cw-kid »

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #7 on: June 21, 2014, 10:24:37 am »
Attached is a screen shot of the XBMC Gotham UPNP settings. The XBMC PC is on the LAN via a cable with a static IP address.

I am not sure how your upnp discovery works, but my router is listing the XBMC PC as being an "attached device" and I can ping and resolve the XBMC PC's IP address / hostname from my Windows 7 laptop OK.

Cheers

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #8 on: June 21, 2014, 10:36:10 am »
Hi

I've just installed an app on my iPOD Touch called UPNP Browser which discovers and lists all UPNP devices on your network.

If I run this its showing two instances of XBMC01 one says the Manufacturer is Microsoft Corporation (MediaServer:1) and the other says Team XBMC (MediaRender) both have the same static IP which is correct. No idea why one says Microsoft as it a Linux OpenElec box. But XBMC01 is showing on the LAN as a upnp device etc.

If I click the Reload button in Vera then the DLNA device becomes online again.
« Last Edit: June 21, 2014, 10:47:52 am by cw-kid »

Offline lolodomo

  • Moderator
  • Master Member
  • *****
  • Posts: 3484
  • Karma: +74/-10
Re: XBMC Shows as offline
« Reply #9 on: June 21, 2014, 03:05:58 pm »
By default the state is not checked regularly but only after a reload or when you send a command.

If you want a cyclic check of the state, you have to set the variable CheckStateRate. When set to 0, the default, the cyclic check is disabled. The value is a number of minutes.
« Last Edit: June 21, 2014, 03:08:42 pm by lolodomo »

Offline lolodomo

  • Moderator
  • Master Member
  • *****
  • Posts: 3484
  • Karma: +74/-10
Re: XBMC Shows as offline
« Reply #10 on: June 21, 2014, 03:15:05 pm »
Regarding UPnP discovery, you might be in the same case as me and in this case you have to update the network setup of your Vera. I provided the link  to the message explaining what command to run. After that, the discovery is working.

I will think how I could propose this network patch in the plugin UI.

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #11 on: June 21, 2014, 03:46:51 pm »
Hi

Thanks I will try the CheckStateRate thing.

I am using the DLNA device to send Google TTS notifications to XBMC, so the DLNA device needs to automatically change itself from Offline to Online (No Media) status when I turn on the XBMC PC etc.

Which network patch for Vera are you referring to? I think the initial discovery was working OK, the DLNA device was detecting the various upnp players on  my LAN. It just wasn't turning itself to an online status with the XBMC PC.

Many thanks
« Last Edit: June 21, 2014, 04:04:48 pm by cw-kid »

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #12 on: June 21, 2014, 04:10:56 pm »
Although having just said that it appears to be working again now. I put 5 in the CheckStatusRate field saved Vera etc.

Now when I turn on the XBMC PC the status of the DLNA device changes immediately to "No Media" if I power off the XBMC PC (S3 Sleep) the DLNA device changes status immediately to "Offiline" power PC back on it changes immediately back to status "No Media"

So its certainly not waiting 5 minutes to check the up status of the PC. Seems hit and miss, sometimes it works fine other times it just stays as status Offline even when the XBMC PC has been on for some time.

Regards
« Last Edit: June 21, 2014, 04:14:39 pm by cw-kid »

Offline lolodomo

  • Moderator
  • Master Member
  • *****
  • Posts: 3484
  • Karma: +74/-10
Re: XBMC Shows as offline
« Reply #13 on: June 22, 2014, 04:43:12 am »
Did you install the UPnP event porxy ?

When the UPnP event proxy is running, the plugin does not do anything except checking that the renderer is here every XX minutes (XX being the value set in CheckStateRate variable). So the refresh can occur between 1 second and XX minutes after you change the state.

When the UPnP event proxy is not running, there is a poll of data every 15 seconds. That could accelerate the discovery of a suddenly OFF device -between 1 and 15 seconds). But it is not recommended to not use the UPnP event proxy. I should even say that I have not tested the plugin without the UPnP event proxy. This mode is here historically because it was the initial behaviour with the Sonos plugin.

You have the action "SelectDMRDevice" that you could call to update the state before running your TTS command. You have to provide the description URL as parameter. It is the action called when you push the button "Check" in the settings tab.

PS: don't care about the network patch, you are apparently not concerned by this problem, that is a chance.

Offline cw-kid

  • Hero Member
  • *****
  • Posts: 1566
  • Karma: +16/-2
Re: XBMC Shows as offline
« Reply #14 on: June 22, 2014, 08:20:40 am »
Hi

No I have not install a upnp event proxy.

So I should also install this?

Cheers