Skip to content

Commit

Permalink
update:补充注释
Browse files Browse the repository at this point in the history
  • Loading branch information
allewalker committed Oct 27, 2023
1 parent 23e6035 commit d89af5c
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions luat/include/luat_mcu.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,23 @@ uint64_t luat_mcu_tick64(void);
int luat_mcu_us_period(void);
uint64_t luat_mcu_tick64_ms(void);
void luat_mcu_set_clk_source(uint8_t source_main, uint8_t source_32k, uint32_t delay);

/**
* @brief 用户是否设置了外设的IOMUX
* @param type 外设类型 LUAT_MCU_PERIPHERAL_XXX
* @param sn 外设序号,0~7
* @return 0 用户没有配置 1用户配置了
*/
uint8_t luat_mcu_iomux_is_default(uint8_t type, uint8_t sn);
/**
* @brief 用户控制外设的IOMUX,如果不配置或者取消,则外设初始化时使用默认配置
* @param type 外设类型 LUAT_MCU_PERIPHERAL_XXX
* @param sn 外设序号,0~7
* @param pad_index pad序号,具体看芯片,可能是GPIO序号,可能是PAD序号。如果是-1,则表示取消配置
* @param alt 复用功能序号,具体看芯片
* @param is_input,是否是单纯输入功能
* @return 无
*/
void luat_mcu_iomux_ctrl(uint8_t type, uint8_t sn, int pad_index, uint8_t alt, uint8_t is_input);

void luat_mcu_set_hardfault_mode(int mode);
Expand Down

0 comments on commit d89af5c

Please sign in to comment.