lcc_api.c
来自「是一个手机功能的模拟程序」· C语言 代码 · 共 45 行
C
45 行
/******************************************************************************
* Power Task (pwr)
* Design and coding by Svend Kristian Lindholm, skl@ti.com
*
* PWR MMI Interface
*
* $Id: lcc_api.c,v 1.1.1.1 2004/06/19 06:00:29 root Exp $
*
******************************************************************************/
#include "lcc.h"
#include "lcc_env.h"
#include "lcc_trace.h"
/******************************************************************************
* Function prototypes
******************************************************************************/
T_RVM_RETURN pwr_start_timer(UINT32 *timer_begin);
// Inform the PWR process which callback function to send MMI events
// and perform initialization of mmi related variables
void pwr_register (T_RV_RETURN_PATH *return_path, void *ptr)
{
ttw(ttr(TTrInit,"pwr_register (%d)" NL, 0x00));
// Assign return path (callback or task address id)
pwr_ctrl->rpath.callback_func = return_path->callback_func;
pwr_ctrl->rpath.addr_id = return_path->addr_id;
// Pointer to mmi event memory allocated (& deallocated) by the MMI
pwr_ctrl->mmi_ptr = (struct mmi_info_ind_s *) ptr;
// Yes - the mmi has registered!
pwr_ctrl->flag_mmi_registered = 1;
// Start the mmi repetition timer
pwr_start_timer(&pwr_ctrl->time_begin_mmi_rep);
ttw(ttr(TTrTimerLow,"mmi repetition timer started(%d)" NL, 0));
ttw(ttr(TTrInit,"pwr_register (%d)" NL, 0xFF));
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?