Hi Michael,
I tried with different 'NREADINGS' in the following structure: (I am using
TinyOS-2.1.0)
typedef nx_struct oscilloscope {
nx_uint16_t version; /* Version of the interval. */
nx_uint16_t interval; /* Sampling period. */
nx_uint16_t id; /* Mote id of sending mote. */
nx_uint16_t count; /* The readings are samples count * NREADINGS onwards
*/
nx_uint16_t readings[NREADINGS];
} oscilloscope_t;
It seems that you r right. 1st reading is the number of readings and the
2nd reading is 0. The rest is the meaningfull data.
However, there is not any clue about this in the ReadStream Interface. Is it
the intended way?
I thought that you pass the buffer with the following command
command error_t postBuffer(val_t * buf, uint16_t count);
And then
On Sun, May 31, 2009 at 9:36 AM, Michael Schippling <[email protected]>wrote:
> Could that just be the count of readings?
> MS
>
> Mehmet Akif Antepli wrote:
>
>> Hi,
>> I am using trying to take magnetic sensor data from MTS310 sensor board
>> (I use MicaZ motes). I have modified oscilloscope application. When I use
>> MagXC and MagYC interfaces, it works, but I want to increase the sampling
>> rate so i used MagXStreamC and MagYStreamC interfaces.
>>
>> I use the same message structure as in the Osciiloscope application. In
>> the oscilloscope_t struct, there is the field 'readings' which keeps 10
>> sensor readings. The problem is that , first two entries in the 'readings'
>> array, are 0xa0 and 0x0 and they never change. Data in the rest of the array
>> is correct.
>> I can get rid of those 'dummy' values. I just ignore them and send the
>> meaningful data over the radio to the base-station mote.
>> But it shouldn't be this way and i couldn't figure out what i am doing
>> wrong. Maybe there is problem in the low level i2c code.
>> Could anyone help me with this issue?
>>
>> Thanks in advance,
>>
>> --
>> Mehmet Akif Antepli
>> Graduate student
>> Dept. of EEE
>> Middle East Technical University
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Tinyos-help mailing list
>> [email protected]
>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
>>
>
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help