code: func (h *ADXL345Driver) SetRange(sensorRange byte) (err error) {
  	if sensorRange != ADXL345_RANGE_2G &&
  		sensorRange != ADXL345_RANGE_4G &&
  		sensorRange != ADXL345_RANGE_8G &&
  		sensorRange != ADXL345_RANGE_16G {
  		return errors.New("not a valid range")
  	}
  	h.dataFormat.sensorRange = sensorRange & 0x03
  	if _, err := h.connection.Write([]byte{ADXL345_REG_DATA_FORMAT, h.dataFormat.toByte()}); err != nil {
  		return err
  	}
  	return
  }
docs: // SetRange change the current range of the sensor