Contiki 3.x
dot-15-4g.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015, Texas Instruments Incorporated - http://www.ti.com/
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
8  * 1. Redistributions of source code must retain the above copyright
9  * notice, this list of conditions and the following disclaimer.
10  * 2. Redistributions in binary form must reproduce the above copyright
11  * notice, this list of conditions and the following disclaimer in the
12  * documentation and/or other materials provided with the distribution.
13  * 3. Neither the name of the copyright holder nor the names of its
14  * contributors may be used to endorse or promote products derived
15  * from this software without specific prior written permission.
16  *
17  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
20  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
21  * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
22  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
24  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
26  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
28  * OF THE POSSIBILITY OF SUCH DAMAGE.
29  */
30 /*---------------------------------------------------------------------------*/
31 /**
32  * \addtogroup rf-core
33  * @{
34  *
35  * \defgroup rf-core-15-4g-modes IEEE 802.15.4g Frequency Bands and Modes
36  *
37  * @{
38  *
39  * \file
40  * Header file with descriptors for the various modes of operation defined in
41  * IEEE 802.15.4g
42  */
43 /*---------------------------------------------------------------------------*/
44 #ifndef DOT_15_4G_H_
45 #define DOT_15_4G_H_
46 /*---------------------------------------------------------------------------*/
47 #include "contiki-conf.h"
48 /*---------------------------------------------------------------------------*/
49 /* IEEE 802.15.4g frequency band identifiers (Table 68f) */
50 #define DOT_15_4G_FREQUENCY_BAND_169 0 /* 169.400–169.475 (Europe) - 169 MHz band */
51 #define DOT_15_4G_FREQUENCY_BAND_450 1 /* 450–470 (US FCC Part 22/90) - 450 MHz band */
52 #define DOT_15_4G_FREQUENCY_BAND_470 2 /* 470–510 (China) - 470 MHz band */
53 #define DOT_15_4G_FREQUENCY_BAND_780 3 /* 779–787 (China) - 780 MHz band */
54 #define DOT_15_4G_FREQUENCY_BAND_863 4 /* 863–870 (Europe) - 863 MHz band */
55 #define DOT_15_4G_FREQUENCY_BAND_896 5 /* 896–901 (US FCC Part 90) - 896 MHz band */
56 #define DOT_15_4G_FREQUENCY_BAND_901 6 /* 901–902 (US FCC Part 24) - 901 MHz band */
57 #define DOT_15_4G_FREQUENCY_BAND_915 7 /* 902–928 (US) - 915 MHz band */
58 #define DOT_15_4G_FREQUENCY_BAND_917 8 /* 917–923.5 (Korea) - 917 MHz band */
59 #define DOT_15_4G_FREQUENCY_BAND_920 9 /* 920–928 (Japan) - 920 MHz band */
60 #define DOT_15_4G_FREQUENCY_BAND_928 10 /* 928–960 (US, non-contiguous) - 928 MHz band */
61 #define DOT_15_4G_FREQUENCY_BAND_950 11 /* 950–958 (Japan) - 950 MHz band */
62 #define DOT_15_4G_FREQUENCY_BAND_1427 12 /* 1427–1518 (US and Canada, non-contiguous) - 1427 MHz band */
63 #define DOT_15_4G_FREQUENCY_BAND_2450 13 /* 2400–2483.5 2450 MHz band */
64 /*---------------------------------------------------------------------------*/
65 /* Default band selection to band 4 - 863MHz */
66 #ifdef DOT_15_4G_CONF_FREQUENCY_BAND_ID
67 #define DOT_15_4G_FREQUENCY_BAND_ID DOT_15_4G_CONF_FREQUENCY_BAND_ID
68 #else
69 #define DOT_15_4G_FREQUENCY_BAND_ID DOT_15_4G_FREQUENCY_BAND_863
70 #endif
71 /*---------------------------------------------------------------------------*/
72 /*
73  * Channel count, spacing and other params relating to the selected band. We
74  * currently only support some of the bands defined in .15.4g and for those
75  * bands we only support operating mode #1 (Table 134).
76  *
77  * DOT_15_4G_CHAN0_FREQUENCY is specified here in KHz
78  */
79 #if DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_470
80 #define DOT_15_4G_CHANNEL_MAX 198
81 #define DOT_15_4G_CHANNEL_SPACING 200
82 #define DOT_15_4G_CHAN0_FREQUENCY 470200
83 #define PROP_MODE_CONF_LO_DIVIDER 0x0A
84 
85 #elif DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_780
86 #define DOT_15_4G_CHANNEL_MAX 38
87 #define DOT_15_4G_CHANNEL_SPACING 200
88 #define DOT_15_4G_CHAN0_FREQUENCY 779200
89 #define PROP_MODE_CONF_LO_DIVIDER 0x06
90 
91 #elif DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_863
92 #define DOT_15_4G_CHANNEL_MAX 33
93 #define DOT_15_4G_CHANNEL_SPACING 200
94 #define DOT_15_4G_CHAN0_FREQUENCY 863125
95 #define PROP_MODE_CONF_LO_DIVIDER 0x05
96 
97 #elif DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_915
98 #define DOT_15_4G_CHANNEL_MAX 128
99 #define DOT_15_4G_CHANNEL_SPACING 200
100 #define DOT_15_4G_CHAN0_FREQUENCY 902200
101 #define PROP_MODE_CONF_LO_DIVIDER 0x05
102 
103 #elif DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_920
104 #define DOT_15_4G_CHANNEL_MAX 37
105 #define DOT_15_4G_CHANNEL_SPACING 200
106 #define DOT_15_4G_CHAN0_FREQUENCY 920600
107 #define PROP_MODE_CONF_LO_DIVIDER 0x05
108 
109 #elif DOT_15_4G_FREQUENCY_BAND_ID==DOT_15_4G_FREQUENCY_BAND_950
110 #define DOT_15_4G_CHANNEL_MAX 32
111 #define DOT_15_4G_CHANNEL_SPACING 200
112 #define DOT_15_4G_CHAN0_FREQUENCY 951000
113 #define PROP_MODE_CONF_LO_DIVIDER 0x05
114 
115 #else
116 #error The selected frequency band is not supported
117 #endif
118 /*---------------------------------------------------------------------------*/
119 #endif /* DOT_15_4G_H_ */
120 /*---------------------------------------------------------------------------*/
121 /**
122  * @}
123  * @}
124  */