Refactor folder structure.
[sim/o1-interface.git] / ntsimulator / yang / x-ran / xran-externalio.yang
1 module xran-externalio {
2   yang-version 1.1;
3   namespace "urn:xran:external-io:1.0";
4   prefix "xran-io";
5
6   organization "xRAN Forum";
7
8   contact
9     "www.xran.org";
10
11   description
12     "This module defines the input state and output configuration for
13     the xRAN Radio Unit external IO.
14
15     Copyright 2018 the xRAN Forum.
16
17     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
18     AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19     IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20     ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
21     LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
22     CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
23     SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24     INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
25     CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26     ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
27     POSSIBILITY OF SUCH DAMAGE.
28
29     Redistribution and use in source and binary forms, with or without
30     modification, are permitted provided that the following conditions are met:
31
32     * Redistributions of source code must retain the above copyright notice,
33     this list of conditions and the above disclaimer.
34     * Redistributions in binary form must reproduce the above copyright notice,
35     this list of conditions and the above disclaimer in the documentation
36     and/or other materials provided with the distribution.
37     * Neither the Members of the xRAN Forum nor the names of its
38     contributors may be used to endorse or promote products derived from
39     this software without specific prior written permission.";
40
41   revision "2018-07-20" {
42     description
43       "version 1.0.0 - First release of the xRAN YANG M-Plane models.
44
45       This version of the model supports v01.00 of the corrsponding xRAN
46       M-Plane Specification.";
47     reference "XRAN-FH.MP.0-v01.00";
48   }
49
50   container external-io {
51     description
52       "External IO information.";
53     list input {
54       key "name";
55       config false;
56       description
57         "Leaf nodes describing external line inputs";
58       leaf name {
59         type string {
60           length "1..255";
61         }
62         description
63         "A name that is unique across the RU that identifies an input port instance.
64         This name may be used in fault management to refer to a fault source
65         or affected object";
66       }
67       leaf port-in {
68         type uint8;
69         description
70           "A number which identifies an external input port.";
71       }
72
73       leaf line-in {
74         type boolean;
75         default true;
76         description
77           "Value TRUE indicates that circuit is open.
78            Value FALSE indicates that circuit is closed.
79
80            Usually when nothing is connected to the line the value is TRUE.
81            The details of external line-in implementation are HW specific.";
82       }
83     }
84
85     list output {
86       key "name";
87       description
88         "Leaf nodes describing external line outputs";
89       leaf name {
90         type string {
91           length "1..255";
92         }
93         description
94           "A name that is unique across the RU that identifies an output port instance.
95           This name may be used in fault management to refer to a fault source
96           or affected object";
97       }
98       leaf port-out {
99         type uint8;
100         mandatory true;
101         description
102           "A number which identifies an external output port.";
103       }
104
105       leaf line-out {
106         type boolean;
107         default true;
108         description
109           "Value TRUE indicates that circuit is in its natural state.
110            Value FALSE indicates that circuit is not in its natural state.";
111       }
112     }
113   }
114
115   notification external-input-change {
116     description
117       "Notification used to indicate that external line input has changed state";
118     container current-input-notification {
119       description "a container for the state of the input ports";
120       list external-input {
121         key "name";
122         description "a list of the input ports and their state";
123         leaf name{
124           type leafref{
125             path "/external-io/input/name";
126           }
127           description "the name of the ald-port";
128         }
129         leaf io-port {
130           type leafref{
131             path  "/external-io/input/port-in";
132           }
133           description "the external input port";
134         }
135         leaf line-in {
136           type leafref{
137             path  "/external-io/input/line-in";
138           }
139           description "the state of the external input port";
140         }
141       }
142     }
143   }
144 }