public String openRECEIVE(DatagramPacket syn) throws IOException{
        Transporte t = new Transporte(initTransporteACKeSYN);
        Transporte t1 = new Transporte(initTransporteACKeSYN);
        
        seq = 100;        

        
     //desencapsula SYN e reconhece o endereco/porta do outro terminal
        t1 = t1.receberDeDatagramPacket(syn);
        this.sendIPAddress = syn.getAddress();
        this.sendPort = Transporte.byteToInt(t1.getDados(),2); //recebe a receivePort do cliente
        this.receiveSocket = new DatagramSocket();
        this.receiveSocket.setSoTimeout(SOCKETTIMEOUT);
        mtu = Transporte.byteToInt(t1.getMTU(),2);
        win = Transporte.byteToInt(t1.getWin(),2);
                
     //criar SYN_ACK 
        int x = Transporte.byteToInt(t1.getSeq(), 2) + 1; //num_ack = num_seq(SYN) + 1
        t.createTransportePacket("SYN_ACK", 0, 2, win, mtu, seq, x, Transporte.intToByte(this.receiveSocket.getLocalPort(), 2));
        Console_println(t.toString()); //teste
        
     //envia SYN_ACK e espera por ACK
        RTT = RTT_INIT;
        do{ RTT--;
            t.enviarTransporte(this.sendSocket, this.sendIPAddress, this.sendPort);
            Console_println(">SYN_ACK enviado"+ " para "+this.sendIPAddress.getHostAddress()+":"+this.sendPort);

            this.iniciar_smallTimeOut(boundedB,timeout,SMALLTIMEOUT_OPEN);
            
            Console_println(">a espera de ACK");
            
            t1 = recebeuACKde(t, this.sendIPAddress);
            if(timeout.value==1) Console_println("timeout");
            if(RTT<0) return rtt_error;
        }while(timeout.value==1 || t1==null);
        
        return sucesso;
   }