TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

A place to report problems and bugs in SharpCap
Forum rules
Please read about Troubleshooting USB Issues before posting.

*** Please do not post license keys - please report any problems with licensing to 'admin' by PM ***

Please include the following details in any bug report:

* Version of SharpCap
* Camera and other hardware being user
* Operating system version
* Contents of the SharpCap log after the problem has occurred.
[If SharpCap crashes, please send the bug report when prompted instead of including the log]
Post Reply
talanzaar
Posts: 4
Joined: Sun Jun 28, 2020 9:24 am

TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by talanzaar » Sun Jun 28, 2020 10:29 am

Hi,

I can't seem to get my ancient webcam to work. Not sure if its something simple. Want to get it to work so I can use it for a bit of outreach with my Scouts later this year... in person not on Zoom (hopefully Covid-19 rules withstanding!).

I realise its ancient technology, and I mostly work with my QHY 5L-II cameras. But it has served me well over the years and is reasonably sensitive.

Its a "TS-Optics moon and planetary astro CCD camera", https://www.teleskop-express.de/shop/pr ... ction.html
The device manager drivers (the ones that work) are 64-bit (I'm running 64-bit Win10) from TS. These are the ones that work https://www.teleskop-express.de/shop/bi ... /TSSSI.zip

When I try to load the filter options in 64-bit SharpCap I get the attached error (I might have submitted a few similar ones with the reporting tool). The filter options work in the included AmCap_x64.exe (I've also attached an image) - but clearly this software isn't very good compared to SharpCap. So is it something to do with the way SharpCap calls the filter settings module?

The device does not appear at all in 32-bit SharpCap. What am I doing that means its not detected?

Not sure which way to go with this.

Thanks,
Jonathan

Just as a note: It works on my 32-bit Win7 laptop with SharpCap, but that device is too small and slow to be much use.
Attachments
filter options.png
filter options.png (65.62 KiB) Viewed 108 times
Log_2020-06-28T11_08_55-16088.log
(18.75 KiB) Downloaded 4 times

User avatar
admin
Site Admin
Posts: 4334
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by admin » Sun Jun 28, 2020 3:07 pm

Hi,

I think I can understand why you can't get the 32-bit version of SharpCap to work – I downloaded the drivers from the link that you included and had a look inside the .inf file for the Windows 7 64-bit drivers. Unfortunately the inf looks like it is set up incorrectly and will only install the 64 bit 'ax' file on a 64-bit system. Really it should install the 32-bit version of that file as well which would allow access to the camera from 32-bit applications. Unfortunately it's not just a simple as copying the file over from the install pack to the your Windows directory – there are a number of registry settings that point to the file that would need to be set up correctly which is not at all trivial :-(

I also had a look at the log file that you included, but that looks like it is cut off at the point that you have displayed the filter dialogue – I was also unable to find any crash reports in my uploaded collection that I could track back to your model of camera. If you are getting the crash report window to appear then please try using the little down arrow on the 'Send and Quit' button to either send the bug report manually or via email – both are better for this sort of situation where we are trying to track down a specific issue. Allowing them to be uploaded is great, but I tend to go through the uploads looking for bugs that are occurring frequently rather than trying to find specific user issues.

Cheers, Robin

talanzaar
Posts: 4
Joined: Sun Jun 28, 2020 9:24 am

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by talanzaar » Sun Jun 28, 2020 7:46 pm

Hi,
Thanks very much for your response.
Apologies - must have attached the wrong log. This one clearly has the problem in - right at the end (see attached). I turned your "more verbose" option on too.

Your suggestion is correct regarding the driver - I had a dig around in regedit and noticed that none of these are registered:
;CAMERAGUID
HKCR,CLSID\%DTCS033.CAMERAGUID%,,,%USB\VID_0547&PID_7303.DeviceDesc%
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,,,DTCS033.ax
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,ThreadingModel,,Both

;SETUPGUID
HKCR,CLSID\%DTCS033.SETUPGUID%,,,%DTCS033.Setup%
HKCR,CLSID\%DTCS033.SETUPGUID%\InprocServer32,,,DTCS033.ax
HKCR,CLSID\%DTCS033.SETUPGUID%\InprocServer32,ThreadingModel,,Both

;SIZEGUID
HKCR,CLSID\%DTCS033.SIZEGUID%,,,%DTCS033.Size%"
HKCR,CLSID\%DTCS033.SIZEGUID%\InprocServer32,,,DTCS033.ax
HKCR,CLSID\%DTCS033.SIZEGUID%\InprocServer32,ThreadingModel,,Both

I.e. there's a DTSC03364.ax there but not a DTSC033.ax

I'm a controls engineer by trade, so I have some coding knowledge, but not the sort to attack windows installers with. The bit I don't understand is what's wrong with the .inf that means these chunks of code don't work. If you could point me at that, maybe I could correct it? Obviously you may have way better things to do, and as you say, if its overly complicated don't worry!

Cheers,
Jonathan
Attachments
Log_2020-06-28T20_12_53-10852.log
(28.26 KiB) Downloaded 5 times

User avatar
admin
Site Admin
Posts: 4334
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by admin » Mon Jun 29, 2020 7:34 pm

Hi,

okay, looking through your updated log file I can see that the problem is that a DLL called 'olepro32.dll' cannot be loaded. Searching on my computer I can only see 32-bit versions of that in the Windows directory and subdirectories, so I think the problem may be that there is no 64-bit version of the DLL.

Tinkering with the .inf file is a bit hit and miss – not least because that will then invalidate the digital signature in the .cat file, meaning you will need to reboot your computer in the special mode where the signature of drivers is not checked before allowing the edited driver to be installed.

I think that you kind of want to combine bits of the 32 bit section ([DTCS033.Dev]) with the 64 bit section ([DTCS03364.Dev]) - the bits you want are the 32 bit .ax file and the 32 bit registry entries. However I think any simple attempt on that will end up installing those files into the 64-bit system folder and the 64 bit registry rather than the 32-bit version of those places.

It may be easiest to look at your working 32 bit Windows install and copy things across from that - the 32 bit .ax file will probably be in c:\windows\system32 and should go to c:\windows\syswow64 (which is oddly the 32 bit directory). The registry entries will be in HKCR and should go into HKCR\Wow6432Node.

Procmon (from sysinternals) is your friend when trying this sort of thing - you can monitor registry/file system access in various applications to see if it is doing what you expect.

cheers,

Robin

talanzaar
Posts: 4
Joined: Sun Jun 28, 2020 9:24 am

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by talanzaar » Mon Jun 29, 2020 9:30 pm

Yes - thanks for that. I've been wondering about this all day at work... its far more interesting/challenging than what I supposed to be doing.

As you said, this comes down to the shonky driver install .inf (although probably not the 64-bit filter properties not loading).
If I get the 32-bit driver working properly I'll just use the 32-bit SharpCap.

I have realised (I think - I was being dense before) what's wrong with my dodgy driver .inf - the file is read sequentially, so for example it does these lines:
;CAMERAGUID
HKCR,CLSID\%DTCS033.CAMERAGUID%,,,%USB\VID_0547&PID_7303.DeviceDesc%
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,,,DTCS033.ax
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,ThreadingModel,,Both
[the 32 bit driver references]

Then they get overwritten by the 64 bit refs:
;CAMERAGUID
HKCR,CLSID\%DTCS033.CAMERAGUID%,,,%USB\VID_0547&PID_7303.DeviceDesc%
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,,,DTCS03364.ax
HKCR,CLSID\%DTCS033.CAMERAGUID%\InprocServer32,ThreadingModel,,Both
[the 64 bit driver references]

So it doesn't do the 32-bit refs - at all, and certainly not in the correct registry location.

I had a delve around, there's a similar driver available for some variant/clone of the same item (well TS and Omegon seem to have sold it as the same item at some point) that has a .inf I can pull apart (assuming it works).
The drivers don't work for my camera, but maybe I can steal the structure...
I.e. put the right refs in the HKCR\Wow6432Node, and move the 32 bit files to c:\windows\syswow64. Which is exactly what you are saying.

They have sections for 64-bit installs like this:
;HKCR,CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8},,,"iP298x Plug in"
;HKCR,CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8}\InprocServer32,,,iPPage8x.AX
;HKCR,CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8}\InprocServer32,ThreadingModel,,Both
;HKLM,System\CurrentControlSet\Control\MediaInterfaces\{E944B116-0757-4569-B234-B2D1FC7B2CE8},,,"iP298x Plug in"
;HKLM,System\CurrentControlSet\Control\MediaInterfaces\{E944B116-0757-4569-B234-B2D1FC7B2CE8},IID,1,16,b1,44,e9,57,07,69,45,b2,34,b2,d1,fc,7b,2c,e8
;HKCR,Wow6432Node\CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8},,,"iP298x Plug in"
;HKCR,Wow6432Node\CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8}\InprocServer32,,,iPPage8x.AX
;HKCR,Wow6432Node\CLSID\{E944B116-0757-4569-B234-B2D1FC7B2CE8}\InprocServer32,ThreadingModel,,Both

