OpenBIC
OpenSource Bridge-IC
plat_fan.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MAX_FAN_DUTY_VALUE   100
 
#define DEFAULT_FAN_DUTY_VALUE   70
 
#define MAX_FAN_PWM_INDEX_COUNT   4
 
#define INDEX_ALL_PWM   0xFF
 
#define PWM_DEVICE_NAME   "PWM"
 

Enumerations

enum  fan_mode_ctrl_cmd { FAN_SET_MANUAL_MODE = 0x00 , FAN_SET_AUTO_MODE = 0x01 , FAN_GET_MODE = 0x02 }
 
enum  fan_mode { FAN_MANUAL_MODE = 0x00 , FAN_AUTO_MODE = 0x01 }
 

Functions

void init_fan_mode ()
 
void init_fan_duty ()
 
int pal_get_fan_ctrl_mode (uint8_t *ctrl_mode)
 
void pal_set_fan_ctrl_mode (uint8_t ctrl_mode)
 
int pal_get_fan_rpm (uint8_t fan_id, uint16_t *rpm)
 
int pal_get_fan_duty (uint8_t pwm_id, uint8_t *duty, uint8_t slot_index)
 
int pal_set_fan_duty (uint8_t pwm_id, uint8_t duty, uint8_t slot_index)
 

Macro Definition Documentation

◆ DEFAULT_FAN_DUTY_VALUE

#define DEFAULT_FAN_DUTY_VALUE   70

◆ INDEX_ALL_PWM

#define INDEX_ALL_PWM   0xFF

◆ MAX_FAN_DUTY_VALUE

#define MAX_FAN_DUTY_VALUE   100

◆ MAX_FAN_PWM_INDEX_COUNT

#define MAX_FAN_PWM_INDEX_COUNT   4

◆ PWM_DEVICE_NAME

#define PWM_DEVICE_NAME   "PWM"

Enumeration Type Documentation

◆ fan_mode

enum fan_mode
Enumerator
FAN_MANUAL_MODE 
FAN_AUTO_MODE 

◆ fan_mode_ctrl_cmd

Enumerator
FAN_SET_MANUAL_MODE 
FAN_SET_AUTO_MODE 
FAN_GET_MODE 

Function Documentation

◆ init_fan_duty()

void init_fan_duty ( )

◆ init_fan_mode()

void init_fan_mode ( )

◆ pal_get_fan_ctrl_mode()

int pal_get_fan_ctrl_mode ( uint8_t *  ctrl_mode)

◆ pal_get_fan_duty()

int pal_get_fan_duty ( uint8_t  pwm_id,
uint8_t *  duty,
uint8_t  slot_index 
)

◆ pal_get_fan_rpm()

int pal_get_fan_rpm ( uint8_t  fan_id,
uint16_t *  rpm 
)

◆ pal_set_fan_ctrl_mode()

void pal_set_fan_ctrl_mode ( uint8_t  ctrl_mode)

◆ pal_set_fan_duty()

int pal_set_fan_duty ( uint8_t  pwm_id,
uint8_t  duty,
uint8_t  slot_index 
)