Hi Michael Schippling, The problem is it is difficult processing in the 'DemoSensorC' , as 'DemoSensorC' only provide one interface 'Read' with one data. I tried to set up a 'DemoSensorXC' and a 'DemoSensorYC', which want to read X and Y acceletation data separately, and use interface 'AccelXC' and 'AccelYC' correspondingly. However, the compile cannot find 'DemoSensorXC' and 'DemoSensorYC'.
How about I use 'ReadStream' or 'AccelReadStreamP'? regards, Fangming On 5/7/07, Michael Schippling < [EMAIL PROTECTED]> wrote:
You will need to create two DemoSensor type files that differ only in their ADC channels. Or for extra credit you can just eliminate the entire DemoSensor thing and just use ADC[x] & ADC[y], where x and y are the channel numbers of interest. Generally you could use a Timer to fire off the first ADC.getData() conversion and then in the dataReady() of that ADC, fire the next one. There is some indication that you could do both getData()'s in the timer fire routine -- and internal ADC queuing code will handle the sequencing -- but I haven't actually tried it... seem reasonable? MS Fangming Zhang wrote: > Hi everyone, > > I use a MTS310 to read the accelometer data, X and Y. The wireless > platform is micaz. My difficulty is how to implement measure and put the > X and Y acceleration in one 'DemoSensorC' file. It seems the interface > 'Read' can only read one AD port. How can I do? > > Regards, > Fangming > > > ------------------------------------------------------------------------ > > _______________________________________________ > Tinyos-help mailing list > [email protected] > https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
_______________________________________________ Tinyos-help mailing list [email protected] https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
