Sign in to follow this  
Filousov

Direct Input 8 internal Error

Recommended Posts

Hi, I'm trying to get Direct Input Action mapping into work, but when I turn on Direct Input debug drivers, I get very strange messages from Direct Input 8 in my output log:
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(00182770, 0012F2F4, 0012F248) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(00182770, 0012F2F4) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
'mainDebug.exe': Loaded 'C:\WINDOWS\system32\wintrust.dll', No symbols loaded.
'mainDebug.exe': Loaded 'C:\WINDOWS\system32\imagehlp.dll', No symbols loaded.
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(0018fe88, 0012EE48, 0012ED9C) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(0018fe88, 0012EE48) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
'mainDebug.exe': Loaded 'C:\WINDOWS\system32\dimap.dll', No symbols loaded.
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(001836e8, 0012E094, 0012DFE8) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(001836e8, 0012E094) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(001983a8, 0012E094, 0012DFE8) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(001983a8, 0012E094) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(00187610, 0012E094, 0012DFE8) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(00187610, 0012E094) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
First-chance exception at 0x7c81eb33 in mainDebug.exe: Microsoft C++ exception: MapException @ 0x0012eca8.
DINPUT8: Internal GetActionMap error 0x8004060c for configurable device
DINPUT8: DIHid_GetDevInfo: CreateFile(\\?\hid#vid_045e&pid_0047#6&daf0aba&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}) failed? le=5
DINPUT8: DIHid_GetDevInfo(001875f0, 0012E098, 0012DFEC) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry(001875f0, 0012E098) -> 00000000 le=[5]
DINPUT8: DIHid_BuildHidListEntry failed?
First-chance exception at 0x7c81eb33 in mainDebug.exe: Microsoft C++ exception: MapException @ 0x0012ecac.

It also includes two first change exceptions stating, that DINPUT8: Internal GetActionMap error occured. But only lines of codes, which I run were:
	HRESULT hr=ERRNOERROR;

    if (DirectInput8Create(_hInst, DIRECTINPUT_VERSION, IID_IDirectInput8, (void**)&pDI, NULL)) //Direct input initialization
		ERRORMSG(ERRGENERIC,"DirectInput8Create()","DirectInput initialization failed");
	
	
    ZeroMemory( &diaf, sizeof(DIACTIONFORMAT) );
    diaf.dwSize          = sizeof(DIACTIONFORMAT);
    diaf.dwActionSize    = sizeof(DIACTION);
    diaf.dwDataSize      = NUM_OF_ACTMAP * sizeof(DWORD);
    diaf.guidActionMap   = g_guidApp;
    diaf.dwGenre         = DIVIRTUAL_DRIVING_RACE; 
    diaf.dwNumActions    = NUM_OF_ACTMAP;
    diaf.rgoAction       = actionsMap;
    diaf.lAxisMin        = -99;
    diaf.lAxisMax        = 99;
    diaf.dwBufferSize    = 16;
    _tcscpy( diaf.tszActionMap, _T("ActionMap") );
 
	
	if( pDI->EnumDevicesBySemantics( NULL, &diaf,StaticEnumDevicesCallback,this, DIEDBSFL_ATTACHEDONLY )){
			ERRORMSG(ERRGENERIC,"pDI->EnumDevicesBySemantics()","Enum devices failed");
	}

	return hr;



Even it was written in output log before StaticEnumDeviceCallback was called, but after I execute pDI->EnumDevicesBySemantics(...). Has anyone an idea, what is happening? Is there some documentation for debug messages, which I get from DirectInput8 into my output log? Any idea, how to fix this problem? I'm using Direct9 October 2004 SDK. Thanks for help anyway. Filousov [Edited by - Muhammad Haggag on November 25, 2005 11:13:35 AM]

Share this post


Link to post
Share on other sites
Are you actually seeing any side-effects in your application? are these debug errors corresponding to failed calls and/or errors in your code?

Whilst it might well be nice to know what they mean, it can be a case that the debug output is so verbose that it's telling you about insignificant errors (that is, the error is thrown but also caught/handled internally).

As far as I'm aware there is no documentation for the debug output for any of the DX components. It seems to change every now-and-then as well, which doesn't help documentation matters [smile]

hth
Jack

Share this post


Link to post
Share on other sites
Hi,
I tried it on another computer and no internal error. So it must be some problem on my computer.

But still I have another problem, which is occuring on all computers and that is with setting new keys on Action mapping. They don't react after I set them.

Filousov

Share this post


Link to post
Share on other sites
So I finally find out the problem.
When using BuildActionMap(...) try to choose some user name, do not pass NULL. Since I think in documentation is mistake and setting is not saved either in ASCII or Unicode mode. Be aware of this, because when user changes key settings, all will be ok, but it will not inform you about keys pressed down!!!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this