none
How to create a custom-capabilities for UWP apps ? RRS feed

  • Question

  • Hi,

    I just read the following linked content. 

    https://docs.microsoft.com/en-us/windows-hardware/drivers/devapps/custom-capabilities-for-universal-windows-platform-apps

    And, from the link, https://docs.microsoft.com/en-us/windows-hardware/drivers/devapps/faq-on-custom-capabilities. From those document, I learned that,

    for a IHV, suppose that my company want to offer some custom function to our UWP apps developer. Then this function is originally implemented by windows services.

    The content describe that a custom capability can be access through RPC. 

    Then, the only way is becoming a 3rd Party Microsoft partners first. 

    I has two problems for this custom capability. 

    1. How to become a 3rd Party Microsoft partners ?  

    2. And, if the user download the custom capability UWP apps package from windows store, the package will includes the custom services and driver. Is this correct? 

    B.R.

    Caro Lin


    Tuesday, August 1, 2017 8:28 AM

Answers

  • There is no way for a store app to install system software. System software can be installed by the OEM on the factory floor or through a pnp driver package. If neither is an option, you are out of luck.

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Wednesday, November 22, 2017 5:04 PM

All replies

  • The UWP will not include the driver or the service. The driver and service are installed by Pnp and hopefully you submit them to WU for automatic distribution

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Tuesday, August 1, 2017 5:15 PM
  • Hey Guys,

    I am also looking at creating a custom capability as an NT Service to make better use of our hardware from a UWP app. I read the above stated link and some more documentation. 

    The official microsoft sample on github (https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/CustomCapability) however is written in C++. Other app requirements force me to use C# for app development. How can I access my custom capability from a C# app? Trying to port the code from the example to a Windows runtime component failed for me. What is the correct approach to create my RPC client to work with my app? Ultimately I would want to create a reusable code library for future C# apps to use the same custom capability

    (I'm using VS2017 to develop my app) 

    I'm a bit lost. Any help and advice appreciated, thanks!

    Friday, August 18, 2017 1:44 AM
  • I would recommend creating a stand alone managed assembly implemented in c++ to support the client rpc side. Your app would then reference the new assembly and use it for the rpc management

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Friday, August 18, 2017 1:54 AM
  • I would recommend creating a stand alone managed assembly implemented in c++ to support the client rpc side. Your app would then reference the new assembly and use it for the rpc management

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Thanks for the fast reply. Which project template should I use for that in VS2017? VS2015 had CLR >> Class Library for that right? In VS 2017 I suppose one of the following: 

    Visual C++ >> Windows Universal >> DLL (Universal Windows) / Static Library (Universal Windows) / Windows Runtime Component (Universal Windows) ?


    Friday, August 18, 2017 2:33 AM
  • I would think the project template would be under the UWP section. The drivers section doesn't have any templates for managed projects

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Friday, August 18, 2017 6:01 AM
  • Hi Doron,

    Regarding with the same subject...

    Is it possible to use .Net Windows Service in order to register Custom Capability (HSA) and them implement RPC part to communicate with UWP App in a managed assembly in c++ for the server part also?

    Tuesday, November 21, 2017 11:56 AM
  • The language that implements the rpc endpoint is irrelevant. What matters is the security descriptor assigned to the rpc server endpoint during registration. As long .net allows you to set it, you are good to go.

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Tuesday, November 21, 2017 1:16 PM
  • Hi Doron,

    Thanks for your fast answer!

    Do you have a link where i can found documentation abou process that the company that i work for must to follow in order to submit a .Net Service with a custom capability signed on it to be late downloaded by Windows Update during UWP Apps installation that require it?

    Cheers!

    Tuesday, November 21, 2017 3:01 PM
  • WU only delivers pnp driver packages. That package may contain a service. You cannot install system level software with a store app

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Tuesday, November 21, 2017 5:25 PM
  • Ohhh ok i think i got it...
    So there is  anyway to test a WU deliverable PNP driver in dev time?
    Tuesday, November 21, 2017 5:35 PM
  • You can’t simulate WU directly, but you can install pnp drivers with pnputil /adddriver /install

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Tuesday, November 21, 2017 10:26 PM
  • Nice!!

    Thanks Doron!!!

    Wednesday, November 22, 2017 11:20 AM
  • Hi Doron,

    I tryed to find out a way to create a driver package and include a Windows Service files... but i was not able to find any documentation that describe this scenario. I was following this documentation: https://docs.microsoft.com/en-us/windows-hardware/drivers/develop/creating-a-driver-package

    Could you please send link documentation that describe this scenario?

    Cheers

    Wednesday, November 22, 2017 11:56 AM
  • It is a part of the inf syntax, this sample installs a service https://github.com/Microsoft/Windows-driver-samples/tree/master/general/DCHU . If you don’t have real hardware, you are going down the wrong path

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Wednesday, November 22, 2017 2:01 PM
  • Hummm....
    So if i don´t have a real hardware... what is the right path to install a Windows Service which can do certain work on background and be accessed by certain UWP apps also? At least on new proposed Windows 10 aproach.

    Cheers.

    Wednesday, November 22, 2017 2:55 PM
  • There is no way for a store app to install system software. System software can be installed by the OEM on the factory floor or through a pnp driver package. If neither is an option, you are out of luck.

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Wednesday, November 22, 2017 5:04 PM