1/1
Need Clarifiaction USB 1.1 Interrupt Endpoint
by Unknown on Jan 15, 2005 |
Not available! | ||
Hello all,
I have a Question regarding USB 1.1 Endpoint . First Let me describe what I'm doing using USB Core. I developed PS2 Keyboard to USB application using USB 1.1 core. I wrote PS2 Interface logic and gluelogic to store ASCII value of the Pressed Key in Endpoint 5. [ Endpoint 5 is configured as IN , INTERRUPT with max of 64 Byte transfer. I use Windriver USB software to read USB Port. ep5_cfg = `INT | `IN | 14'd0001 Device Enumeration is taking place properly and i could see all the endpoints with the same setup mentioned in usb1_rom.v file. The Problem i'm facing is like , what ever the data i type in Keyboard , It is read and displayed TWICE. I checked the behavioral simulation and saw that the data is stored in Endpoint FIFO only once with WE for FIFO is kept asserted for 1 Clock Pulse. I even tried to store the data into Endpoint FIFO continuously and then Invoked Windriver software. Then also each character is displayed TWICE [ i.e., . i Typed rama ..But i received as ..rraammaa ]. Is this the Problem with INTERRUPT Transfer Mechanism the way i configred. or Could it be the Problem of Windriver Software ?.. Can anyone clarify me where exactly the Problem and how can i overcome this ? It would be grate Helpful for me. Thanks in Advance , Ramachandiran.V |
Need Clarifiaction USB 1.1 Interrupt Endpoint
by Unknown on Jan 17, 2005 |
Not available! | ||
Ramachandiran V wrote on Sat, 15 Jan 2005 16:21:18 +0530
The Problem i'm facing is like , what ever the data i type in Keyboard , It is read and
One simple test: do the characters appear twice when you press a key or
once when you press it and then a second time when you release it?
For example: when you press the "A" key the PS/2 interface sends a scan
code of 0x1C and when you release it sends a 0xF0 followed by a 0x1C,
which is three bytes in all. If you just convert the 0x1C to ASCII and
ignore the 0xF0 you will get two "a"s on your screen. The reason why the
AT keyboard works this way is so you can detect when some key is being
held down and not just when it is pressed. This doesn't always work very
well (see "n key rollover" and autorepeat for complications) but is what
makes the keyboard a practical input device for games.
Check out
http://panda.cs.ndsu.nodak.edu/~achapwes/PICmicro/keyboard/scancodes2.ht
ml
Your problem is probably something else, but it is always good to check
your basic assumptions when debugging.
Good luck,
-- Jecel
displayed TWICE. I checked the behavioral simulation and saw that the data is stored in Endpoint FIFO only once with WE for FIFO is kept asserted for 1 Clock Pulse. |
1/1