     do: String.to_existing_atom(axis)
 
   defp assert_axis!(axis) do
-    # {:error, "unknown axis #{axis}"}
     raise("unknown axis #{axis}")
   end
 end

    end
  end

  defp do_move_absolute(x, y, z, speed, retries, errors) do
    with {:ok, speed_x} <- param_read(:movement_max_spd_x),
         {:ok, speed_y} <- param_read(:movement_max_spd_y),
         {:ok, speed_z} <- param_read(:movement_max_spd_z),

        {:error, "emergency_lock"}

      {:error, reason} ->
        handle_movement_error(reason)

      reason ->
        handle_movement_error(reason)
    end
  end

  def handle_movement_error(reason) do
    msg = "Movement failed. #{inspect(reason)}"
    FarmbotCore.Logger.error(1, msg)
  end

  def calibrate(axis) do
