start = clock(); | |
for(count = 0; count <1000; count++) | |
{ | |
filed = open("/sys/bus/iio/devices/iio:device1/in_voltage0_raw", O_RDWR ); | |
nbytes = read(filed, buf, 16); | |
close(filed); | |
} |
end = clock(); |
takes 200 ms.
start = clock(); | |
for(count = 0; count <1000; count++) | |
{ | |
filed = open("/sys/bus/iio/devices/iio:device1/in_voltage0_raw", O_RDWR ); | |
nbytes = read(filed, buf, 16); | |
close(filed); | |
} |
end = clock(); |
takes 200 ms.