/* Unregisters an asynchronous callback function with the driver. 
Unregisters an asynchronous callback with the DAC driver, removing it from the internal callback registration table. */
enum status_code dac_unregister_callback(struct dac_module *const module_inst, const enum dac_channel channel, const enum dac_callback type)
/* Unregisters an asynchronous callback function with the driver. 
Unregisters an asynchronous callback with the DAC driver, removing it from the internal callback registration table. */
enum status_code dac_unregister_callback(struct dac_module *const module_inst, const enum dac_channel channel, const enum dac_callback type)
{
	Assert(module_inst);
	if (module_inst->start_on_event[channel] == false) {
		return STATUS_ERR_UNSUPPORTED_DEV;
	}
	if ((uint8_t)type < DAC_CALLBACK_N) {
		module_inst->callback[channel][(uint8_t)type] = NULL;
		return STATUS_OK;
	}
	return STATUS_ERR_INVALID_ARG;
}