I am having problem precisely reading in a pulse-width signal on a telosb node.
This code runs, but I think errors are coming from non-deterministic execution of events between this and other events in the code. async event void pwminput.fired() { uint16_t time; time = call Counter.get(); atomic { if (edgeState == TRUE) { startEdge = time; edgeState = FALSE; } else { endEdge = time; local.readings[0] = endEdge-startEdge; edgeState = TRUE; } } call pwminput.clear(); call pwminput.edge(edgeState); } I noticed that there is a GpioCapture interface as part TinyOS but I can not figure out how to attach it to an external pin. Can anyone offer some suggestions or example code that I can base my system off of. Thanks, Timothy Hnat h...@cs.virginia.edu _______________________________________________ Tinyos-help mailing list Tinyos-help@millennium.berkeley.edu https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help