This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28377D: ADC Macro Issue

Part Number: TMS320F28377D

Tool/software:

Dear TI,

I have a client who uses a macro to compute an ADC value. However, I am encountering unexpected behavior between two boards that utilize the same DSP. On revision A, the macro executes correctly, and the corresponding physical values are computed accurately. When flashing the same code onto revision B, the CPU no longer outputs the expected values and instead returns 0.

Changing this macro significantly impacts the codebase because it is extensively used throughout the application. Therefore, it is critical to confirm that the macro itself is causing the issue before proposing any modifications to the client.

To investigate further, I manually computed the ADC values in revision B using the conversion coefficients to determine if the macro was incorrectly executed. The manual calculation confirmed that the ADC values are accurate and correctly transmitted to the application.

Your support in diagnosing and resolving this issue would be greatly appreciated.

Best regards,

#define Analog_ReadPhy(channel) 	ANALOG_CLAMP((float32_t)(Analog_Read(channel)*Analog_Trim[Analog_##channel].Coef_A)+Analog_Trim[Analog_##channel].Coef_B,Analog_Trim[Analog_##channel].MinPhyValue,Analog_Trim[Analog_##channel].MaxPhyValue)

  • Hello,

    I discovered that the buffer used by the macro is declared, but it has been placed in a section that is not defined in the CMD file. However, in revision A, the buffer is available, and the conversion works.