I am trying to log the information using Windows.Foundation.Diagnostics.LoggingChannel class, in my UWP headless app that runs on a Raspberry Pi.
I don't see any errors while running the application, but I cannot see any events in Device portal-ETW viewer. I have enabled “Microsoft-Windows-Diagnostics-LoggingChannel” level 5.
Below is the code snippet from my application.
Using Windows.Foundation.Diagnostics;
LoggingChannel loggingChannel = new LoggingChannel("test provider", null);
loggingChannel.LogMessage("Process started",LoggingLevel.Information);
Please note that I can see the events for other providers like Microsoft-Windows-Kernel-Networking.
The LoggingChannel registered in your code is not for Microsoft-Windows-Diagnostics-LoggingChannel but for your custom channel. You can see the events via enabling the custom provider with GUID. For example, i run the sample on my Raspberry Pi 3, i can see the events in Device Portal.Microsoft-Windows-Diagnostics-LoggingChannel is system registered provider.