Can I detect if my controller is using DirectInput or XInput?

I have a Mayflash wireless PS3 to PC usb adapter. It works great and has a handy switch to allow me to go from XInput to DirectInput. My game controls perfectly on DirectInput, but the buttons are all messed up on XInput. This is no big deal, but I cannot figure out how to detect what mode my controller input is in. Can anybody help? Googling was no help to me :*(

there’s a nice .NET wrapper for XInput that also supports Unity. check it out if you want to use XInput: GitHub - speps/XInputDotNet: C# wrapper around XInput, works with any Mono or .NET application (eg. Unity3D)