Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
meltingrabbit committed Jan 24, 2022
1 parent a3d9927 commit 162f425
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
#include <src_core/TlmCmd/common_tlm_cmd_packet.h>


CTCP_PACKET_TYPE CTCP_get_tc_dsc(const CommonTlmCmdPacket* packet)
CTCP_PACKET_TYPE CTCP_get_packet_type(const CommonTlmCmdPacket* packet)
{
switch (CTCP_get_packet_type(packet))
switch (TCP_get_type(packet))
{
case TCP_TYPE_TLM:
return CTCP_PACKET_TYPE_TLM;
Expand Down
8 changes: 4 additions & 4 deletions TlmCmd/packet_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,12 @@ void PH_init(void)
// Cmd_GENERATE_TLMとかも.
PH_ACK PH_analyze_packet(const CTCP* packet)
{
switch (CTCP_get_tc_dsc(packet))
switch (CTCP_get_packet_type(packet))
{
case CTCP_TC_DSC_CMD:
case CTCP_PACKET_TYPE_CMD:
return PH_analyze_cmd_(packet);

case CTCP_TC_DSC_TLM:
case CTCP_PACKET_TYPE_TLM:
return PH_analyze_tlm_(packet);

default:
Expand Down Expand Up @@ -166,7 +166,7 @@ static PH_ACK PH_analyze_tlm_(const CTCP* packet)

CCP_EXEC_STS PH_dispatch_command(const CTCP* packet)
{
if (CTCP_get_tc_dsc(packet) != CTCP_PACKET_TYPE_CMD)
if (CTCP_get_packet_type(packet) != CTCP_PACKET_TYPE_CMD)
{
// CMD以外のパケットが来たら異常判定。
return CCP_EXEC_PACKET_FMT_ERR;
Expand Down

0 comments on commit 162f425

Please sign in to comment.