Undocumented Panasonic KX-TA Command Interpreter

In order to take advantage of the undocumented CLI, you need a 9-pin RS-232 null modem cable (or straight-through cable and null-modem adapter), a serial port on your PC, and a terminal emulator. On Windows, HyperTerminal will suffice; on Linux, you can use minicom or cu.

Examples on this page refer specifically to the KX-TA624, and the Perl scripts assume a 624 unit as well.

Perl scripts

I have written a pair of Perl 5 scripts to automate the process of downloading and uploading configuration data. They depend on the Device::SerialPort package.

kxdump will connect to the system and download the desired data to the specified text file.

Usage: kxdump pass type outfile

pass is the Panasonic system password

type is the type of data dump:
  ALL   dump all data
  SYS   dump system parameters
  COT   dump CO trunk parameters
  EXT   dump extension parameters
  DSS   dump DSS console parameters
  DOR   dump doorphone parameters

kxbatch will take a dump file created by kxdump (or portions thereof) and upload it to the PBX. THE DATA MUST END WITH AN EOD OR ELSE THE SYSTEM WILL GET STUCK IN PROGRAMMING MODE UNTIL YOU USE A TERMINAL EMULATOR TO "UNSTICK" IT! Or, you could power-cycle the PBX...

Usage: kxbatch pass infile

pass is the Panasonic system password

infile is the configuration dump file to load

