Hi All
I have implemented the readstream interface for the microphone but since I
am doing high sampling (10KHz) I decided to check whether I am actually
getting a sampling period close to 100 micro-secs. When I try to printout
the actualPeriod from inside readDone I get the value 370 continuously (I am
looping the calls by posting tasks)
I would be fine with 370 micro-second as the period as well but the problem
is the LED indicators as well as these print statements (instead of coming
at a very fast rate considering my buffer size is only 1000) come at almost
1 per second. Is there a hardware limit that I am reaching ??
I have the following code:
===============================================================
event void ReadStream.readDone(error_t result, uint32_t actualPeriod)
{
if (result == SUCCESS && streamSuccess)
{ printf("Actuall Period is: %ld\n",actualPeriod);
printfflush();
post sampleData();
}
}
task void sampleData(){
call ReadStream.postBuffer(buf1, BUF_SIZE);
call ReadStream.read(128);
}
===============================================================
I would be grateful to anyone who replies !!!
--
First they ignore you, then they laugh at you, then they fight you, then you
win.
- Mahatma Gandhi
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help