Routing inbound calls (ss7->sip) based on the E1/T1 port
Â
Syntax:
<condition field="${freetdm_span_number}" expression="X" break="never">
    <action application="bridge" data="sofia/internal/${destnumber}@<ip address>:<port>"/>                 Â
    <action application="hangup" data="${originate_disposition}"/>
</condition> |
Â
Detailed description:
 In the above dialplan replace  ‘X’ with the E1/T1 port you want to target.
 Also replace <ip address>:<port> with IP address and port of the sip end point you want to send the traffic to
 Â
Below is an example of traffic from port 2 that routes to softswitch 1.2.3.4:5060 and port 3 that routes to softswitch 5.6.7.8:5060:Â
<condition field="${freetdm_span_number}" expression="2" break="never">Â
    <action application="bridge" data="sofia/internal/${destnumber}@1.2.3.4:5060"/>
    <action application="hangup" data="${originate_disposition}"/>        Â
</condition> |
<condition field="${freetdm_span_number}" expression="3" break="never">Â
    <action application="bridge" data="sofia/internal/${destnumber}@5.6.7.8:5060"/>
    <action application="hangup" data="${originate_disposition}"/>        Â
</condition> |
Â
 Where to place these condition statements
 The above dialplan examples must be placed within the <context name="from-pstn-to-sip">> and above the ‘bridge’ line (which is line that routes the call)
   |
Â
Â