mirror of
https://github.com/eclipse/upm.git
synced 2025-03-24 17:30:01 +03:00
dfrph_c_example: Fixed small copy/paste error
Removed urm37 string. Re-aligned source. Signed-off-by: Noel Eck <noel.eck@intel.com>
This commit is contained in:
parent
c0bff584d5
commit
668aa320b9
@ -39,7 +39,7 @@ int main()
|
|||||||
{
|
{
|
||||||
signal(SIGINT, sig_handler);
|
signal(SIGINT, sig_handler);
|
||||||
|
|
||||||
//! [Interesting]
|
//! [Interesting]
|
||||||
|
|
||||||
// Instantiate a dfrph sensor on analog pin A0
|
// Instantiate a dfrph sensor on analog pin A0
|
||||||
dfrph_context sensor = dfrph_init(0);
|
dfrph_context sensor = dfrph_init(0);
|
||||||
@ -50,9 +50,7 @@ int main()
|
|||||||
return(1);
|
return(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Every half a second, sample the URM37 and output the measured
|
// Every half a second, sample the sensor output
|
||||||
// distance in cm.
|
|
||||||
|
|
||||||
while (shouldRun)
|
while (shouldRun)
|
||||||
{
|
{
|
||||||
float volts = 0.0, pH = 0.0;
|
float volts = 0.0, pH = 0.0;
|
||||||
@ -66,7 +64,7 @@ int main()
|
|||||||
usleep(500000);
|
usleep(500000);
|
||||||
}
|
}
|
||||||
|
|
||||||
//! [Interesting]
|
//! [Interesting]
|
||||||
|
|
||||||
printf("Exiting\n");
|
printf("Exiting\n");
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user