WARNINGS:

  • The system cannot process calls in programming mode. Any calls in progress will be summarily disconnected, and no calls can be placed or received until programming mode is ended.
  • Improper programming may disrupt operation of your system, or potentially leave it open for exploitation by unauthorized users. You should have your installation manual handy. You may need to correct wrong settings using a system phone in the normal manner, or even do a full system reset if things go wrong.
  • The CLI can access features that are normally unavailable in US-market KX-TA624 units (notably, automatic route selection and alternate numbering plans). These settings cannot be corrected from the manager phone.

  • Preparation

    You should first check and see if you are correctly receiving SMDR output. The typical default setting of the KX-TA624 is 9600 bps, 8 bits, mark parity, 1 stop bit (9600, 8-M-1). You can get away with no parity (9600, 8-N-1), with the restriction that the system will refuse the input of many lower-case characters. Stick to upper case, and 9600 8-N-1 won't be a problem.

    If SMDR output is working, you can put the system into programming mode by sending a couple of carriage returns and typing:

        TA624

    and then pressing ENTER. These characters might not be echoed back to your system.

    At this point, if you have display phones attached, you will see their displays go blank. The system cannot process calls until you quit programming mode. You should see a banner displayed, followed by a command prompt:

    ; Welcome to KX-TA308/616/624  on-site administration
    ;                       ver11.0 Panasonic CO.,LTD
    ;** Aug. 5.2005  10:11'AM **
    
    ; The "HLP" displays command informations
    
    ;>
    

    At any point in programming mode, the BYE command will return the system to normal call processing mode. There will be no confirmation other than seeing the displays on system phones turn back on.

    On entering any command other than BYE, the system will prompt you for the password. This is the same password that is used when programming the system from a display phone on Jack 01. Once the password is successfully entered, you will not be asked for it again until the next time you enter programming mode.

    At the top level, HLP lists three commands:

    ;>HLP                                                                           
    ; Select the mode                                                               
    ;   Edit............... EDT(cr)
    ;   Show............... SHW(cr)
    ;   Dump............... DMP(cr)
    
    ;>
    

    DMP - dump system data

    DMP will dump system data in the CLI programming format (as opposed to the printer-friendly format that Program 804 provides from the normal phone-based programming mode). You can select ALL for dumping all data, SYS for system-related data, COT for CO trunk data, DSS for DSS console data, DOR for doorphone data, and END to return to the top level prompt.

    ALL is a bit of a misnomer, since certain per-extension settings (such as forwarding and Data Line Security) are NOT accessible via CLI programming (and are also not accessible when programming from the manager's phone).

    Here is a highly-abridged COT dump to illustrate:

    ;P>COT                                                                          
    ; CO data dump start                                                            
                                                                                    
    350C1/0/                                                                        
    350C2/0/                                                                        
    350C3/0/                                                                        
    350C4/0/                                                                        
    350C5/0/                                                                        
    350C6/0/                                                                        
    [snipped]                                  
    400C1/1/                                                                        
    400C2/1/                                                                        
    400C3/1/                                                                        
    400C4/1/                                                                        
    400C5/1/                                                                        
    400C6/0/                                                                        
    [snipped]
    408C1/1111_1100,0111_0000,1111_1111/                                            
    408C2/1111_1100,0111_0000,1111_1111/                                            
    408C3/1111_1100,0111_0000,1111_1111/                                            
    408C4/1111_1111,1111_1111,1111_1111/                                            
    408C5/1111_1111,1111_1111,1111_1111/                                            
    408C6/1111_1111,1111_1111,1111_1111/                                            
    [snipped]
    928C1/0/                                                                        
    928C2/0/                                                                        
    928C3/0/                                                                        
    928C4/0/                                                                        
    928C5/0/                                                                        
    928C6/0/                                                                        
    EOD                                                                             
                                                                                    
    ; CO data dump end                                                              
                                                                                    
    ;P>
    

    Dumps end with EOD to indicate the end of data. This is needed when performing a batch upload.

    The basic CLI syntax for programming data depends on the program number, and settings for extension function keys and DSS keys have a special syntax. A complete description would fill a book; I strongly recommend that you consult your installation manual.

    Examples:

    002S/1234/ Program 002 (System Password), set to 1234
    009S00/1/ Program 009 Numbering Plan 1. On US systems, the numbering plan cannot be changed from the manager's phone, but it can be changed here (not recommended).
    009S06/184/ Program 009 - set jack J06 to use extension 184. This part of Program 009 works on the manager's phone regardless of country.
    100S/0110_0000/ Program 100, enable hunting on extension groups 2 and 3 only.
    408C1/1111_1100,0111_0000,1111_1111/ Program 408, daytime flexible ringing assignment for CO line 1, disable ringing on jacks J07, J08, J13, J14, J15, and J16.
    600E07/2/ Program 600, assign jack J07 to extension group 2.
    604E01/RUSS      / Program 604, assign the name RUSS to jack J01 (10 characters max)
    P01BC01/0,1/ Make J01's CO1 button a Single-CO button for line CO1.
    P01BC12/2,04/ Make J01's CO12 button a DSS button for jack J04.
    P01BF01/918005551212/ Make J01's PF1 button dial 9-1-800-555-1212.
    D01BD04/2,04/ Assign DSS Console 1's DSS button 4 to jack J04.

    NOTE: The system will randomly insert NUL (ASCII 0) characters in the dump. Care must be taken to filter these out if you plan to use DMP output for batch programming the system.

    SHW - show individual items

    SHW allows you to query individual settings as opposed to dumping data. You can use either INT for interactive queries, or FIL for batch queries. END will send you back to the top-level prompt. The latter seems to be of questionable usefulness to me, but it works in a similar way to the more useful batch upload discussed below, except that you would only send the program numbers without data.
    In INT mode, if you wanted to query program 408 for CO line 1, you would inter 408C1 and press ENTER. The system would rewrite your line to show the current contents of the program.

    EDT - edit mode

    This allows programs to be modified, either on an interactive basis (INT), or a batch basis (FIL). Batch uploads would use your terminal emulator's ASCII transfer function, and should end with EOD to indicate the end of the batch. In FIL mode, characters are not echoed until the entire command line is entered. Once an EOD is received, END will return to the EDT command line, and another END will return to the top level.

    Due to the vagaries of ASCII transfer, I would recommend using the Perl scripts to send data to and retrieve data from the system.