| int main()  
{  
    Thread thread(led_thread);  
    thread2 = new Thread(scan_thread);  
  
  //  sw2.fall(&sw2_press);  
    tick.attach(&sw2_press,0.001);   //scan MMA8451Q ervery 0.01s  
    while (true) {  
        Thread::wait(1);  
        mouse.move( y*127,x*127);  
        printf("\r\n 0.1 seconds passed: %f,%f,%f,%f \r\n", x,y,z,t);  
        fflush(stdout);  
    }  
}  
 |