]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/ferret/include/sensors/scalar.h
Update
[l4.git] / l4 / pkg / ferret / include / sensors / scalar.h
1 /**
2  * \file   ferret/include/sensors/scalar.h
3  * \brief  Functions to operate on the most basic sensors type: scalars.
4  *
5  * \date   08/11/2005
6  * \author Martin Pohlack  <mp26@os.inf.tu-dresden.de>
7  * \author Bjoern Doebel   <doebel@tudos.org>
8  */
9 /*
10  * (c) 2005-2009 Technische Universität Dresden
11  * This file is part of TUD:OS and distributed under the terms of the
12  * GNU General Public License 2.
13  * Please see the COPYING-GPL-2 file for details.
14  */
15 #ifndef __FERRET_INCLUDE_SENSORS_SCALAR_H_
16 #define __FERRET_INCLUDE_SENSORS_SCALAR_H_
17
18 #include <l4/ferret/sensors/common.h>
19 #include <l4/ferret/types.h>
20
21 /* fixme: - convert data to array
22  *        - optionally support word sized data entries for faster access
23  */
24
25 typedef struct
26 {
27     ferret_common_t header;
28
29     ferret_time_t   low;       // lower bound for valid range
30     ferret_time_t   high;      // upper bound for valid range
31     ferret_time_t   val_min;   // minimum value put in so far
32     ferret_time_t   val_max;   // maximum value put in so far
33     long long       val_count; // number of values inserted
34     ferret_time_t   val_sum;   // sum of all values inserted
35     ferret_time_t   data;      // finally the data itself
36 }  ferret_scalar_t;
37
38 #endif