Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.9.0.2
openapi_boxs.h
Go to the documentation of this file.
1 
9 /**********************************************************************
10 *
11 * Copyright 2016-2019 Broadcom.
12 *
13 * Licensed under the Apache License, Version 2.0 (the "License");
14 * you may not use this file except in compliance with the License.
15 * You may obtain a copy of the License at
16 *
17 * http://www.apache.org/licenses/LICENSE-2.0
18 *
19 * Unless required by applicable law or agreed to in writing, software
20 * distributed under the License is distributed on an "AS IS" BASIS,
21 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22 * See the License for the specific language governing permissions and
23 * limitations under the License.
24 *
25 **********************************************************************
26 *
27 * @filename openapi_boxs.h
28 *
29 * @purpose Box Services Configuration and Status
30 *
31 * @component OPEN
32 *
33 * @create 11/09/2012
34 *
35 * @end
36 *
37 **********************************************************************/
38 #ifndef OPENAPI_BOXS_H_INCLUDED
39 #define OPENAPI_BOXS_H_INCLUDED
40 
41 #include "openapi_common.h"
42 
44 typedef enum
45 {
46  OPEN_ITEMSTATE_NONE = 0, /* N/A */
47  OPEN_ITEMSTATE_NOT_PRESENT = 1,
48  OPEN_ITEMSTATE_OPERATIONAL = 2,
49  OPEN_ITEMSTATE_FAILED = 3,
50  OPEN_ITEMSTATE_POWERING = 4,
51  OPEN_ITEMSTATE_NOPOWER = 5,
52  OPEN_ITEMSTATE_NOT_POWERING = 6,
53  OPEN_ITEMSTATE_INCOMPATIBLE = 7, /* This state is possible on boards capable of pluggable Power supplies */
54  OPEN_ITEMSTATE_WARNING = 8,
55  OPEN_ITEMSTATE_PRESENT = 9 /* Added for detecting Xcvr inserted state */
57 
59 typedef enum
60 {
61  OPEN_TEMPSENSOR_STATE_NONE = 0, /* N/A */
62  OPEN_TEMPSENSOR_STATE_LOW = 1,
63  OPEN_TEMPSENSOR_STATE_NORMAL = 2,
64  OPEN_TEMPSENSOR_STATE_WARNING = 3,
65  OPEN_TEMPSENSOR_STATE_CRITICAL = 4,
66  OPEN_TEMPSENSOR_STATE_SHUTDOWN = 5,
67  OPEN_TEMPSENSOR_STATE_NOTPRESENT = 6,
68  OPEN_TEMPSENSOR_STATE_NOTOPERATIONAL = 7
70 
72 typedef enum
73 {
74  OPEN_TYPE_NONE = 0, /* N/A */
75  OPEN_TYPE_FIXED = 1,
76  OPEN_TYPE_REMOVABLE = 2
78 
79 typedef enum
80 {
93 
94 typedef enum
95 {
96  OPEN_LED_CMD_OFF = 0,
97  OPEN_LED_CMD_ON = 1
98 }OPEN_LED_CMD_t;
99 
100 typedef enum
101 {
102  OPEN_LED_STATUS_OFF = 0,
103  OPEN_LED_STATUS_ON = 1
104 }OPEN_LED_STATUS_t;
105 
106 #define OPEN_BXS_STR_BUFFER_SIZE 128
108 /******************************************************************************/
131 open_error_t openapiFiberPortsOpticsFaultStatusGet(openapiClientHandle_t *client_handle, uint32_t ifNum,
132  uint32_t *localFaultStatus, uint32_t *remoteFaultStatus);
133 
134 /******************************************************************************/
161 open_error_t openapiFiberPortsOpticsGet(openapiClientHandle_t *client_handle, uint32_t ifNum,
162  uint32_t *temperature, uint32_t *voltage, uint32_t *current,
163  uint64_t *powerIn, uint64_t *powerOut,
164  OPEN_BOOL_t *txFault, OPEN_BOOL_t *los);
165 
166 /******************************************************************************/
198 open_error_t openapiFiberPortsLaneOpticsGet(openapiClientHandle_t *client_handle, uint32_t ifNum, uint32_t lane,
199  uint32_t *temperature, uint32_t *voltage, uint32_t *current,
200  open_buffdesc *powerIn, open_buffdesc *powerOut,
201  OPEN_BOOL_t *txFault, OPEN_BOOL_t *los);
202 
203 /*****************************************************************/
224  uint32_t ifNum, OPEN_BOOL_t *present);
225 
226 /*****************************************************************/
241  uint32_t * genFanSpeed);
242 
243 /*****************************************************************/
258  uint32_t * genFanDutyLevel);
259 
260 /******************************************************************************/
275  uint32_t * numFans);
276 
277 /*****************************************************************/
293  uint32_t fanNum, uint32_t * fanSpeed);
294 
295 
296 /*****************************************************************/
312  uint32_t fanNum,
313  OPEN_BOXS_ITEM_STATE_t * fanState);
314 
315 /*****************************************************************/
331  uint32_t fanNum,
332  OPEN_BOXS_ITEM_TYPE_t * fanType);
333 
334 /*****************************************************************/
350  uint32_t fanNum, uint32_t * fanDuty);
351 
352 /*****************************************************************************************/
366  client_handle,
367  uint32_t * descripSize);
368 
369 /*****************************************************************************************/
387  client_handle,
388  uint32_t fanNum,
389  open_buffdesc * descrip);
390 
391 /*****************************************************************/
406  client_handle,
407  uint32_t * numPowSuplies);
408 
409 /*****************************************************************/
425  client_handle, uint32_t psNo,
426  OPEN_BOXS_ITEM_STATE_t * psState);
427 
428 /*****************************************************************/
444  client_handle, uint32_t psNo,
445  OPEN_BOXS_ITEM_TYPE_t * psType);
446 
447 /*****************************************************************************************/
461  client_handle,
462  uint32_t * descripSize);
463 
464 /*****************************************************************************************/
482  client_handle,
483  uint32_t psNum,
484  open_buffdesc * descrip);
485 
486 /*****************************************************************/
502  client_handle,
503  uint32_t * minTemp,
504  uint32_t * maxTemp);
505 
506 /************************************************************************************/
521  client_handle,
522  uint32_t * genTemp);
523 
524 /*****************************************************************/
539  client_handle,
540  uint32_t * numOfTempSemsors);
541 
542 /*****************************************************************************************/
557  client_handle,
558  uint32_t * descripSize);
559 
560 /*****************************************************************************************/
578  client_handle,
579  uint32_t sensorNum,
580  open_buffdesc * descrip);
581 
582 /************************************************************************************/
596  uint32_t sensorNum, uint32_t * temperature);
597 
598 /*****************************************************************/
613  client_handle, uint32_t sensorNum,
615  state);
616 
617 /*******************************************************************************/
633  client_handle,
634  uint32_t sensorNum,
635  uint32_t * maxTemperature);
636 
637 /*****************************************************************/
652  uint32_t ifNum, OPEN_SFP_MODULE_TYPE_t *moduleType);
653 
654 /*****************************************************************/
673  uint32_t ifNum, open_buffdesc *vendorNameDesc);
674 
675 /*****************************************************************/
694  uint32_t ifNum, open_buffdesc *serialNumberDesc);
695 
696 /*****************************************************************/
715  uint32_t ifNum, open_buffdesc *partNumberDesc);
716 
717 
718 /*****************************************************************/
736  uint32_t ifNum, open_buffdesc *vendorRevDesc);
737 
738 /*****************************************************************/
754  uint32_t ifNum, uint32_t *linkLength50um);
755 
756 /*****************************************************************/
772  uint32_t ifNum, uint32_t *linkLength62_5um);
773 
774 /*****************************************************************/
791  uint32_t ifNum, uint32_t *nominalSigRate);
792 
793 /*****************************************************************/
812  uint32_t ifNum, open_buffdesc *complianceDesc);
813 
814 /*****************************************************************/
827  uint32_t *vendorNameSize);
828 
829 /*****************************************************************/
842  uint32_t *serialNumberSize);
843 
844 /*****************************************************************/
857  uint32_t *partNumberSize);
858 
859 /*****************************************************************/
872  uint32_t *vendorRevSize);
873 
874 /*****************************************************************/
887  uint32_t *complianceSize);
888 
889 /*****************************************************************/
902 
903 /*****************************************************************/
918  uint32_t interface,
919  OPEN_CONTROL_t enable);
920 
921 /*****************************************************************/
939  open_buffdesc *cpldVersion);
940 
941 /******************************************************************************/
955  uint32_t *version);
956 
957 /*****************************************************************/
974  OPEN_LED_CMD_t val);
975 
976 /*****************************************************************/
992  OPEN_LED_STATUS_t *val);
993 
994 /*****************************************************************/
1011  OPEN_LED_CMD_t val);
1012 
1013 /*****************************************************************/
1029  OPEN_LED_STATUS_t *val);
1030 #endif /* OPENAPI_BOXS_H_INCLUDED */
1031