Page 1 of 1
HID_Data with Delphi...
Posted: Sun Oct 24, 2010 11:48 am
by dzairo
Hi all.
I read this post
http://forums.obdev.at/viewtopic.php?f=8&t=3748 where some user iphi write so have
worked HID_data demo with Delphi.
Have any one this source or can contact me iphi sevc @ post at sk .
I'm too interesting to use any HID project with Delhi
I create project for UART-CDC project - read RFID chip, use small I2C LCD and some button . for control use standard serial port (after install driver) set speed 600bps and work.
But I want make own application with out of install driver ..
regards
Re: HID_Data with Delphi...
Posted: Wed Oct 27, 2010 8:17 pm
by dzairo
no one use delphi with Hid?
help pls with this
regarst
Re: HID_Data with Delphi...
Posted: Wed Oct 27, 2010 10:04 pm
by maxi
Perhaps you will get a better reply on the Delphi forums. Working example code has been provided which can be compiled under MinGW or even MSVC (with a few tweaks). The biggest problem I think you will face is finding a compatible version of the Driver Delevopment Kit (DDK) required to compile the HID-tool executable.
Re: HID_Data with Delphi...
Posted: Thu Oct 28, 2010 9:20 am
by dzairo
Hi maxi.
More user write on this forum so use any V-USB example with jvHidControllerClass for Delphi.
But no more information can find.
On jvHid is more example .
If use this example then can find and see information for all HID devices connected in System (VID , PID, serial number ...)
but how use it for read and write data in to MCU ????
If try example posted from this forum no one work good.
On this forum are users what can help but I don't have contact to send email. Just nick on this forum.
Maybe it's not hard just don't know from where start.
regards
Re: HID_Data with Delphi...
Posted: Thu Oct 28, 2010 10:45 pm
by maxi
dzairo wrote:On jvHid is more example .
If use this example then can find and see information for all HID devices connected in System (VID , PID, serial number ...)
but how use it for read and write data in to MCU ????
Is there not also an example of how to read/write? I do not use Delphi myself nor do I have any knowledge of the jvHidController class but a quick google tells me it's part of the JEDI Visual Component Library
http://jvcl.delphi-jedi.org/. Looks like it comes with plenty of examples and documentation. As far a the jvHid is concerned a v-usb hid device should behave the same as any other usb hid device.
Re: HID_Data with Delphi...
Posted: Fri Oct 29, 2010 9:43 am
by dzairo
maxi.
I use this component. if use any example then show you all HID device on system and if click on info button then show VID and PID number , serial number .... .
there is place for enter ID number report and button read and write and it's all. But how can I read data from mcu and send???
there just had not understood thing which is crucial in use, and here I do not know
regards
Re: HID_Data with Delphi...
Posted: Sat Oct 30, 2010 8:23 pm
by Valeron
on event "OnEnumerate"
Code: Select all
...
if (HidDev.Attributes.VendorID=VID) and (HidDev.Attributes.ProductID=PID) then begin
Dev:=HidDev; //Global variable
eDev.Text:=Dev.ProductName; //my label
Dev.CheckOut;
end;
...
on event "ButtonClick"
Code: Select all
var Raw:array[0..9] of byte; //length of Raw must be = Dev.Caps.OutputReportByteLength
Writed:Cardinal;
...
if Dev=nil then exit;
Raw[0]:=$01; //Your Report ID, i use 0x01
Raw[1]:= ...... // your data
Raw[xx]:=...
Dev.WriteFile(Raw[0],Dev.Caps.OutputReportByteLength,Writed);
...
Dev.Caps.OutputReportByteLength - length of output report descriptor
Now I make an USB-application, if you have a questions, call ICQ 454817422