/* Find an empty spot for callback in set.  */
static int8_t findCallbackSpace(TEMPDRV_CallbackSet_t *set)
/* Find an empty spot for callback in set.  */
static int8_t findCallbackSpace(TEMPDRV_CallbackSet_t *set)
{
  uint8_t index;
  for (index = TEMPDRV_CUSTOM_CALLBACK_INDEX; index < TEMPDRV_CALLBACK_DEPTH; index++)
  {
    if (set[index].callback==NULL)
    {
      return index;
    }
  }
  return -1;
}