code: private static String commandRun(Command command) {
          // Wait bind
          if (I_COMMAND == null) {
              synchronized (I_LOCK) {
                  if (I_COMMAND == null) {
                      try {
                          I_LOCK.wait();
                      } catch (InterruptedException e) {
                          e.printStackTrace();
                      }
                  }
              }
          }
  
          // Cancel Destroy Service
          cancelDestroyService();
  
          // Get result
          // In this we should try 5 count get the result
          int count = 5;
          Exception error = null;
          while (count > 0) {
              if (command.isCancel) {
                  if (command.mListener != null)
                      command.mListener.onCancel();
                  break;
              }
              try {
                  command.mResult = I_COMMAND.command(command.mId, command.mTimeout, command.mParameters);
                  if (command.mListener != null)
                      command.mListener.onCompleted(command.mResult);
                  break;
              } catch (Exception e) {
                  error = e;
                  count--;
                  try {
                      Thread.sleep(3000);
                  } catch (InterruptedException e1) {
                      e1.printStackTrace();
                  }
              }
          }
  
          // Check is Error
          if (count <= 0 && command.mListener != null) {
              command.mListener.onError(error);
          }
  
          // Check is end and call destroy service
          if (I_COMMAND != null) {
              try {
                  if (I_COMMAND.getTaskCount() <= 0)
                      destroyService();
              } catch (Exception e) {
                  e.printStackTrace();
              }
          }
          // Return
          return command.mResult;
      }
docs: Run do Command
  
  @param command Command
  @return Result