I.e. it properly discriminates between the 32-bit reg, and the 64-bit reg.

I didn't realise 64-bit drivers all have to be signed properly.

So the plan is - shift the files, and make a .reg file to sort me out. If it works I'll stick the solution on here

Remaining thoughts:
I need to work out the services from the driver.
Plus I think the Twain_32 references are depreciated.

Thanks,
Jonathan

User avatar
admin
Site Admin
Posts: 4334
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by admin » Mon Jun 29, 2020 10:07 pm

Hi,

I don't think you need to worry about the service side of things – that looks like it is set up to load the kernel driver - you only need the one version of that (the one that matches bitness of your operating system). As you say the twain stuff can be ignored as well – that's an ancient API for accessing scanners. The key is to get the 32 bit .ax file into the right place and the registry settings in place to point to it correctly. Actually the .ax file is just a DLL with a different extension.

Signatures on drivers come in two parts – the part on the actual binary driver files (*.sys) and the signature in the cat file which also verifies the content of the .inf file. Your cat file signature will be invalid so you will need to get Windows into the mode where it ignores driver signing before you can install. The signature on the .sys file will be valid which means that you don't need to stay in that mode afterwards – once the driver has been installed windows will be quite happy to load it every time.

I'm sure there's probably copious documentation on the .inf file format out there – although you may have to download the whole of the Microsoft Windows driver development kit (DDK) to get your hands on it. Whether it's actually going to be very helpful or not is another matter entirely :-)

