Step-By-Step: Building AllJoyn Universal Windows Apps for Windows 10 Public Preview

Sign in to queue

The Discussion

  • User profile image
    ken

    Great stuff, but where can I get the getajxml.exe application?

  • User profile image
    GavinGear

    Ken- the getajxml.exe tool is now included in the Git Repo that we linked to. Let us know if you have any issues with it.

  • User profile image
    ppatierno

    Hi Gavin,

    I'm creating a simple AllJoyn Led for excersing and I change a little the commands sequence you provided.

    I didn't delete pch.cpp and pch.h from created runtime component but override them with the auto generated version (I saw in your toaster example that you have autogenerated pch.h and pch.cpp in the runtime project). However, if you try to compile ... it fails of course, becase it doesn't have all dependencies needed from step "Editing Project Settings and Dependencies".

    My advice is to change in the following way :

    override pch.h and pch.cpp with autogenerated

    before trying to compile, the user can execute "Editing Project Settings and Dependencies" and then the build will work fine.

    Does it make sense for you ?

    Paolo

  • User profile image
    GavinGear

    Thanks Paolo- my directions could have been more clear. I meant "leave the project references to pch.h and pch.cpp", but didn't directly state to overwrite the actual files with the generated ones. I've simplified the instructions now. Yes, you do want the pch.h and pch.cpp that are generated by the AllJoyn code generator.

  • User profile image
    ppatierno

    It seems that a first compilation before copying all generated files is needed because I receive error regarding missing precompiled header pch.pch (in the Debug folder).

    If I compile the runtime component just created before replacing all generated files, it works.

    Another point ...

    In general, when you don't have a capability in the package manifest file but use it at runtime, an exception is raised. In my example application, I forgot to set the AllJoyn capability in the consumer app but no exception is raised. The only result is that the added watcher event isn't called.

    Paolo.

  • User profile image
    GavinGear

    Thanks Paolo! We are fixing the exception issue, and I updated the steps to start with a build of the UWP component project before modifying it.

  • User profile image
    ppatierno

    There is another main step that drove me crazy !

    To use toaster on the Raspberry Pi 2, it's needed to disable the firewall on the board with :

    netsh advfirewall set allprofiles state off

    It's documented in the ZWave DSB guide. I didn't read the guide because I didn't need to implement a DSB bridge so I lost this mandatory step.

    However, I think that it could be better to open only AllJoyn ports and not disable the firewall.

    Paolo

  • User profile image
    Joe

    I can't seem to get getajxml.exe to run on Windows 10 preview..I get the following message:

    This version of C:\temp\getajxml.exe is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher.

    Any Ideas?

    I'm attempting to use this instead of alljoyn explorer due to issues I am encountering. Alljoyn explorer is showing two different bus objects having identical interfaces (com.microsoft.zwaveadapter.xxxx.interface_1). They therefore generate identical introspection XML. When connecting via my UWP app it is connecting to the wrong bus. I can't seem to figure out how to differentiate between the two. I'm hoping to see different XML generated by the getajxml tool.

  • User profile image
    Chihfan Hsin

    I think that there may be an issue with current getajxml.exe and alljoyncodegen.exe, when there are interfaces with the same name under 2 different object paths.
    My scenario is to write a Win UWP AllJoyn Client app that controls Aeon Lab Smart Switch via Device System Bridge. The Aeon Lab Smart Switch is used as a demo/sample codes for Device System Bridge.
    The main control interface is "com.microsoft.ZWaveAdapter.HomeID25504235Node2.interface_1". However, both /Switch object path and /Enable_Wattage_Reports object path have the same interface.

    Issue 1: When I use "getajxml.exe" to generate the introspection xml, the "node" does not specify which object path to use. Therefore, I got the same xaml for 2 different object paths.
    Issue 2: Even when I manually add name="/Switch" to node and use "alljoyncodegen.exe", the resulting codes generated (I believe) do not consider the object path.
    In auto generated AllJoynHelpers::GetObjectPath(), it only returns the first object path for that interface name. Therefore, I alwasy got /Enable_Wattage_Reports object path, not the intended /Switch object path.

    Can some one shed some light about these issues?

    Thanks,
    Chih-fan Hsin.

  • User profile image
    Joe

    Chihfan,

    I am running into the exact same issue and have not been able to work around it. Please keep me updated if you find a solution.

    Thanks!
    Joe

  • User profile image
    Chihfan Hsin

    Joe,
    To workaround this issue, I modified the auto-generated codes at AllJoynHelpers::GetObjectPath(). You need to return multiple object paths that have the same interfaces. Then you need to loop through them, and get the object path you want, and return that object path.

    Currently, the auto-generated codes only return the 1st object path with a matching interface. I also reported this issue at https://github.com/MS-brock/AllJoynToasterDemo/issues/1 .
    Chih-fan

Add Your 2 Cents