I downloaded it....will report back.
Announcement
Collapse
No announcement yet.
Getting Track #, Track Count and Music Source
Collapse
X
-
Originally posted by dcorsus View PostAdded properties
- ZoneIPAddress as String
- ZoneMACAddress as String
- ZoneThirdPartyMediaServices as string
Added Methods
- GetHouseHoldID returns string
- Public Function ListAvailableServices(ByRef AvailableServiceDescriptorList As String, ByRef AvailableServiceTypeList As String, ByRef AvailableServiceListVersion As String) As String (returns empty or OK, all parameters are by REFERENCE)
Dirk
Code:Dim householdID As String = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "GetHouseholdID", Nothing) Dim TPMS As String = hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", Nothing) Dim a, b, c, ret As String ret = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "ListAvailableServices", {a, b, c})
Comment
-
Originally posted by skavan View PostOK - I'm sure I'm being thick...but using the following code. only the HouseholdID works:
Code:Dim householdID As String = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "GetHouseholdID", Nothing) Dim TPMS As String = hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", Nothing) Dim a, b, c, ret As String ret = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "ListAvailableServices", {a, b, c})
Do you need all 3 fields? Not sure how to return all 3 parameters, maybe I can return it as an array of strings, will that work?
Dirk
Comment
-
So, from Music Services, I *think* I only need:- AvailableServiceDescriptionList
So returning a string of that should be fine.
As for, ZoneThirdPartyMediaServices...I'm not sure why that isn't returning anything. Perhaps, you could make it a function, just like HouseholdID?
Then, while I'm jabbering, where would I grab:
- CurrentMetaData XML block
- NextTrackMetaData XML block
- EnqueuedTransportURI XML block
Closer and closer!
Comment
-
Originally posted by skavan View PostOK - I'm sure I'm being thick...but using the following code. only the HouseholdID works:
Code:Dim householdID As String = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "GetHouseholdID", Nothing) Dim TPMS As String = hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", Nothing) Dim a, b, c, ret As String ret = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "ListAvailableServices", {a, b, c})
Public Function ListAvailableServices(By) As String()
' First returned parameter = AvailableServiceDescriptorList
' Second = AvailableServiceTypeList
' Third = AvailableServiceListVersion
New .exe attached
DirkLast edited by dcorsus; November 18, 2015, 11:54 PM.
Comment
-
Originally posted by skavan View PostSo, from Music Services, I *think* I only need:- AvailableServiceDescriptionList
So returning a string of that should be fine.
As for, ZoneThirdPartyMediaServices...I'm not sure why that isn't returning anything. Perhaps, you could make it a function, just like HouseholdID?
Then, while I'm jabbering, where would I grab:
- CurrentMetaData XML block
- NextTrackMetaData XML block
- EnqueuedTransportURI XML block
Closer and closer!
CurrentData is property CurrentTrackMetaData
I'll add NextTrackMetaData as another property
No idea where or what you want to do with EnqueuedTransportURI
Dirk
Comment
-
Originally posted by skavan View Postnope.
Code:Dim ret() As String ret = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "ListAvailableServices", Nothing)
Code:hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", Nothing)
ListAvailableServices called for zoneplayer .......
Comment
-
1. ThirdPartyMediaServicesX is returned after subscribing to ZoneGroupTopology. Sorry, I forgot the X!
2. If you could put CurrentTrackMetaData, NextTrackMetaData and EnqueuedTransportURI into separate methods (all of which are returned in an AVTransport Last Change Event) that would be great.
3. If you could just return AvailableServiceDescriptionList from a method ListAvailableServices.
Then, I *think* I'm all good. Thank you so much for your patience on this.
Comment
-
Originally posted by skavan View Postnope.
Code:Dim ret() As String ret = hs.PluginFunction("Sonos", "RINCON_000E58A72F9601400", "ListAvailableServices", Nothing)
Code:hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", Nothing)
May have made a type on ListAvailableServices, try attached.
Have added NextTrackMetaData
Dirk
DirkLast edited by dcorsus; November 19, 2015, 12:26 AM.
Comment
-
Originally posted by skavan View PostHi,
Debug reports:
Error in PluginProc for instance = RINCON_000E58A72F9601400 : Parameter count mismatch.
s.
hs.PluginPropertyGet("Sonos", "RINCON_000E58A72F9601400", "ZoneThirdPartyMediaServices", {ret})
Got a more verbose error:
ERROR in ListAvailableServices for zoneplayer = Family Room with UPNP Error = Read only tag / Transport is locked / Access denied. Error = MyUPnPService.InvokeAction for ServiceID = http://192.168.1.57:1400/xml/DeviceProperties1.xml while sending Action = ListAvailableServices for URI = http://192.168.1.57:1400/DeviceProperties/Control and Request = UPNP Error = faultcode = s:Client, faultstring = UPnPError, detail = 401 with error = The remote server returned an error: (500) Internal Server Error.
Comment
-
Originally posted by skavan View PostEnqueuedTransportURI into separate methods (all of which are returned in an AVTransport Last Change Event) that would be great.
Comment
-
Originally posted by dcorsus View PostEnqueuedTransportURI is a non-evented parameter as per the XML descriptor, so doesn't come with events. Have you seen it somewhere? When is it used?
<r:EnqueuedTransportURI val="x-sonosapi-radio:custom_radio.f559_54d7dbbae992798d9c084b0d?sid=6&f lags=8300&sn=4"/>
Comment
Comment