Paul Stoffregen Posted August 12, 2010 Share Posted August 12, 2010 I'm looking for a few good Keyboard and Mouse examples to include in the upcoming Teensyduino ...to be released soon after Arduino 0019 comes out, which ought to be "real soon now". Of course, any examples contributed will give full credit to their authors. They will appear under in the menus, File > Examples > Teensy > (sub-category) Quote Link to comment Share on other sites More sharing options...
benownzu93 Posted August 12, 2010 Share Posted August 12, 2010 The first one I would include is just running a command or opening command prompt. void setup(){ run("cmd"); } void loop(){ digitalWrite(PIN_D6, LOW); delay(1000); digitalWrite(PIN_D6, HIGH); delay(1000); } void run(char *command){ delay(100); Keyboard.set_modifier(MODIFIERKEY_GUI); Keyboard.set_key1(KEY_R); Keyboard.send_now(); Keyboard.set_modifier(0); Keyboard.set_key1(0); Keyboard.send_now(); delay(400); Keyboard.print(command); delay(200); enter(); } void enter(){ Keyboard.set_key1(KEY_ENTER); Keyboard.send_now(); Keyboard.set_key1(0); Keyboard.send_now(); } Quote Link to comment Share on other sites More sharing options...
PineDominator Posted August 12, 2010 Share Posted August 12, 2010 A cool one I was thinking of is windows updates. it would be hard since some updates require custom input. like every time I reinstall from my rescue disc windows update takes about 7 restarts and a whole night "Hey windows 7 true auto update that works, was my idea". #2 would be nice to include all the good library s for the teensy that we have all been making. I am working on a awesome library for switches/dip/button and hopefully when I get the parts to solder on and test I will release in a couple weeks. another good way of white hat. would be a keyloging program on your computer then another program that could convert the logged ones to teensy code allso a way to manipulate the delays. with this you could take those mundane things and convert them to teensy code Paul thanks so much for all the great code and teensy. I had an issue with linksys because they were ignoring there 6 month old product and fixed all the issues on the newer one. still to this day they have not fixed a single issue. great to have people like you. that can get past bull$$$$ Quote Link to comment Share on other sites More sharing options...
BITS1 Posted August 12, 2010 Share Posted August 12, 2010 Hi Paul, This is uses the Mac Keyboard shortcuts to open the Spotlight, open up the textedit program, write Hello World! every 1 second while moving the mouse to a spontaneous place on the screen. Bits1 void setup(){ delay(2000); //opens spotlight Keyboard.set_modifier(MODIFIERKEY_GUI); Keyboard.send_now(); Keyboard.set_key1(KEY_SPACE); Keyboard.send_now(); //release keys Keyboard.set_modifier(0); Keyboard.set_key1(0); Keyboard.send_now(); delay(200); //open textedit application Keyboard.print("Textedit"); Keyboard.set_key1(KEY_ENTER); Keyboard.send_now(); Keyboard.set_key1(0); Keyboard.send_now(); } void loop(){ delay(1000); //prints Hello World Keyboard.println("Hello World!"); //Moves mouse to random places Mouse.move(random(-127,127), random(-127,127)); } Quote Link to comment Share on other sites More sharing options...
Mr-Protocol Posted August 12, 2010 Share Posted August 12, 2010 A cool one I was thinking of is windows updates. it would be hard since some updates require custom input. like every time I reinstall from my rescue disc windows update takes about 7 restarts and a whole night "Hey windows 7 true auto update that works, was my idea". I'd suggest creating a clone with like clonezilla and restore from that after you get all current updates made on the image. Quote Link to comment Share on other sites More sharing options...
sandred Posted August 13, 2010 Share Posted August 13, 2010 Tried this? http://www.hak5.org/forums/index.php?showtopic=16469 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.