code: func floatToCmdByte(cmd float32, mid byte, maxv byte) byte {
  	if cmd > 1.0 {
  		cmd = 1.0
  	}
  	if cmd < -1.0 {
  		cmd = -1.0
  	}
  	cmd = cmd * float32(maxv)
  	bval := byte(cmd + float32(mid) + 0.5)
  	return bval
  }
docs: // floatToCmdByte converts a float in the range of -1 to +1 to an integer command