Unable to get any device attributes.
|
05-07-2012, 09:22 AM
Post: #1
|
|||
|
|||
Unable to get any device attributes.
Using the C API, I have tried calling CpDeviceCGetAttribute() function with all of the following keys.
"friendlyName" "location" "deviceXml" On each call, the function returns 0, which according to comments in CpDevice.h means: "...it was not available". Perhaps some of the attributes are genuinely not available for the devices I discovered, but I find it hard to believe that there is no XML device description! Is there another way to get a device's attributes using the C API? Also, is it possible to get other device attributes like Manufacturer, IP Address, Icon etc? Doug |
|||
05-07-2012, 09:48 AM
(This post was last modified: 05-07-2012 09:49 AM by simonc.)
Post: #2
|
|||
|
|||
RE: Unable to get any device attributes.
(05-07-2012 09:22 AM)dough Wrote: Using the C API, I have tried calling CpDeviceCGetAttribute() function with all of the following keys. You can query the following attributes:
(05-07-2012 09:22 AM)dough Wrote: Is there another way to get a device's attributes using the C API? Attributes other than above can be retrieved by getting "Upnp.DeviceXml" then parsing the xml returned. (This may seem odd but is probably more efficient. ohNet uses a pretty rudimentary xml parser; apps targetting a particular platform will typically have access to far more efficient/capable parsers.) |
|||
« Next Oldest | Next Newest »
|