reads the sensor data
Dependencies: MAG3110 MMA8451Q SLCD TSI mbed-src
Fork of KL46Z by
Revision 1:e62070cc6725, committed 2014-02-06
- Comitter:
- rajkiran_anthapur
- Date:
- Thu Feb 06 00:46:24 2014 +0000
- Parent:
- 0:52fadadad843
- Child:
- 2:cec387091316
- Commit message:
- n2;
Changed in this revision
--- a/main.cpp Mon Oct 14 14:57:22 2013 +0000 +++ b/main.cpp Thu Feb 06 00:46:24 2014 +0000 @@ -15,8 +15,8 @@ PwmOut rled(PTE29); PwmOut gled(PTD5); AnalogIn lightSensor(PTE22); -DigitalIn SW1(PTC3); -DigitalIn SW3(PTC12); +DigitalIn sw1(PTC3); +DigitalIn sw3(PTC12); //AnalogOut lcd03(PTB23); //PwmOut lcd07(PTB7); @@ -41,18 +41,19 @@ gled = onTime - abs(acc51.getAccY()); mag.getValues(&magX, &magY, &magZ); - cout << "MMA8451: " << acc51.getAccX() << "\t" << acc51.getAccY() << "\t" << acc51.getAccZ() << "\n\r" << endl; - cout << "MAG3110: " << magX << "\t" << magY << "\t" << magZ << "\n\r" << endl; - cout << "MAG3110: " << mag.getHeading() << "\n\r" << endl; - wait(holdTime); +// cout << "MMA8451: " << acc51.getAccX() << "\t" << acc51.getAccY() << "\t" << acc51.getAccZ() << "\n\r" << endl; +// cout << "MAG3110: " << magX << "\t" << magY << "\t" << magZ << "\n\r" << endl; +// cout << "MAG3110: " << mag.getHeading() << "\n\r" << endl; +// wait(holdTime); rled = tsi.readPercentage(); gled = tsi.readPercentage(); - cout << "Touch: " << tsi.readPercentage() << "\n\r" << endl; - cout << "SW1: " << SW1 << "\n\r" << endl; - cout << "SW3: " << SW3 << "\n\r" << endl; - cout << "Light Sensor: " << lightSensor << "\n\r" << endl; +// cout << "Touch: " << tsi.readPercentage() << "\n\r" << endl; +// cout << "SW1: " << sw1 << "\n\r" << endl; +// cout << "SW3: " << sw3 << "\n\r" << endl; +// cout << "Light Sensor: " << lightSensor << "\n\r" << endl; + cout << acc51.getAccX(); wait(holdTime); } return 0;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed-src.lib Thu Feb 06 00:46:24 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed-src/#f54042cbc282
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Thu Feb 06 00:46:24 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/824293ae5e43 \ No newline at end of file