# Blinker - SIP Phone Connector

The SIP phone connector module acts as SIP client and provides an interface to the internal operator connections. Each module instance is a separate SIP client and can handle a single call at a time. The incoming calls are connected to an internal operator connector. Received DTMF tones are delivered to the operator connection. Sound play requests received over the operator connection are processed based on `*.wav` files in the `sounds` subdirectory, i.e., the sounds are played on the SIP connection if the file is found.

## Configuration

The configuration of the SIP phone connector module with name `NAME` is located in the `sipphones/NAME` subdirectory.

### SIP Server Name

The file `server` contains the host name of the SIP server.
The SIP phone connector module will register with this server and accept incoming calls (or reject them if another call is already in progress).

### SIP User Name

The file `username` contains the user name for the SIP connection. It is used for authentication and to form the SIP identity by prepending it to the SIP server name (separated `@`).

### SIP Password

The file `password` contains the password for the SIP authentication. Please note that those files are not present in the example configuration.

### Target Operator Connection Slot

The file `target` contains the name of the operator interface to contact via an operator connection if the extension is called.

### Sound Directory

The `*.wav` files used to process sound playback requests received on the internal operator connection are read from the `sounds` subdirectory. The file name extension `.wav` is automatically appended to the name of the requested sound. This means if a sound play request for `SOUND` is received, the file `sounds/SOUND.wav` if opened. If it exists, it is played in the SIP connection.

### Log Files

Log information from the SIP library is written to the file `sip.log`. When the file reaches 10000 lines, a new log file is started (using the same file name). The previous log file is kept under the name `sip.log.prev`.