|
1 /* |
|
2 * Copyright 2005-2006 Intel Corporation |
|
3 * |
|
4 * Licensed under the Apache License, Version 2.0 (the "License"); |
|
5 * you may not use this file except in compliance with the License. |
|
6 * You may obtain a copy of the License at |
|
7 * |
|
8 * http://www.apache.org/licenses/LICENSE-2.0 |
|
9 * |
|
10 * Unless required by applicable law or agreed to in writing, software |
|
11 * distributed under the License is distributed on an "AS IS" BASIS, |
|
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|
13 * See the License for the specific language governing permissions and |
|
14 * limitations under the License. |
|
15 */ |
|
16 |
|
17 /* tab:4 |
|
18 * "Copyright (c) 2000-2003 The Regents of the University of California. |
|
19 * All rights reserved. |
|
20 * |
|
21 * Permission to use, copy, modify, and distribute this software and its |
|
22 * documentation for any purpose, without fee, and without written agreement is |
|
23 * hereby granted, provided that the above copyright notice, the following |
|
24 * two paragraphs and the author appear in all copies of this software. |
|
25 * |
|
26 * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR |
|
27 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT |
|
28 * OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF |
|
29 * CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
|
30 * |
|
31 * THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, |
|
32 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY |
|
33 * AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS |
|
34 * ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO |
|
35 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS." |
|
36 * |
|
37 * Copyright (c) 2002-2003 Intel Corporation |
|
38 * All rights reserved. |
|
39 * |
|
40 * This file is distributed under the terms in the attached INTEL-LICENSE |
|
41 * file. If you do not find these files, copies can be found by writing to |
|
42 * Intel Research Berkeley, 2150 Shattuck Avenue, Suite 1300, Berkeley, CA, |
|
43 * 94704. Attention: Intel License Inquiry. |
|
44 */ |
|
45 /* |
|
46 * Authors: Nelson Lee |
|
47 * Date last modified: 6/27/02 |
|
48 * |
|
49 */ |
|
50 |
|
51 /* Message types used by Oscope. */ |
|
52 |
|
53 /** |
|
54 * @author Nelson Lee |
|
55 */ |
|
56 |
|
57 #ifndef OSCOPEMSG_H |
|
58 #define OSCOPEMSG_H |
|
59 |
|
60 enum { |
|
61 BUFFER_SIZE = 10 |
|
62 }; |
|
63 |
|
64 typedef struct |
|
65 { |
|
66 uint16_t sourceMoteID; |
|
67 uint16_t lastSampleNumber; |
|
68 uint16_t channel; |
|
69 uint16_t data[BUFFER_SIZE]; |
|
70 }OscopeMsg; |
|
71 |
|
72 typedef struct |
|
73 { |
|
74 uint16_t sourceMoteID; |
|
75 uint16_t lastSampleNumber; |
|
76 uint16_t channel; |
|
77 }OscopeAck; |
|
78 |
|
79 struct OscopeResetMsg |
|
80 { |
|
81 /* Empty payload! */ |
|
82 }; |
|
83 |
|
84 |
|
85 enum { |
|
86 AM_OSCOPEMSG = 10, |
|
87 AM_OSCOPEACK = 37, |
|
88 AM_OSCOPERESETMSG = 32 |
|
89 }; |
|
90 |
|
91 #endif //OSCOPEMSG_H |