Page 1 of 1

KEYBOARD USB HID

Posted: Tue Sep 29, 2015 10:33 pm
by Genilsonsa
Good use Flowcode 6.Estou problem with the USB HID simulation in WINDOW 10. Do not recognize the window 10 of the following message. "FAULT DISPOSITIVO.Como DESCRIPTOR REQUEST do I solve? Thanks

Re: KEYBOARD USB HID

Posted: Tue Sep 29, 2015 10:35 pm
by Genilsonsa
WINDOWS does not detect the device.

Re: KEYBOARD USB HID

Posted: Tue Sep 29, 2015 10:37 pm
by Genilsonsa
Arquivo

Re: KEYBOARD USB HID

Posted: Wed Sep 30, 2015 12:04 am
by kersing
Have you made sure your clock settings (OSC settings in configuration and clock speed in project options) match and are correct? The 20MHz clock speed looks suspicious when checking the configuration settings and the table on page 31 of the data sheet.

Also, what hardware are you using? Do you have a 220nF capacitor connected between Vusb pin (14 for PDIP/SOIC) and ground?

Re: KEYBOARD USB HID

Posted: Wed Sep 30, 2015 1:57 am
by Genilsonsa
Hello thank you for me responder.Eu made the settings the same as this example of BEN modified for forum.Alterei mate only the crystal to 20mhz.Utilizo breadboard.

Re: KEYBOARD USB HID

Posted: Wed Sep 30, 2015 2:00 am
by Genilsonsa
Este é o programa teste que modifiquei para meu uso.

Re: KEYBOARD USB HID

Posted: Fri Oct 02, 2015 1:16 am
by Genilsonsa
Hello fortunately managed to make my funcionar.O error in hardware design was lack of capacitor 470 to terra.Muito thank you for answering me. KERSING

Re: KEYBOARD USB HID

Posted: Fri Oct 02, 2015 1:24 am
by Genilsonsa
My question is now shipping a value in education "SENDDATADIRECT" which seems to be a DO STRING.Como to send word "A" .Escrevo eg SENDDATADIRECT "0x04" But in string format?

Re: KEYBOARD USB HID

Posted: Fri Oct 02, 2015 1:30 am
by Genilsonsa
I write as STRING or HEX?

KeyPress Code KeyPress Code
A 0x04 X 0x1B
B 0x05 Y 0x1C
C 0x06 Z 0x1D
D 0x07 Carriage Return 0x28
E 0x08 Tab 0x2B
F 0x09 Caps Lock 0x39
G 0x0A Scroll Lock 0x47
H 0x0B Num Lock 0x53
I 0x0C / 0x54
J 0x0D * 0x55
K 0x0E - 0x56
L 0x0F + 0x57
M 0x10 1 0x59
N 0x11 2 0x5A
O 0x12 3 0x5B
P 0x13 4 0x5C
Q 0x14 5 0x5D
R 0x15 6 0x5E
S 0x16 7 0x5F
T 0x17 8 0x60
U 0x18 9 0x61
V 0x19 0 0x62
W 0x1A \ 0x64

Re: KEYBOARD USB HID

Posted: Mon Oct 05, 2015 4:56 pm
by Benj
Hello,

Perhaps these files would help.
HID Keyboard Scan Codes.xls
(37.5 KiB) Downloaded 549 times
http://www.matrixtsl.com/wiki/index.php ... 7a31b97c2a

The keyboard is a bit strange you have 8 bytes from the micro to the PC for the key scan code (2 bytes for modifiers such as shift or control and 6 bytes for alphanumeric keys) and one byte from the PC to the micro for status LEDs caps lock etc.

The key scan code is send as 8 bytes to allow multiple key combinations to be pressed or held at once.

Re: KEYBOARD USB HID

Posted: Sat Oct 29, 2016 6:05 pm
by Genilsonsa
Hello everyone I am raising this topic i know that it has all the features released,but i am wanting to emulate a keyboard HID and i need the ENTER key.Is it possible someone having the key value

Re: KEYBOARD USB HID

Posted: Mon Oct 31, 2016 1:19 pm
by Benj
Hello,

This should give you an enter key.

Data[2] = 0x28

Taken from here, under the Keyboard section.
http://www.freebsddiary.org/APC/usb_hid_usages.php

It is listed in my Keyboard Scan Codes Excel document but is listed as Carriage Return so I missed it at first.

Re: KEYBOARD USB HID

Posted: Mon Oct 31, 2016 2:23 pm
by Genilsonsa
Hello thank Benj again for me reply.
:D

Re: KEYBOARD USB HID

Posted: Sun Nov 27, 2016 11:41 am
by George_B
Hello,

i would like to modify the attached FC6 program so it will send ten lines of predefined (fixed) text to my computer.

The attached file is taken from the USB HID component examples. What it does is just to send a line of text every 5 seconds.

I tried to modify the program but i am missing something.

Any thoughts about it?

Thanks in advance
George

Re: KEYBOARD USB HID

Posted: Mon Nov 28, 2016 12:57 pm
by Benj
Hi George,

It looks to me like you're close though I haven't spotted anything incorrect yet. Are you getting anything out of it at the moment?

Maybe the CheckRx needs to be in the loop after the KeyUp macro?

Re: KEYBOARD USB HID

Posted: Thu Dec 01, 2016 10:00 am
by George_B
Benj wrote:Hi George,

It looks to me like you're close though I haven't spotted anything incorrect yet. Are you getting anything out of it at the moment?

Maybe the CheckRx needs to be in the loop after the KeyUp macro?

Hi Benj,

At the moment i get only the "Hello From Your USB Keyboard Device! 12345\n" text every 5 seconds.

It looks like this:
Hello From Your USB Keyboard Device! 12345
Delay 5s
Hello From Your USB Keyboard Device! 12345
Delay 5s
Hello From Your USB Keyboard Device! 12345
Delay 5s
Hello From Your USB Keyboard Device! 12345
Delay 5s..

I would like to modify the program so i will take 10 different lines of text. For example:


Text for line 1
Delay 5s
Text for line 2
Delay 5s
Text for line 3
Delay 5s
Text for line 4
Delay 5s
Text for line 5
Delay 5s
Text for line 6
Delay 5s
Text for line 7
Delay 5s
Text for line 8
Delay 5s
Text for line 9
Delay 5s
Text for line 10
Delay 5s

Re: KEYBOARD USB HID

Posted: Thu Dec 01, 2016 6:19 pm
by Benj
This should hopefully help.
USB_HID_Keyboard_Strings.fcfx
(24.48 KiB) Downloaded 304 times

Re: KEYBOARD USB HID

Posted: Sat Dec 03, 2016 5:00 pm
by George_B
Benj wrote:This should hopefully help.
USB_HID_Keyboard_Strings.fcfx


Thank you very much Benj! That was exactly what i was looking for! :D


George