// the hid object Hid hid; HidMsg msg; // open the hid if( !hid.openKeyboard( 0 ) ) me.exit(); // ready <<< "ready...", "" >>>; // event while( true ) { // this waits for activity on device hid => now; // drain the queue, one by one while( hid.recv( msg ) ) { <<< now, "" >>>; if( msg.isButtonDown() ) { <<< "down:", msg.key, msg.ascii >>>; } } }