When testing connections, you must specify various parameters, depending on whether the calling program is an ABAP/4 program or a C program:
You will find more information in the following topics:
Calling Program: ABAP Program in R/3 Calling Program: ABAP Program in R/2 Calling Program: C Program