Hi Adilson,
Can you please do a quick test here? Asuming you haven't registered your program in PI side explictly (which is not required anyways), please stop the sender RFC channel and try doing the connection test from SM59 (ECC) side one more time. Ideally, it should fail with Progam ID not registered error. If you see any other error, you may need to revisit your RFC connection settings.
At this time , I am also assuming below points are already taken care of.
1. Firewall between ECC and PI is up and running with out any issues.
2. RFC destination name is same as Program ID (check out for invisible space(s)
3. Host name, gateway details (as mentioned in SM59) are correct and exactly matches that in RFC sender channel.
Also, can I please request you to knidly share more dump details? One shared above is very high level.
Thanks,
Anir.