3.2.13.1 DIAG_GCLK_ClockCalibration

Returns the status of the GCLK_CLOCK_CALIBRATION diagnostic

This function will perform frequency test on GCLK peripheral. This function will measure the frequency of the GCLK with reference clock.

DIAG_TEST_STATUS 
DIAG_GCLK_ClockCalibration
(
    DIAG_GCLK_PERIPHS gclk_periph, 
    uint32_t expected_freq
);

Diagnostic verifies the following faults do not exist

  • GCLK is not generated properly

Operating Mode

  • Interface can be used at POST and ‘On Demand’
Precondition
  • none

Parameters

  • DIAG_GCLK_PERIPHS gclk_periph - glck peripheral
  • uint32_t expected_freq - expected frequency

Returns

  • DIAG_TEST_PASSED if no faults were found, otherwise, DIAG_TEST_FAILED.