/* Autosleep. When set to 1, autosleep is enabled, and the device enters wake-up mode automatically upon detection of inactivity.  */
int32_t adxl372_set_autosleep(adxl372_dev *dev, bool enable)
/* Autosleep. When set to 1, autosleep is enabled, and the device enters wake-up mode automatically upon detection of inactivity.  */
int32_t adxl372_set_autosleep(adxl372_dev *dev, bool enable)
{
	int32_t ret;
	ret = adxl372_spi_write_mask(dev,
				     ADXL372_MEASURE,
				     ADXL372_MEASURE_AUTOSLEEP_MSK,
				     ADXL372_MEASURE_AUTOSLEEP_MODE(enable));
	return ret;
}