/**
   * Opening Connection to the serial port.first check whether port is open if not create new
   * connection to the port.
   */
  private void openConnection() {
    try {
      if (connection.isOpen()) {
        System.out.println("Port Open!,Can't open a new connection while a port is open.");
        ezlink.info("Port Open!,Can't open a new connection while a port is open : ");
      }

      connection.openConnection();
    } catch (SerialConnectionException e2) {
      System.out.println(e2);
      ezlink.error(new Object(), e2);
    }
  }