Skip to content

Commit

Permalink
Merge pull request #427 from ut-issl/feature/change_record_el_at_eh_r…
Browse files Browse the repository at this point in the history
…espond

EH 対応時の BC 展開時の EL がうるさいことを直す(時間調整時は LOW にした)
  • Loading branch information
meltingrabbit authored Sep 19, 2022
2 parents eebf067 + cfd49fa commit 937a4c8
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 7 deletions.
4 changes: 2 additions & 2 deletions Applications/timeline_command_dispatcher.c
Original file line number Diff line number Diff line change
Expand Up @@ -279,8 +279,8 @@ CCP_CmdRet Cmd_TLCD_DEPLOY_BLOCK(const CommonCmdPacket* packet)
EL_record_event((EL_GROUP)EL_CORE_GROUP_TLCD_DEPLOY_BLOCK,
(uint32_t)ack,
EL_ERROR_LEVEL_LOW,
(uint32_t)id);
return CCP_make_cmd_ret_without_err_code(CCP_EXEC_ILLEGAL_CONTEXT);
(uint32_t)( ((0x000000ff & id) << 24) | (0x00ffffff & block_no) ));
return CCP_make_cmd_ret(CCP_EXEC_ILLEGAL_CONTEXT, (uint32_t)ack);
}

return CCP_make_cmd_ret_without_err_code(CCP_EXEC_SUCCESS);
Expand Down
21 changes: 16 additions & 5 deletions System/EventManager/event_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ typedef enum
EH_EL_LOCAL_ID_EL_TOTAL_COUNTER_ERR = 0, //!< ELとEHのカウンタの不整合エラー (counter_total)
EH_EL_LOCAL_ID_EL_COUNTER_ERR, //!< ELとEHのカウンタの不整合エラー (counters)
EH_EL_LOCAL_ID_TOO_MANY_EVENT, //!< イベントが発生しすぎて,TLogが失われている
EH_EL_LOCAL_ID_FAIL_FORM_CTCP, //!< BC 展開 Cmd の生成に失敗
EH_EL_LOCAL_ID_FAIL_TO_RESPOND, //!< EH 対応時に BC 展開に失敗
EH_EL_LOCAL_ID_LOG_TABLE_FULL, //!< EH_LogTable が満杯になり, wp が 0 に戻った
EH_EL_LOCAL_ID_SEARCH_ERR, //!< EH_search_rule_table_index_ の返り値不正
EH_EL_LOCAL_ID_RECURSION_ERR, //!< 多段対応時に再帰呼び出し回数が設定値を超えた
Expand Down Expand Up @@ -653,10 +653,21 @@ static void EH_respond_(EH_RULE_ID rule_id)
cmd_ret = CCP_form_and_exec_block_deploy_cmd(TLCD_ID_DEPLOY_BC, rule->settings.deploy_bct_id);
if (cmd_ret.exec_sts != CCP_EXEC_SUCCESS)
{
EL_record_event((EL_GROUP)EL_CORE_GROUP_EVENT_HANDLER,
EH_EL_LOCAL_ID_FAIL_FORM_CTCP,
EL_ERROR_LEVEL_HIGH,
cmd_ret.exec_sts);
uint32_t note = ((0x0000ffff & cmd_ret.exec_sts) << 16) | (0x0000ffff & cmd_ret.err_code);
if ((PL_ACK)cmd_ret.err_code == PL_BC_TIME_ADJUSTED)
{
EL_record_event((EL_GROUP)EL_CORE_GROUP_EVENT_HANDLER,
EH_EL_LOCAL_ID_FAIL_TO_RESPOND,
EL_ERROR_LEVEL_LOW,
note);
}
else
{
EL_record_event((EL_GROUP)EL_CORE_GROUP_EVENT_HANDLER,
EH_EL_LOCAL_ID_FAIL_TO_RESPOND,
EL_ERROR_LEVEL_HIGH,
note);
}
}

EH_inactivate_rule_for_multi_level(rule_id);
Expand Down

0 comments on commit 937a4c8

Please sign in to comment.