API Changelog
From berofix - professional SIP gateway
The beroFix API has changed a bit between the 1.X and the 2.0 Firmware. This page summarizes these changes.
Contents |
config file name changes
There are config file changes:
* isdn.conf (renamed to hardware.conf, because it contains now the Analog modules and in the future the GSM modules as well) * isgw.analog (file added which works the same like the isgw.isdn file for the analog ports) * filter.conf (file added for IP Filter rules. This File is optional) * isgw.tones (file added for tone settings. This File is optional) * misc.conf (file added for several misc values. This File is optional)
hardware.conf
The general Structure of the hardware.conf hasn't changed compared to the isdn.conf and is explained here: http://wiki.berofix.com/index.php/Howto_Provisioning_berofix_via_TFTP/HTTP#isdn.conf
There are now 3 new Line-Interface types:
Name - type 4FX0 - bf4FXO 4FXS - bf4FXS 2S02FXS - bf2S02FXS
If for example lif0 is a 4FXO module, it the hardware.conf has the following options:
[lif0] type=bf4FXO master=1 portswitch=0 country=1TR110_DE ; The country code defines country specific settings
Exactly the same settings apply to the 4FXS Module, so if for example lif1 is a 4FXS:
[lif1] type=bf4FXS master=0 portswitch=0 country=1TR110_DE ; The country code defines country specific settings
The hybrid 2S02FXS Module on the other hand combines the BRI and FXS Settings, so if lif1 has the bf2S02FXS Module the hardware.conf looks like:
[lif1] type=bf2S02FXS master=0 clock=0 ntteSW=te,nt ntteHW=te,nt termination=1,1 ptp=1,0 portswitch=0 country=1TR110_DE ; The country code defines country specific settings
The Country Setting must be one of the following possible countries:
FCC,TBR21,ARGENTINA,AUSTRALIA,AUSTRIA,BAHRAIN,BELGIUM,BRAZIL,BULGARIA,CANADA,CHILE,CHINA,COLOMBIA,CROATIA CYPRUS,CZECH,DENMARK,ECUADOR,EGYPT,ELSALVADOR,FINLAND,FRANCE,GERMANY,1TR110_DE,GREECE,GUAM,HONGKONG,HUNGARY ICELAND,INDIA,INDONESIA,IRELAND,ISRAEL,ITALY,JAPAN,JORDAN,KAZAKHSTAN,KUWAIT,LATVIA,LEBANON,LUXEMBOURG,MACAO MALAYSIA,MALTA,MEXICO,MOROCCO,NETHERLANDS,NEWZEALAND,NIGERIA,NORWAY,OMAN,PAKISTAN,PERU,PHILIPPINES,POLAND PORTUGAL,ROMANIA,RUSSIA,SAUDIARABIA,SINGAPORE,SLOVAKIA,SLOVENIA,SOUTHAFRICA,SOUTHKOREA,SPAIN,SWEDEN,SWITZERLAND SYRIA,TAIWAN,THAILAND,UAE,UK,USA,YEMEN
PCM Bridging
The 2.0 FW allows PCM Bridging between 2 berofix devices. Let's assume berofix 1 should be Master and berofix 2 slave. To enable PCM Bridging, you need to configure both berofixes in a specific way:
Berofix 1 (master):'
In the hardware.conf you need to define one line interface to be master. The other Lineinterface and the PCM Section must be slave. So let's assume the master berofix has a 1E1 and a 4FXS Module on it. The files hardware.conf and isgw.conf must be modified.
hardware.conf:
[lif0] type=bf2E1 master=1 clock=1 ntteSW=te,te [lif1] type=bf4FXS master=0 portswitch=0 country=1TR110_DE [pcm] type=pcm master=0
isgw.conf:
pcm_server=1 pcm_server_port=54329
Berofix 2 (slave:)
The Slave must know the Master berofix in terms of IP Configuration. So when the master berofix has for example the IP 172.20.1.1, this needs to be configured in the slave. Let's assume berofix 2 has 1 BRI and 1 FXS Module, the hardware.conf and the isgw.conf should then look as follows:
hardware.conf:
[lif0] type=bf4S0 master=0 clock=1 ntteSW=nt,nt,nt,bt ntteHW=nt,nt,nt,bt [lif1] type=bf4FXS master=0 portswitch=0 country=1TR110_DE [pcm] type=pcm master=1 ; the PCM Connector is the Clock Master
isgw.conf:
pcm_server=172.20.1.1 ; IP of the master berofix. pcm_server_port=54329
isgw.analog
The isgw.analog is used to group ports together. The group has a name and there can be group-specific settings.
isgw.analog:
[general] ; no general settings yet [test] ; Ports in the Test group ports=1,2,3,4 ;config string config= ;timeout for dialing when dad is empty overlap_dial_timeout_empty_dad=15 ;timeout for dialing overlap_dial_timeout=3 ;language code for tones tones=de ;values can be instant or polarity fxo_connect=instant ;wait,dontwait fxo_wait_for_oad=wait ;passthrough analog dialtone no or yes fxo_dialtone_passthrough=no ;busy,unobtainable,polarity fxo_call_ending_signal=unobtainable ;minimum voltage on fxo for the port to be considered as active fxo_portup_voltage=5 ;overlap dialing overlap_dialing=no ;quit dialing phase when given number of digits have been provided (when not in overlap dialing mode) overlap_dial_max_digits=20
File Content Changes
Some files have got new settings for new features:
isgw.conf:
;timeout in seconds for the feature code timer fc_timeout=2 ;local address log information is sent to locallogport=54323 ;log level(0=low,9=extreme) loglevel2=9 ;enable debug logging debug_logging=yes ;enable message logging message_logging=yes
isgw.isdn [general]
;0:do nothing 1: try to get isdn port up if L1/L2 are down (default), 2: try call though port is down portpullup=1 ;quit dialing phase when given number of digits have been provided (when not in overlap dialing mode) overlap_dial_max_digits=20
isgw.sip [general]
;sip transport modes, possible values are udp,tcp,tls sip_transport= ;tls or sslv2 ssl_version=tls
isgw.sip [port]:
;failover sip peer failover= ;some register nat specific options can be set register_options=
