Delphi-libUSB for Delphi2010

General discussions about V-USB, our firmware-only implementation of a low speed USB device on Atmel's AVR microcontrollers
Post Reply
test

Delphi-libUSB for Delphi2010

Post by test » Thu Jul 04, 2013 5:25 pm

Hi everyone,

I just download the PowerSwitch_Delphi Source and run the USBTest.exe.
It detected my PowerSwitch baord, and everything works great.

And then I tried open the source code with Delphi 2010 and recompile the code without altering any of the code.
The code complied without any error but it failed to detect my board.
Has anyone encoutered the same problem?


grimmjaw

vouvoume

Re: Delphi-libUSB for Delphi2010

Post by vouvoume » Fri Jul 05, 2013 9:48 am

Hi test.

Maybe it is a string problem (in the vendor definitions). I recall they have changed string handling from UTF8 to UTF16 it in D2010.
Since the VUSB host software looks for some specific vendor string this might explain why your error occurs.
(Perhaps you have to cast the strings by yourself.)

grimmjaw
Posts: 1
Joined: Thu Jul 04, 2013 5:18 pm

Re: Delphi-libUSB for Delphi2010

Post by grimmjaw » Fri Jul 05, 2013 10:17 am

Hi vouvonne,

thanks for the info, actually i have resolved the problem, it seem that in char is not usable in delphi 2010.
I replaced all char with Ansichar and everything seem to be working now.
Thanks again

grimmjaw

vouvoume

Re: Delphi-libUSB for Delphi2010

Post by vouvoume » Sat Jul 06, 2013 2:01 am

glad I could help

Post Reply