update print

This commit is contained in:
Gatsby Van
2024-01-29 18:51:31 +08:00
parent 1555c7493c
commit 3f10a1cbe4
2 changed files with 6 additions and 6 deletions
@@ -134,7 +134,7 @@ static int32_t Service_Packing(L2_INST *instPtr, L2_FRAME_TYPE type, uint8_t dst
}
default:
{
DBG_ERROR("Unexpected frame type: %d.\n", type);
DBG_ERROR("Unexpected frame type: %" PRIu8 ".\n", type);
return EPARAM;
break;
}
@@ -279,7 +279,7 @@ int32_t L2_Service_PktHandler(L2_INST *instPtr, uint8_t *msg)
break;
}
default:
DBG_ERROR("Unsupported frame type: %d.\n", instPtr->frame.last);
DBG_ERROR("Unsupported frame type: %" PRIu8 ".\n", frameType);
break;
}
return Status;
@@ -357,7 +357,7 @@ int32_t L2_Service_Routine(L2_INST *instPtr, const L2_RTNE_TABLE_ENTRY *rtneEntr
L2_SetupNextSlot(instPtr, torState, L2_SVC_FRAME);
break;
default:
DBG_ERROR("UNKNOWN slot type [%d].\n", rtneEntry->slotType);
DBG_ERROR("UNKNOWN slot type [%" PRIu8 "].\n", rtneEntry->slotType);
return FAILURE;
}
#ifdef DATALINK_ENABLE_BERTEST
+3 -3
View File
@@ -218,13 +218,13 @@ void TimeCtrl_TimeAdjust(TMC_INST *instPtr, const TIME_WORD *tmWord, TIMECTRL_AD
ASSERT(tmWord != NULL);
if (type < TM_ADJ_ADD || TM_ADJ_ADD > TM_ADJ_SET)
{
DBG_ERROR("Unsupported adjustment type: %d", type);
DBG_ERROR("Unsupported adjustment type: %" PRId8 ".\n", type);
return;
}
if (((int32_t)tmWord->frac_part) > TIME_FRAC_MAX || ((int32_t)tmWord->frac_part) < -TIME_FRAC_MAX)
{
DBG_WARNING("Invalid fractional value %d (should between %d~%d)\n",
tmWord->frac_part, -TIME_FRAC_MAX, TIME_FRAC_MAX);
DBG_WARNING("Invalid fractional value %" PRIu32 " (should between %" PRIu32 "~%" PRIu32 ")\n",
tmWord->frac_part, (uint32_t)(-TIME_FRAC_MAX), (uint32_t)TIME_FRAC_MAX);
return;
}
TMC_Write(instPtr, TIME_ADJ_FRAC, tmWord->frac_part);