All of the content of this repository is taken from my website as it is easier to add stuff here rather than on the website. https://buba.pw/tutorial
Welcome! This tutorial will guide you through the process of setting up Cisco 7900 phones to work with FreePBX.
For clabretro, I've found SIP firmware for 7965 phones. You can download it from the official Cisco link below:
If you don’t have a Cisco account or can’t download it, email me, and I'll send it to you. Make sure to download:
cmterm-7945_7965-sip.9-4-2-1SR3-1.zip
- Power down the phone by unplugging the 48VDC PoE Ethernet cable or power adapter.
- Plug the power source back in while holding the
#
key. Keep holding it until the line buttons start flashing. - When the line buttons flash, press
123456789*0#
.
-
Install Tftpd64 on a Windows machine.
-
Configure your Ethernet adapter settings as shown:
-
Open Tftpd64 and adjust the settings as shown:
-
Set the "Current Directory" to the folder containing the firmware files:
- Connect the phone to a PoE switch (or non-PoE switch with a power injector). Cisco 7900 series phones have known issues with auto MDI-X.
- Power on the phone. It will display the "Upgrading" screen.
- Wait for the phone to display an IP address and begin downloading files from the TFTP server. You can monitor this in Tftpd64.
- Once the phone finishes downloading, it will reboot automatically.
-
Install the TFTP server on Debian 12:
sudo apt install tftpd-hpa
Note:
tftpd-hpa
is often installed along with FreePBX. -
Configure the TFTP server by editing
/etc/default/tftpd-hpa
: -
Restart the TFTP server:
sudo systemctl restart tftpd-hpa.service
-
Upload the configuration file (e.g.,
SEP[MAC_ADDRESS].cnf.xml
) to the TFTP server directory (typically/tftpboot
or/srv/tftp
). -
Some phones are picky about config files, so try one of these:
-
Upload
dialplan.xml
to the same directory: -
Configure the phone:
- Press the Checkmark button →
Network Configuration
→IPv4 Configuration
→Alternate TFTP
- Press
**#
to unlock settings - Click
Yes
to enable Alternate TFTP - Scroll to
TFTP Server 1
and set it to the TFTP server's IP
- Press the Checkmark button →
-
Restart the phone. It should provision automatically.
-
Go to Settings → Asterisk SIP Settings → SIP Settings [chan_pjsip] in the FreePBX admin panel.
-
Adjust the transport settings as shown:
-
Click Submit and Apply Config, then restart FreePBX and the phone.
You can customize the background of your Cisco 7900 series phones by adding a Desktops
directory to the TFTP server directory where SEP[MAC_ADDRESS].cnf.xml
and dialplan.xml
are stored.
Image dimensions for different phone models:
Phone Model | Full Image | Thumbnail (25% of full image) | Color Depth | Directory Path |
---|---|---|---|---|
7906G / 7911G | 95 x 34 | 23 x 8 | Grayscale | /Desktops/95x34x1 |
7941G / 7961G | 320 x 196 | 80 x 49 | Grayscale | /Desktops/320x196x4 |
7942G / 7962G | 320 x 196 | 80 x 49 | Grayscale | /Desktops/320x196x4 |
7945G / 7965G | 320 x 212 | 80 x 53 | 16-bit Color | /Desktops/320x212x16 |
7970G / 7971G | 320 x 212 | 80 x 53 | 12-bit Color | /Desktops/320x212x12 |
7975G | 320 x 216 | 80 x 54 | 16-bit Color | /Desktops/320x216x16 |
Images should be in PNG format.
-
Create the following directory structure:
For 7942 for example:
/tftpboot/Desktops/320x196x4/
For 7975:
/tftpboot/Desktops/320x216x16/
-
Place your custom background images in
320x196x4/
or320x196x4/
. These must be in 320x196 resolution with 4-bit color depth or monochrome, if made for 7942. Refer to the table above for your phone's display details. -
Add a
List.xml
file inside the desired directory eg:320x196x4
or320x216x16
to specify available backgrounds. -
Example
List.xml
format:<CiscoIPPhoneImageList> <ImageItem Image="TFTP:Desktops/320x196x4/ubuntu-tn.png" URL="TFTP:Desktops/320x196x4/ubuntu.png"/> <ImageItem Image="TFTP:Desktops/320x196x4/tux-tn.png" URL="TFTP:Desktops/320x196x4/tux.png"/> </CiscoIPPhoneImageList>
-
Restart the phone and navigate to the settings to select the new background.
I have been doing some tinkering and made a kind of phonebook by accident. If you want a phone book of sorts then I've attached a folder called phonebook. In there there are PHP files, index.html we're interested about. Place the files in /var/www/html/webapp
directory. It reads off of a database and returns the values with cisco phone format. you need to make a database called "phonebook" and a table "employees":
CREATE DATABASE phonebook;
USE phonebook;
CREATE TABLE employees (
id INT AUTO_INCREMENT PRIMARY KEY,
name VARCHAR(100) NOT NULL,
phone VARCHAR(20) NOT NULL
);
Next create a user that can access that database:
CREATE USER 'user'@'%' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON phonebook.* TO 'user'@'%';
Next you want to go to the phone config and find:
<servicesURL></servicesURL>
and add a URL like this:
<servicesURL>http://freepbx_ip_address/webapp/index.php</servicesURL>
Now when you press the globe icon on the phone the service will show a list of users that you put in.
In the index.php there is a variable called $limit = X
where X is the number of contacts per page. If there is more entries in the phonebook than the value of this variable, the directory/phonebook will have a softkey "Next" and "Previous"
Go to http://freepbx_ip_address/webapp/contacts.php
to manage your contacts.
UPDATE DATABASE CREDENTIALS IN THE CONFIG FILE FOR THE SERVICE TO WORK
If you have any questions, feel free to reach out at kubab945@gmail.com.
Or open a GitHub issue.
© 2025 buba.pw