[Asterisk-Users] Re: chan_skinny and firmware upgrade

Tom Ivar Helbekkmo tih at eunetnorge.no
Mon Jan 24 09:30:42 MST 2005


Subhi S Hashwa <lists at subhi.com> writes:

> The xml request is a feature of new firmware, that is my guess.

Yup.  Older, skinny capable, phones request the SEP...cnf file, which
is in a binary format.  I don't know how to get them to update their
firmware, but I do know how to build the SEP file to configure the
phones correctly.  I use the below program to write a simple one, to
give the phone the name, address and TCP port number (2000) to use for
the skinny protocol (I haven't bothered to make something that reads
the configuration data from the terminal -- I edit, compile, and run):

/*
 * Program to write a SEPDefault.cnf for Cisco SCCS phones.
 * Records in the file have two bytes that tell what data
 * is supplied, then the data (either fixed length or as
 * a zero-terminated character string.
 */

#include <stdio.h>
#include <stdlib.h>

int main(int argc, char **argv) {
  FILE *SEPDefault;
  unsigned char SEPData[BUFSIZ];

  SEPDefault = fopen("SEPDefault.cnf", "w");

  /* change the string to be the FQDN of the call manager: */
  sprintf(SEPData, "%c%c%s", 1, 1, "pbx.company.com");
  fwrite(SEPData, 1, strlen(SEPData) + 1, SEPDefault);
  /* change the last four numbers to the IP address of the call manager: */
  sprintf(SEPData, "%c%c%c%c%c%c", 1, 2, 192, 168, 1, 42);
  fwrite(SEPData, 1, 6, SEPDefault);
  /* the last four numbers are 2000 as a four byte little-endian integer: */
  sprintf(SEPData, "%c%c%c%c%c%c", 1, 3, 208, 7, 0, 0);
  fwrite(SEPData, 1, 6, SEPDefault);
  /* this is a special end of file marker: */
  sprintf(SEPData, "%c%c", 1, 255);
  fwrite(SEPData, 1, 2, SEPDefault);

  fclose(SEPDefault);
}

/*
 * eof
 */

-tih
-- 
Tom Ivar Helbekkmo, Senior System Administrator, EUnet Norway Hosting
www.eunet.no  T +47-22092958 M +47-93013940 F +47-22092901 FWD 484145



More information about the asterisk-users mailing list