Beispiel #1
0
/**
 * @brief   Enables or disables RTC callbacks.
 * @details This function enables or disables the callback, use a @p NULL
 *          pointer in order to disable it.
 *
 * @param[in] rtcp      pointer to RTC driver structure
 * @param[in] callback  callback function pointer or @p NULL
 *
 * @api
 */
void rtcSetCallback(RTCDriver *rtcp, rtccb_t callback) {

  chDbgCheck((rtcp != NULL), "rtcSetCallback");

  chSysLock();
  rtcSetCallbackI(rtcp, callback);
  chSysUnlock();
}
Beispiel #2
0
/**
 * @brief   Enables or disables RTC callbacks.
 * @details This function enables or disables the callback, use a @p NULL
 *          pointer in order to disable it.
 *
 * @param[in] rtcp      pointer to RTC driver structure
 * @param[in] callback  callback function pointer or @p NULL
 *
 * @api
 */
void rtcSetCallback(RTCDriver *rtcp, rtccb_t callback) {

  osalDbgCheck(rtcp != NULL);

  osalSysLock();
  rtcSetCallbackI(rtcp, callback);
  osalSysUnlock();
}