Arduino string / password keyboard emulator using reset button

Arduino has a nice Keyboard library that allows it to pretend to be a keyboard to any host it is connected to. This allows you to automatically “type” passwords or strings, eliminating a potential source of error (though this still obviously exists while programming the arduino). Unlike other examples, this does not require you to have an external button or the like. The reset button will simply act as the activator.

To start the “typing” of the string, either plug the arduino into the USB port or if already connected to the USB port, simply press the arduino’s reset button and it will print the programming string. On the Arduino Due, you will have to connect the USB cable to the “native USB” port, rather than the programming port.

Here’s the code arduino code:

void setup() {
  // do not remove this delay or you will brick the arduino
  delay(1000);
  Keyboard.begin();
  Keyboard.println("replace with string to be printed");
  Keyboard.end();
}

void loop() {
  // put your main code here, to run repeatedly:
}
 
8
Kudos
 
8
Kudos

Now read this

Apple removing outdated iPads and iPhones

After Apple’s presentation on March 21st 2016 it seems as if they have listened to my previous post on their line-up, at least with regards to the internals. All iPhones and all apart from one iPad now have the latest or previous... Continue →