mirror of
https://github.com/eclipse/upm.git
synced 2025-03-19 06:57:30 +03:00
23 lines
442 B
C
23 lines
442 B
C
![]() |
//Modified: Abhishek Malik <abhishek.malik@intel.com>
|
||
|
|
||
|
#include <stdio.h>
|
||
|
#include <stdlib.h>
|
||
|
#include <string.h>
|
||
|
#include <stdlib.h>
|
||
|
#include <unistd.h>
|
||
|
#include "collision.h"
|
||
|
|
||
|
int main()
|
||
|
{
|
||
|
collision_context dev = collision_init(2);
|
||
|
bool abc = 0;
|
||
|
while(1){
|
||
|
if(collision_is_colliding(dev, &abc) != UPM_SUCCESS){
|
||
|
printf("an error has occured\n");
|
||
|
}
|
||
|
upm_delay(1);
|
||
|
printf("value retrieved: %d\n", abc);
|
||
|
}
|
||
|
collision_close(dev);
|
||
|
}
|