#include "UDS_19Service_Internal.h"

/**
  *获取该DTC数组下标
  *@param DTC
  *@return DTC数组下标
  */
uint8_t getDTCCount(uint32_t DTC)
{
    uint8_t DTCCount = 0u;
    for(DTCCount = 0u; DTCCount < (sizeof(DTCList) / sizeof(DTCList[0u])); ++DTCCount)
    {
        if(DTCList[DTCCount][0u] == DTC)
        {
            break;
        }
    }
    return DTCCount;
}

/**
  *获取该DTC数组下标的DTC
  *@param DTCcount DTC数组下标
  *@return DTC
  */
uint32_t getDTCNumber(uint8_t DTCcount)
{
    return DTCList[DTCcount][0u];
}