It should type a "d" over and over. However, it types "D" over and over. Also, even when I unplug the Arduino, the key is still pressed. Can anyone help me?
even when I unplug the Arduino, the key is still pressed. Can anyone help me?
That is because you have to unplug it in the time between the release and the press, which is very very short. Insert a delay just before the end of the loop.
When I run your code I get lower case ds. Therefore there is nothing wrong with your code.
Your error lies not with your arduino but with the system you are feeding your arduino into.
Can you describe what you are doing. Operating system, other keyboards, application at the computer end.