/** * @brief Deactivates the GPT peripheral. * * @param[in] gptp pointer to the @p GPTDriver object * * @api */ void gptStop(GPTDriver *gptp) { osalDbgCheck(gptp != NULL); osalSysLock(); osalDbgAssert((gptp->state == GPT_STOP) || (gptp->state == GPT_READY), "invalid state"); gpt_lld_stop(gptp); gptp->state = GPT_STOP; osalSysUnlock(); }
/** * @brief Deactivates the GPT peripheral. * * @param[in] gptp pointer to the @p GPTDriver object * * @api */ void gptStop(GPTDriver *gptp) { chDbgCheck(gptp != NULL, "gptStop"); chSysLock(); chDbgAssert((gptp->state == GPT_STOP) || (gptp->state == GPT_READY), "gptStop(), #1", "invalid state"); gpt_lld_stop(gptp); gptp->state = GPT_STOP; chSysUnlock(); }