... | ... | @@ -56,7 +56,7 @@ TestSensor* sensor; |
|
|
|
|
|
void testCallback() {
|
|
|
float data = *(sensor->testDataPtr());
|
|
|
TRACE("Test data : %f \n", data);
|
|
|
printf("Test data : %f \n", data);
|
|
|
}
|
|
|
|
|
|
int main() {
|
... | ... | @@ -68,5 +68,14 @@ int main() { |
|
|
sensor_manager.addSensor(sensor, frequency, callback, SIMPLE_SAMPLER);
|
|
|
|
|
|
sensor_manager.start();
|
|
|
|
|
|
// avoid the program to stop
|
|
|
for (;;)
|
|
|
{
|
|
|
miosix::ledOn();
|
|
|
miosix::Thread::sleep(1000);
|
|
|
miosix::ledOff();
|
|
|
miosix::Thread::sleep(1000);
|
|
|
}
|
|
|
}
|
|
|
``` |
|
|
\ No newline at end of file |