Starting on 5.2

49 views
Skip to first unread message

SonyAPILib

unread,
May 11, 2015, 1:28:40 PM5/11/15
to sony-api...@googlegroups.com
I am now starting on version 5.2

Here are just a couple of the things I plan to address:

1) The partial class "API" has been re-named to "Locate", to refer more to it's functions. (Mainly Discovery)
    The Locate class will also have 2 new methods, DeviceSave and DeviceLoad, allowing device information to be saved to a file.
    This will enable applications to preload "Known" devices and speed up the executions of the API

2) I will be adding classes for all the services available. RenderingControl, ConnectionManager, AVTransport, Party and IRCC,
    This will bring in all the other features and functions that are possible through the UPnP/DLNA connection.
    Also, this should provide the ability to have events based on StateVariable changes!

Should have some code for testing by the end of the week!

Thank you to everyone for your help!

SonyAPILib

unread,
May 21, 2015, 6:20:39 PM5/21/15
to sony-api...@googlegroups.com, k.her...@gmail.com
OK,

Thought I would drop an update out there since it's taking me longer than expected.

Once I dived in, I found myself changing A LOT of code.

I hate to say it, but this version 5.2 will have a completely different structure.
So any apps you have created will need to be changed.
I would also suggest for now, not to create to much based on these early releases as new options will come available.

Anyhow, I have decided to drop the ManagedUPnP 3rd party library for several reasons.

1) It seems to cause slight lagging in some applications.
2) keeping to COM connection alive is an issue too.
3) Handling this process myself will greatly increase this API's abilities 

So, I am now sending out my own Discovery broadcast and handling all the information, services and variables.

Also, version 5.2 will no longer require the name and IP to be set.
You will be able to create a Device object from the devices description xml file.
This can be done directly from the device, or from a saved XML file.

Example from device:
SonyDevice myDevice = buildFromDocument(new Uri(@"http://192.168.0.100:50001/description.xml"));

Example from file:
XDocument dDoc = XDocument.Load(dPath.ToString());
SonyDevice myDevice = buildFromDocument(dDoc.Root.Document.ToString(), @"http://192.168.0.100:50001/description.xml);

Also, this library will be compatible with more than just Sony devices.
Now that we are adding in the Services capabilities (AVTransport, Rendering Control, Connection Manager) any device that has these services will be able to use this API.

Still plugging away at it, and have the grand babies for a month, so I will keep you updated! 

petewill

unread,
May 22, 2015, 9:11:38 AM5/22/15
to sony-api...@googlegroups.com
Nice.  Let me know if I can help with testing anything on generation 3.  I don't have a lot of time but I'm happy to help when I can.  

Grand babies for a month!  I wish our parents would take our kids for a month :)

SonyAPILib

unread,
Jun 8, 2015, 8:12:41 PM6/8/15
to sony-api...@googlegroups.com, k.her...@gmail.com
UPDATE!!

Here is the latest update.

I have totally removed all references to the ManagedUPnP Library that I was using for the actions and properties.

I have completely hard coded all the state variables and service actions/methods directly into our API!
I have completed and tested (on Gen1 and Gen2) the Connection Manager, Rendering Control and IRCC services.
I am just now starting on the AVTransport service, as this is the biggest and I saved it for last.

So far so GOOD! All actions are preforming as expected and filling in the state variables with the correct values.
There are some new services available on Gen3 devices that I will have to explore to get in to this library.

But for now, I have already added 4 times more capabilities and functionality!!

I am currently using the console_example for testing, but plan to create a new example application that shows the devices architecture along with all the  state variable values.
I have also completed the DeviceLoad and DeviceSave funtions.
You can now use the DeviceSave function and save ALL the devices information to a Serialized XML file.
Once saved you can use the DeviceLoad function to load the XML in to a Device object and not have to initialize it, get the CommandList or ANYTHING. The Device is 100% ready to use!

Once I have all the service actions and state variables operating correctly, I will start working on being able to subscribe to device events and be able to react on changes made AT THE DEVICE!
Now, with that said, these capabilities will/can cause the application to have more of a delay when executing certain functions, but I think I can overcome this by allowing users to set if they want to subscribe or not, then if they want to use this library but do NOT need to respond to evens, they can turn that function OFF, and it will not cause any delays.

AS I have said before, I don't claim to be a fully trained programmer, this is all a hobby of mine, so if anyone see something that should be done differently, please let me know!
The Grandchildren are about to go back home, and I will have to go back to work, so my attention may drop off a little.
However, I do plan to get something out on GitHub before to much longer, as I need to see some Gen3 testing.

Thanks again!


On Monday, May 11, 2015 at 1:28:40 PM UTC-4, SonyAPILib wrote:

nikiforo...@gmail.com

unread,
Jun 9, 2015, 4:19:00 AM6/9/15
to sony-api...@googlegroups.com
Hi! Thank you for your work. It will be great if you add 'Wake on lan' function for 3th generation devices, which support this standard,.and possibility to receive command through command prompt for use it with automatisation programs in console application.

SonyAPILib

unread,
Jun 9, 2015, 8:58:41 AM6/9/15
to sony-api...@googlegroups.com, nikiforo...@gmail.com, nikiforo...@gmail.com
Thanks for your reply,

and YES, you are correct. That is a function I have forgotten to add in to the API.
I will definitely get it in to the new API, and I will also try to get it added in the old API(v5.1) also. 

Also, I just posted a comment about the possibility of a command line option, and think I will get that part added also.

Thanks so much for participation.
Reply all
Reply to author
Forward
0 new messages