It seems MCV has done a lot of effort implementing UPnP into Vera but unfortunately stopped before completing the last mile
After @Ap15e 's workaround ([url=http://forum.micasaverde.com/index.php/topic,10220.0.html]http://forum.micasaverde.com/index.php/topic,10220.0.html[/url]) for bug #1473 ([url=http://bugs.micasaverde.com/view.php?id=1473]http://bugs.micasaverde.com/view.php?id=1473[/url]), hereās another bug to be fixed:
When calling a UPnP action for a UPnP device imported into Vera, itās supposed to send a SOAP Message to the device as per the xml service file provided. Some devices (like a UPnP Media Server) expect the SOAP message to be properly formatted (ie the argument tags ordered as per the xml service file).
When using the luup.call_action function with an argument list, Vera will sort the tags in the SOAP Message as per their order in the arguments parameter (table) provided, but Luaās string tables are randomly sorted ([url=http://www.lua.org/pil/19.3.html]http://www.lua.org/pil/19.3.html[/url]) so we will end up with a badly formatted SOAP Message (as below).
(I believe the code to properly format the SOAP Message as per the xml service file is missing.)
The same applies when using an http request, the sort order of the parameters in the SOAP Message will be the same as their appearance in the URI. (At least this way, the user/developer is able to control the sort order).
Properly formatted SOAP Message:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<s:Body><u:Browse xmlns:u="urn:schemas-upnp-org:service:ContentDirectory:1">
<ObjectID>0</ObjectID>
<BrowseFlag>BrowseDirectChildren</BrowseFlag>
<Filter>id,dc:title,upnp:class,res,res@duration</Filter>
<StartingIndex>0</StartingIndex>
<RequestedCount>10</RequestedCount>
<SortCriteria>+dc:title</SortCriteria>
</u:Browse>
</s:Body>
</s:Envelope>
Badly formatted SOAP Message:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<s:Body><u:Browse xmlns:u="urn:schemas-upnp-org:service:ContentDirectory:1">
<StartingIndex>0</StartingIndex>
<ObjectID>0</ObjectID>
<RequestedCount>10</RequestedCount>
<BrowseFlag>BrowseDirectChildren</BrowseFlag>
<Filter>id,dc:title,upnp:class,res,res@duration</Filter>
<SortCriteria>+dc:title</SortCriteria>
</u:Browse>
</s:Body>
</s:Envelope>
Please can a beta tester report this bug to MCV so we can get a fix some day ?