CI13LC SDK API手册  2.1.1
本手册用于描述CI13LC SDK各个组件和驱动API
函数
ci13lc_pvdc.c 文件参考

看门狗驱动文件 更多...

#include "ci_pvdc.h"

函数

void pvdc_reg_unlock ()
 寄存器解锁 更多...
 
void pvdc_reg_lock ()
 寄存器上锁 更多...
 
uint8_t pvdc_raw_irq_status (pvdc_intr_t intr)
 读pvdc原始中断状态 更多...
 
uint8_t pvdc_mask_irq_status (pvdc_intr_t intr)
 读屏蔽中断状态 更多...
 
void pvdc_clear_irq (pvdc_intr_t intr)
 清除中断状态 更多...
 
void pvdc_irq_mask (pvdc_intr_t intr, FunctionalState en)
 配置中断屏蔽 更多...
 
pvdc_result_t pvdc_get_irq_pvd_result ()
 读第1次中断电压比较结果 更多...
 
pvdc_vol_t pvdc_get_irq_vol ()
 读第1次中断电压值 更多...
 
void pvdc_enable (FunctionalState en)
 pvdc使能 更多...
 
void pvdc_set_vol_high_threshold (pvdc_vol_t threshold)
 设置高阈值电压 更多...
 
void pvdc_set_vol_low_threshold (pvdc_vol_t threshold)
 设置低阈值电压 更多...
 
pvdc_result_t pvdc_get_current_pvd_result ()
 读扫描实时电压比较结果 更多...
 
pvdc_vol_t pvdc_get_current_vol ()
 读扫描实时电压值 更多...
 
void pvdc_scan_interval_time (uint16_t time)
 配置扫描间隔时间 以8K为时间单位,扫描间隔 = 125 us * (time + 1) 更多...
 
void pvdc_max_wait_times (uint16_t times)
 当模拟电压值一直在Vth和Vtl之间跳变时,最大等待次数 更多...
 
void PVDC_IRQHandler ()
 

详细描述

看门狗驱动文件

版本
0.1
日期
2024-04-019

函数说明

◆ pvdc_clear_irq()

void pvdc_clear_irq ( pvdc_intr_t  intr)

清除中断状态

参数
intr,中断选择

◆ pvdc_enable()

void pvdc_enable ( FunctionalState  en)

pvdc使能

参数
en:ENABLE,打开;DISABLE,关闭

◆ pvdc_get_current_pvd_result()

pvdc_result_t pvdc_get_current_pvd_result ( )

读扫描实时电压比较结果

返回
0 ~ 1

◆ pvdc_get_current_vol()

pvdc_vol_t pvdc_get_current_vol ( )

读扫描实时电压值

返回
0 ~ 7(2.4V ~ 3.1V,step is 100mV)

◆ pvdc_get_irq_pvd_result()

pvdc_result_t pvdc_get_irq_pvd_result ( )

读第1次中断电压比较结果

返回
0 ~ 1

◆ pvdc_get_irq_vol()

pvdc_vol_t pvdc_get_irq_vol ( )

读第1次中断电压值

返回
0 ~ 7(2.4V ~ 3.1V,step is 100mV)

◆ pvdc_irq_mask()

void pvdc_irq_mask ( pvdc_intr_t  intr,
FunctionalState  en 
)

配置中断屏蔽

参数
en:ENABLE,屏蔽;DISABLE,不屏蔽

◆ PVDC_IRQHandler()

void PVDC_IRQHandler ( void  )

◆ pvdc_mask_irq_status()

uint8_t pvdc_mask_irq_status ( pvdc_intr_t  intr)

读屏蔽中断状态

参数
intr,中断选择

◆ pvdc_max_wait_times()

void pvdc_max_wait_times ( uint16_t  times)

当模拟电压值一直在Vth和Vtl之间跳变时,最大等待次数

参数
times:0~ 15

◆ pvdc_raw_irq_status()

uint8_t pvdc_raw_irq_status ( pvdc_intr_t  intr)

读pvdc原始中断状态

参数
intr,中断选择

◆ pvdc_reg_lock()

void pvdc_reg_lock ( )

寄存器上锁

◆ pvdc_reg_unlock()

void pvdc_reg_unlock ( )

寄存器解锁

◆ pvdc_scan_interval_time()

void pvdc_scan_interval_time ( uint16_t  time)

配置扫描间隔时间 以8K为时间单位,扫描间隔 = 125 us * (time + 1)

参数
time:0~ 4095

◆ pvdc_set_vol_high_threshold()

void pvdc_set_vol_high_threshold ( pvdc_vol_t  threshold)

设置高阈值电压

参数
threshold:0~ 7(2.4V ~ 3.1V,step is 100mV)

◆ pvdc_set_vol_low_threshold()

void pvdc_set_vol_low_threshold ( pvdc_vol_t  threshold)

设置低阈值电压

参数
threshold:0~ 7(2.4V ~ 3.1V,step is 100mV)