Test and Measurement Forum

Unable to open device. Status code: 0xC

Post your C and C++ discussions here

Unable to open device. Status code: 0xC

Postby csarm » Tue Jul 05, 2011 9:43 pm

Hardware: Omega PT-104A
Software: USBpt104sdk_r10_1_0_17.zip downloaded today from picotech.com

Example program 'USBPT104con' was extracted from the zip file above and compiled with Embarcadero (formerly Borland) C++Builder XE version 15.0.

I had to change '_kbhit' to 'kbhit' but otherwise the example program compiled fine. But when it is run the output is:

Select connection:
U: USB
E: Ethernet

Unable to open device. Status code: 0xC

The PT-104A is connected and will talk to the Logging Recorder software that came with it.

How can I talk to it directly with a C program?
csarm
 

Re: Unable to open device. Status code: 0xC

Postby Martyn » Mon Jul 11, 2011 8:57 am

I have been able to replicate your issue and have found an issue with the lib file. Attached is a modified file which has been checked with Embarcadero C++Builder XE so please use it to replace the previous version.
Attachments
UsbPt104bc.zip
(799 Bytes) Downloaded 213 times
Martyn
Technical Specialist
Martyn
Site Admin
Site Admin
 
Posts: 2285
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: Unable to open device. Status code: 0xC

Postby Uaconli » Mon Jul 11, 2011 1:11 pm

I have the same problem (Unable to open device - error code 0xc), I am also using C++ Bulider XE by Embarcadero, but I am trying to connect Picoscope 5203 under WIN 7 - 64 bit .. currently I am using an old version of the sw/driver and the old C++ builder 2006 all running under win xp in a VMware window, but this is very annoying ... do you think that the solution can be the same?

Thanks a lot!
Uaconli
 

Re: Unable to open device. Status code: 0xC

Postby Martyn » Wed Jul 13, 2011 8:24 am

Can you try using coff2omf.exe at a command prompt to convert ps5000.lib into a lib file for use in C++ Bulider XE

The executable can be found in the Embarcadero bin directory and is used :-

coff2omf ps5000.lib newps5000bc.lib
Martyn
Technical Specialist
Martyn
Site Admin
Site Admin
 
Posts: 2285
Joined: Fri Jun 10, 2011 8:15 am
Location: St. Neots

Re: Unable to open device. Status code: 0xC

Postby Uaconli » Thu Jul 14, 2011 12:16 pm

**************
* ThankYou *
**************
Now it works under WIN7 X64
Uaconli
 


Return to C and C++

Who is online

Users browsing this forum: No registered users and 0 guests