OpenBIC
OpenSource Bridge-IC
plat_log.h File Reference
#include "plat_modbus.h"
Include dependency graph for plat_log.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _modbus_err_log_mapping
 
struct  _err_sensor_mapping
 

Macros

#define IS_NORMAL_VAL   true
 
#define IS_ABNORMAL_VAL   false
 

Typedefs

typedef struct _modbus_err_log_mapping modbus_err_log_mapping
 
typedef struct _err_sensor_mapping err_sensor_mapping
 

Enumerations

enum  LOG_ERROR_CODE {
  LEAK_CHASSIS_0 = 0x0A , LEAK_CHASSIS_1 = 0x0B , LEAK_CHASSIS_2 = 0x0C , LEAK_CHASSIS_3 = 0x0D ,
  LEAK_RPU_INT = 0x0E , LEAK_RPU_EXT = 0x0F , LEAK_MAN_HOT = 0x10 , LEAK_MAN_COLD = 0x11 ,
  LEAK_MAN_PAN_GPO = 0x6E , LEAK_MAN_FLOOR_GPO = 0x6F , LEAK_MAN_PAN_RELAY = 0x70 , LEAK_MAN_FLOOR_RELAY = 0x71 ,
  LOW_WATER_LEVEL = 0x02 , PUMP_1_SPEED_ABNORMAL = 0x1F , PUMP_2_SPEED_ABNORMAL = 0x20 , PUMP_3_SPEED_ABNORMAL = 0x21 ,
  PUMP_1_SPEED_RECOVER = 0x29 , PUMP_2_SPEED_RECOVER = 0x2A , PUMP_3_SPEED_RECOVER = 0x2B , HIGH_PRESS_DETECTED = 0xA0 ,
  FLOW_RATE_SENSOR_TRIGGERED = 0xA1 , EMERGENCY_BUTTON_TRIGGERED = 0xA2 , LOG_ERR_HEX_EXTERNAL_Y_FILTER = 0xA3 , LOG_ERR_BPB_RPU_COOLANT_INLET_P_KPA = 0xA4 ,
  LOG_ERR_BPB_RACK_PRESSURE_3_P_KPA = 0xA5 , LOG_ERR_BPB_RACK_PRESSURE_4_P_KPA = 0xA6 , LOG_ERR_SB_HEX_PRESSURE_1_P_KPA = 0xA7 , LOG_ERR_SB_HEX_PRESSURE_2_P_KPA = 0xA8 ,
  LOG_ERR_BPB_RPU_COOLANT_INLET_TEMP_C = 0xA9 , LOG_ERR_BPB_RPU_COOLANT_OUTLET_TEMP_C = 0xAA , LOG_ERR_BPB_HEX_WATER_INLET_TEMP_C = 0xAB , LOG_ERR_SB_HEX_AIR_INLET_AVG_TEMP_C = 0xAC ,
  LOG_ERR_FB_1_FAN_TACH_RPM = 0xAD , LOG_ERR_FB_2_FAN_TACH_RPM = 0xAE , LOG_ERR_FB_3_FAN_TACH_RPM = 0xAF , LOG_ERR_FB_4_FAN_TACH_RPM = 0xB0 ,
  LOG_ERR_FB_5_FAN_TACH_RPM = 0xB1 , LOG_ERR_FB_6_FAN_TACH_RPM = 0xB2 , LOG_ERR_FB_7_FAN_TACH_RPM = 0xB3 , LOG_ERR_FB_8_FAN_TACH_RPM = 0xB4 ,
  LOG_ERR_FB_9_FAN_TACH_RPM = 0xB5 , LOG_ERR_FB_10_FAN_TACH_RPM = 0xB6 , LOG_ERR_FB_11_FAN_TACH_RPM = 0xB7 , LOG_ERR_FB_12_FAN_TACH_RPM = 0xB8 ,
  LOG_ERR_FB_13_FAN_TACH_RPM = 0xB9 , LOG_ERR_FB_14_FAN_TACH_RPM = 0xBA , LEAK_CHASSIS_0 = 0x0A , LEAK_CHASSIS_1 = 0x0B ,
  LEAK_CHASSIS_2 = 0x0C , LEAK_CHASSIS_3 = 0x0D , LEAK_RPU_INT = 0x0E , LEAK_RPU_EXT = 0x0F ,
  LEAK_MAN_HOT = 0x10 , LEAK_MAN_COLD = 0x11 , LEAK_MAN_PAN_GPO = 0x6E , LEAK_MAN_FLOOR_GPO = 0x6F ,
  LEAK_MAN_PAN_RELAY = 0x70 , LEAK_MAN_FLOOR_RELAY = 0x71 , LOW_WATER_LEVEL = 0x02 , PUMP_1_SPEED_ABNORMAL = 0x1F ,
  PUMP_2_SPEED_ABNORMAL = 0x20 , PUMP_3_SPEED_ABNORMAL = 0x21 , PUMP_1_SPEED_RECOVER = 0x29 , PUMP_2_SPEED_RECOVER = 0x2A ,
  PUMP_3_SPEED_RECOVER = 0x2B , HIGH_PRESS_DETECTED = 0xA0 , FLOW_RATE_SENSOR_TRIGGERED = 0xA1 , EMERGENCY_BUTTON_TRIGGERED = 0xA2
}
 

