/* stts751_trigger_set - link external trigger to event data ready  */
int stts751_trigger_set(const struct device *dev, const struct sensor_trigger *trig, sensor_trigger_handler_t handler)
/* stts751_trigger_set - link external trigger to event data ready  */
int stts751_trigger_set(const struct device *dev, const struct sensor_trigger *trig, sensor_trigger_handler_t handler)
{
	struct stts751_data *stts751 = dev->data;
	const struct stts751_config *config = dev->config;
	if (!config->int_gpio.port) {
		return -ENOTSUP;
	}
	if (trig->chan == SENSOR_CHAN_ALL) {
		stts751->thsld_handler = handler;
		stts751->thsld_trigger = trig;
		if (handler) {
			return stts751_enable_int(dev, 1);
		} else {
			return stts751_enable_int(dev, 0);
		}
	}
	return -ENOTSUP;
}