1

Resolved

Automation problem with getting the video

description

Hello,
I'm the SQE for Ghost and I'm trying to get the video of the last 6 seconds once I unregistered a package from the console. The goal is to provide our engineers a video of what was happening on our automation farm before the crash happened doing this :
l_xbConsole.CaptureRecordedGameClip(@"C:\XB1_" + l_xbConsole.HostName + ".mp4", 6);

However this is giving me the following exception :
    Microsoft.Internal.GamesTest.Xbox.XboxConsoleException: Failed to capture DVR clip..  Reason: Unknown error (0x8c11040d) ---> System.Runtime.InteropServices.COMException
at Microsoft.Xbox.XTF.HRESULT.CHK(Int32 hr)
at Microsoft.Xbox.XTF.Console.ConsoleControlClient.CaptureDVR(String address, String fileName, UInt32 numSeconds)
at Microsoft.Internal.GamesTest.Xbox.Adapter.November2014.XboxXdk.CaptureRecordedGameClip(String ipAddress, String outputPath, UInt32 captureSeconds)
at Microsoft.Internal.GamesTest.Xbox.Adapter.November2014.XboxConsoleAdapter.CaptureRecordedGameClipImpl(String systemIpAddress, String outputPath, UInt32 captureSeconds)
at Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.<>c__DisplayClass3d.<CaptureRecordedGameClip>b__3c()
at Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.PerformXdkAction(String systemIpAddress, Action action, String errorMessage)
--- End of inner exception stack trace ---
at Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.PerformXdkAction(String systemIpAddress, Action action, String errorMessage)
at Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.CaptureRecordedGameClip(String systemIpAddress, String outputPath, UInt32 captureSeconds)
at Microsoft.Internal.GamesTest.Xbox.XboxConsole.CaptureRecordedGameClip(String outputPath, UInt32 captureSeconds)
at ATF.XB1Controller.XB1Controller.Start(String executableName, String arguments) in d:\Projects\Genesis-dl-build\TnT\Build\Code\ATF.PlatformController\ATF.XB1Controller\XB1Controller.cs:line 352
at ATF.PlatformController.PlatformController.PlatformControllerStarter(String[] ls_args) in d:\Projects\Genesis-dl-build\TnT\Build\Code\ATF.PlatformController\ATF.PlatformController\PlatformControl
ler.cs:line 216
at ATF.XB1Controller.Program.Main(String[] ls_args) in d:\Projects\Genesis-dl-build\TnT\Build\Code\ATF.PlatformController\ATF.XB1Controller\Program.cs:line 17

Here is the callstack:
GamesTest.XboxConsole.Infrastructure.dll!Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.PerformXdkAction(string systemIpAddress = "10.46.65.98", System.Action action = {System.Action}, string errorMessage = "Failed to capture DVR clip.") Line 250 C#
GamesTest.XboxConsole.Infrastructure.dll!Microsoft.Internal.GamesTest.Xbox.XboxConsoleAdapterBase.CaptureRecordedGameClip(string systemIpAddress = "10.46.65.98", string outputPath = "C:\\ATFXB1Controller_AUTOXB1DEV01.mp4", uint captureSeconds = 6) Line 101    C#
GamesTest.XboxConsole.dll!Microsoft.Internal.GamesTest.Xbox.XboxConsole.CaptureRecordedGameClip(string outputPath = "C:\\ATFXB1Controller_AUTOXB1DEV01.mp4", uint captureSeconds = 6) Line 723  C#
ATF.XB1Controller.exe!ATF.XB1Controller.XB1Controller.Start(string executableName = "release", string arguments = "-super layout.toc   -Core.EnableJuice True -Core.JuiceTitleName Genesis -Core.JuiceServerIP 10.46.5.12 -Core.JuiceUserType BuildMonkey -Core.DisplayAsserts 0 -Blaze.LogLevel 2 -Online.DirtySockLogLevel 1  -RaceClient.AutomatedBootflow true -Network.ProtocolVersion 5807") Line 352 C#
PlatformController.dll!ATF.PlatformController.PlatformController.PlatformControllerStarter(string[] ls_args = {string[4]}) Line 216 C#
ATF.XB1Controller.exe!ATF.XB1Controller.Program.Main(string[] ls_args = {string[4]}) Line 17    C#
[External Code] 
And the error is happening in
D:\Projects\Genesis-dl-build\TnT\Code\External\XboxConsole\XboxConsole.Adapter.November2014\XboxXdk.cs

We are running the XDK from April 2015 on our kits and PC, so I thought that maybe I had to start looking into using a more recent Adapter, however looking at the latest release on codeplex, there is no new adapter dll to be found.

I'm also interested in knowing if there is a system in the code that is able to auto detect which adapter should be used depending on what console is being connected.

comments

amccalib wrote May 13, 2015 at 8:15 PM

I'm investigating this now.

The November 2014 adapter is the latest we've published and it should be fully compatible with April, so that shouldn't be your problem.

The code currently does not detect the version on your kit but rather the version of the XDK installed on the local PC. In your case, that doesn't sound like it should be causing a problem, as the two versions align.

amccalib wrote May 13, 2015 at 9:03 PM

The hresult you're getting back corresponds to E_TITLE_VM_NOT_AVAILABLE. This is most frequently encountered when there is not currently a game running. Can you confirm you're hitting this when you've verified a game is running?

wrote May 13, 2015 at 9:05 PM

MAXCORBGHOST wrote May 14, 2015 at 7:58 AM

Well I can confirm that actually the game is almost always not currently running when this is happening...
The goal being to register what is in the XB1 video memory after a crash got detected so that we can give that video to our engineers to give them an idea of what happened before the crash that the automation test farm registered...
That feature would be immensely useful for us to have.
So close, yet so far^^

amccalib wrote May 18, 2015 at 6:59 AM

As far as I'm aware, that's a limitation of the platform. An ERA has to be running for the DVR capture functionality to work. In games we've worked on so far, the way we've accomplished the task you describe is by adding code into an unhandled exception filter in the game. That code can then capture a video and perform any other final acts before the VM is torn down. If you save content to the developer scratch drive, you can easily access it afterwards.

wrote May 18, 2015 at 7:15 AM