MissileLauncher service fails

Submitted by paulfo on Mon, 03/03/2008 - 08:06.

On starting either of the launcher manifest examples I get a failure at the point of calibrating:
*** System.NullReferenceException: Object reference not set to an instance of an object
at BrainTech.AsyncMissileLauncher.ToLimit(Byte[] cmd, Byte[] stat)
at BrainTech.AsyncMissileLauncher.Calibrate()
at BrainTech.AsyncMissileLauncher..ctor(Int64 calib_horiz, Int64 calib_vert, single init_yaw, Single init_pitch)
at Braintech.Vi_MissileLauncher.MissileLauncherService.Start()
at Microsoft.Dss.ServiceMode.DsspServiceBase.DsspServiceBase.d__4f.MoveNext() etc etc

I'm running on Vista, I had two HID items in my system properties - the missile launcher is I think HID\VID_0A81&PID_0701
I have the MSN USB Missile Launcher version - as it had the camera.

Any help/guidance appreciated.
Paul

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Actually you know what

Risking all I downloaded and installed the original USB missile launcher software from Dream Cheeky.

I have just installed it and tested it against my MSN launcher and the same software works.

The application files are identical. How's this work with different product ids??

Anyhow, I'm not stressed by the different USB protocol issues (should I still be?)

Can I ask -with a pretty please - for a new service with just the product id/vendor id changed in InitDevice?

It'd be so much quicker than me re-writing. I volunteer my launcher to be the test pilot!

Attachment is

Paul reports to me that this

Paul reports to me that this isn't working, so I'm pulling it down until we can acquire the hardware and test it.

Ok, I've posted the revised

Ok, I've posted the revised launcher above. It queries both the old vendor/product and the new one: 0x0A81, 0x0701.
It should throw an exception if no device is present.

Use at your own risk. If you experience any problems, please let me know.

Ok

Ok Robert,

Thanks for your help. I'll see if I can make something run by myself.

Knew I should have gone for the earlier model! Just that this one had the camera attached - geek ego pushed to far AGAIN.

Hi, let's check a couple

Hi, let's check a couple things:

When you start up, do you see this message on the console:
Connected: [some string]

That indicates successful connection to the device. You'll see no such message if you fail to connect.

If you have some programming knowledge, try creating a console application, reference the library Vi_Hid.dll and put this call into your Program.cs (or the vb equivalent):

HIDLibrary.HidDevice[] HidDeviceList;
HidDeviceList = HidDevices.Enumerate(0x1941, 0x8021);

These are the vendor/product IDs of the missile launcher. If the list returns empty, then the product id for the msn version is probably different, and we'll have to do some testing over here.

InitDevice config file

Please could you provide a version of the Missile Launcher service that has a InitDevice method that reads device identifiers from a config file...

Cheers
Paul

HID list is empty

I don't see Connected message.

Tried the code you provided and it returns an empty list.
Tried it with the device details I found in Device Manager:
HidDeviceList = HIDLibrary.HidDevices.Enumerate(0x0A81, 0x0701);
and get an item in the list:
ProductId = 1793(0x0701)
VendorID = 2689 (0x0A81)

Is there anyway I can influence your code to use these values?

Appreciate your help in this
Paul

We could check for this

We could check for this vendor/product combination, but we'd have to verify first that it speaks the same control protocol. If it doesn't then we'll have to pick one up and test it here. I wouldn't want to be responsible for frying your launcher. :-) If you know of any online docs that describe the protocol for this model, please send them my way.

I can make an effort to get you a revised launcher but other deadlines mean that the earliest I can address it is next week.