Functions

uint16_t error_log_count (void)
 
void log_transfer_to_modbus_data (uint16_t *modbus_data, uint8_t cmd_size, uint16_t order)
 
void error_log_event (uint8_t sensor_num, bool val_normal)
 
void init_load_eeprom_log (void)
 
void modbus_clear_log ()
 

Macro Definition Documentation

◆ IS_ABNORMAL_VAL

#define IS_ABNORMAL_VAL   false

◆ IS_NORMAL_VAL

#define IS_NORMAL_VAL   true

Typedef Documentation

◆ err_sensor_mapping

◆ modbus_err_log_mapping

Enumeration Type Documentation

◆ LOG_ERROR_CODE

Enumerator
LEAK_CHASSIS_0 
LEAK_CHASSIS_1 
LEAK_CHASSIS_2 
LEAK_CHASSIS_3 
LEAK_RPU_INT 
LEAK_RPU_EXT 
LEAK_MAN_HOT 
LEAK_MAN_COLD 
LEAK_MAN_PAN_GPO 
LEAK_MAN_FLOOR_GPO 
LEAK_MAN_PAN_RELAY 
LEAK_MAN_FLOOR_RELAY 
LOW_WATER_LEVEL 
PUMP_1_SPEED_ABNORMAL 
PUMP_2_SPEED_ABNORMAL 
PUMP_3_SPEED_ABNORMAL 
PUMP_1_SPEED_RECOVER 
PUMP_2_SPEED_RECOVER 
PUMP_3_SPEED_RECOVER 
HIGH_PRESS_DETECTED 
FLOW_RATE_SENSOR_TRIGGERED 
EMERGENCY_BUTTON_TRIGGERED 
LOG_ERR_HEX_EXTERNAL_Y_FILTER 
LOG_ERR_BPB_RPU_COOLANT_INLET_P_KPA 
LOG_ERR_BPB_RACK_PRESSURE_3_P_KPA 
LOG_ERR_BPB_RACK_PRESSURE_4_P_KPA 
LOG_ERR_SB_HEX_PRESSURE_1_P_KPA 
LOG_ERR_SB_HEX_PRESSURE_2_P_KPA 
LOG_ERR_BPB_RPU_COOLANT_INLET_TEMP_C 
LOG_ERR_BPB_RPU_COOLANT_OUTLET_TEMP_C 
LOG_ERR_BPB_HEX_WATER_INLET_TEMP_C 
LOG_ERR_SB_HEX_AIR_INLET_AVG_TEMP_C 
LOG_ERR_FB_1_FAN_TACH_RPM 
LOG_ERR_FB_2_FAN_TACH_RPM 
LOG_ERR_FB_3_FAN_TACH_RPM 
LOG_ERR_FB_4_FAN_TACH_RPM 
LOG_ERR_FB_5_FAN_TACH_RPM 
LOG_ERR_FB_6_FAN_TACH_RPM 
LOG_ERR_FB_7_FAN_TACH_RPM 
LOG_ERR_FB_8_FAN_TACH_RPM 
LOG_ERR_FB_9_FAN_TACH_RPM 
LOG_ERR_FB_10_FAN_TACH_RPM 
LOG_ERR_FB_11_FAN_TACH_RPM 
LOG_ERR_FB_12_FAN_TACH_RPM 
LOG_ERR_FB_13_FAN_TACH_RPM 
LOG_ERR_FB_14_FAN_TACH_RPM 
LEAK_CHASSIS_0 
LEAK_CHASSIS_1 
LEAK_CHASSIS_2 
LEAK_CHASSIS_3 
LEAK_RPU_INT 
LEAK_RPU_EXT 
LEAK_MAN_HOT 
LEAK_MAN_COLD 
LEAK_MAN_PAN_GPO 
LEAK_MAN_FLOOR_GPO 
LEAK_MAN_PAN_RELAY 
LEAK_MAN_FLOOR_RELAY 
LOW_WATER_LEVEL 
PUMP_1_SPEED_ABNORMAL 
PUMP_2_SPEED_ABNORMAL 
PUMP_3_SPEED_ABNORMAL 
PUMP_1_SPEED_RECOVER 
PUMP_2_SPEED_RECOVER 
PUMP_3_SPEED_RECOVER 
HIGH_PRESS_DETECTED 
FLOW_RATE_SENSOR_TRIGGERED 
EMERGENCY_BUTTON_TRIGGERED 

Function Documentation

◆ error_log_count()

uint16_t error_log_count ( void  )

◆ error_log_event()

void error_log_event ( uint8_t  sensor_num,
bool  val_normal 
)

◆ init_load_eeprom_log()

void init_load_eeprom_log ( void  )

◆ log_transfer_to_modbus_data()

void log_transfer_to_modbus_data ( uint16_t *  modbus_data,
uint8_t  cmd_size,
uint16_t  order 
)

◆ modbus_clear_log()

void modbus_clear_log ( )