good luck, Robin

talanzaar
Posts: 4
Joined: Sun Jun 28, 2020 9:24 am

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by talanzaar » Fri Jul 03, 2020 7:07 pm

Success in 32-bit SharpCap world - which is good enough for me. Thanks for your help Robin, as you suggested its not worth writing a new .inf. Just exported the relevant registry keys, and edited to correct.

Obviously clouds and rain now! Anyway, means I have another means to show off the night sky.

For anyone else who decides they want to make their ancient DTCS033 webcam-type solar system camera here's how to do it.

The registry mods to set the correct links to the filter are below. The only other requirement is to copy DTCS033.ax from the driver installer to C:\Windows\SysWOW64.

You can copy this text into a notepad file and save it with a ".reg" extension. Then double click to load the strings into the registry.

Here it is:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{73F5CCE2-7BAA-4568-850B-D787D580CE15}]
@="DTCS033 CCD USB2.0 Camera"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{73F5CCE2-7BAA-4568-850B-D787D580CE15}\InprocServer32]
@="DTCS033.ax"
"ThreadingModel"="Both"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{979B2B2B-019A-4f48-8949-3F94436EB2D1}]
@="DTCS033 SetupPage"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{979B2B2B-019A-4f48-8949-3F94436EB2D1}\InprocServer32]
@="DTCS033.ax"
"ThreadingModel"="Both"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{A7E6EC3A-DECF-4f8e-BA4E-433A86E160B6}]
@="DTCS033 SizePage"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{A7E6EC3A-DECF-4f8e-BA4E-433A86E160B6}\InprocServer32]
@="DTCS033.ax"
"ThreadingModel"="Both"

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{083863F1-70DE-11D0-BD40-00A0C911CE86}\Instance\{73F5CCE2-7BAA-4568-850B-D787D580CE15}]
"FriendlyName"="DTCS033 CCD USB2.0 Camera"
"CLSID"="{73F5CCE2-7BAA-4568-850B-D787D580CE15}"
"FilterData"=hex:02,00,00,00,00,00,20,00,01,00,00,00,00,00,00,00,30,70,69,33,\
08,00,00,00,00,00,00,00,01,00,00,00,00,00,00,00,00,00,00,00,30,74,79,33,00,\
00,00,00,38,00,00,00,48,00,00,00,76,69,64,73,00,00,10,00,80,00,00,aa,00,38,\
9b,71,7d,eb,36,e4,4f,52,ce,11,9f,53,00,20,af,0b,a7,70

[HKEY_CLASSES_ROOT\WOW6432Node\CLSID\{860BB310-5D01-11d0-BD3B-00A0C911CE86}\Instance\DTCS033 CCD USB2.0 Camera]
"FriendlyName"="DTCS033 CCD USB2.0 Camera"
"CLSID"="{73F5CCE2-7BAA-4568-850B-D787D580CE15}"
"FilterData"=hex:02,00,00,00,00,00,20,00,01,00,00,00,00,00,00,00,30,70,69,33,\
08,00,00,00,01,00,00,00,01,00,00,00,00,00,00,00,38,00,00,00,30,74,79,33,00,\
00,00,00,48,00,00,00,58,00,00,00,81,42,6c,fb,53,03,d1,11,90,5f,00,00,c0,cc,\
16,ba,76,69,64,73,00,00,10,00,80,00,00,aa,00,38,9b,71,7d,eb,36,e4,4f,52,ce,\
11,9f,53,00,20,af,0b,a7,70

User avatar
admin
Site Admin
Posts: 4334
Joined: Sat Feb 11, 2017 3:52 pm
Location: Vale of the White Horse, UK
Contact:

Re: TS Optics webcam (old) - not present 32bit / filter options cause crash in 64bit

Post by admin » Fri Jul 03, 2020 7:38 pm

Hi,

good to hear that you got it working, and thank you for sharing the REG file just in case somebody else needs to pull the same trick.

Cheers, Robin

Post Reply