Sccp/skinny support in freepbx 12

I tried adding include functions.inc.php to the page.sccp__devices.php thinking that it might know where to load the functions from but only ended up with error Cannot redeclare sccp_reset_phone() (previously declared in /var/www/html/admin/modules/sccp_manager/functions.inc.php:9).

any update on this? im chugging away with some of the codes and such. but im having trouble getting illegal string offsets to go away.

The BMO stuff is killing me. Iā€™ve been programming this kind of stuff since the '70s and I just canā€™t get my head around the encapsulation.

Iā€™m gonna keep at it. As soon as I upload a new version to GitHub, Iā€™ll let everyone know.

anyway to post what you have? maybe we can help figure it out. i got the illegal strings to go away on the extensions page by replacing ā€™ with ` but the page does not populate the database values back into the form when trying to edit them.

Some resources.



http://wiki.freepbx.org/display/FOP/Uniformity+Guidelines
http://wiki.freepbx.org/display/FOP/Bootstrap+tables

Ok Iā€™ve got it all installed and working (mostly) Iā€™m just stuck on one part.

When I go to add a phone (on the SCCP Phones page) it doesnā€™t create the SEPā€¦cnf.xml file in the /tftpboot directory. Everything else seems to be working.

When I add or edit a phone I get the following error
file_get_contents(): Filename cannot be empty

function sccp_edit_tftp($tftpdisplay,$tftpData) {
    global $db;
    $filename = "/tftpboot/$tftpdisplay.cnf.xml";
    $tftpfile = file_get_contents($inputfile);

However if I refresh the page the SEPxxxxxxxxxxxx (7960) - Ext is listed there but the SEPxxxxxxxxxxxx.cnf.xml is still not in the tftpboot directory?

Any ideas? The tftpboot dir is chmod 777.

If you port your stuff to GitHub, we can get the pre-V12 stuff working reasonably well (except for the TFTP default stuff, the XML always gets chewed up).

Wait. Change the $inputfile argument to $filename (or change the $filename.to $inputfile)

The new BMO stuff is a steep climb for me, so the V12+ extension still isnā€™t any closer to getting done than it was before I got distracted with some paying work.

Just an FYI, Cisco themselves are getting rid of SCCP. Might be time for the rest of us to move on too.

1 Like

You are passing the param ā€˜$inputfileā€™ to file_get_contents. But youā€™re not defining it. Youā€™re defining $filename. Either change $filename to $inputfile, or change $inputfile to $filename

That seems to work when editing an existing SEPxxxxxxxxxxxx.cnf.xml but it still doesnā€™t create a new file. The page reloads and says itā€™s there on the right hand side. I can click on it to edit it but it doesnā€™t create the SEP file in the /tftpboot directory.

Thanks

So I know this is an older topic, but Iā€™m trying to setup and run the SCCP Manager from cynjut, and fixed a bunch of issues with the install and some of the pages, but some of them, such as sccp_devices just give errors that Iā€™m not 100% sure how to fix. Iā€™ve verified that asterisk has full perms on the tables, and the files, and that there actually is data in the tables, but still getting this error:

Invalid argument supplied for foreach()  

      
      
        
    
                            /var/www/html/admin/modules/sccp_manager/page.sccp_devices.php
              
                	<td></td>	<td><a href="#" class="info">Softkeyset:<span>Select the softkeyset from the list. You can manage your keysets from the SCCP keysets option. The default is 'softkeyset'.</span></a></td>	<td>	<select name='devData[softkeyset]' id='softkeyset' >       	<?php    	    $keyset = sccp_list_keysets();	    echo "<option value='default'> default</option>";    	    foreach ($keyset AS $check) {	    	if ($devData['softkeyset'] == $check) {		    echo "<option value='$check' selected='selected'> $check</option>";

Does anyone have this fully working to manage their SCCP phones? Iā€™ve got phones registering via chan_sccp_b, just would love to have a working GUI for my team who isnā€™t so CLI savvy.

Thanks!

The problems with SCCP Manager are manifest and not really compatible with the Data Model for FreePBX 12 and above. There are issues with it that make is not really appropriate for systems that have an ā€œoutward facingā€ interface.

Iā€™ve been busy with other projects, so I havenā€™t had time to rewrite the module to conform to the new coding and visual standards for FreePBX 13.

One thing you can check is that you actually have softkeysets defined in your database. As noted in the docs, there is a default softkeyset called (not surprisingly) ā€œsoftkeysetā€. If you want to add additional keysets, you can.

Yes, actually, I do. The installation process still has issues - I wrote the system to manage an existing and working SCCP installation, so a lot of the ā€œseedingā€ of the data is a little off-kilter. I actually have it installed on one of my FreePBX 13 installations. Unfortunately, because of the new BMO interface, the system doesnā€™t meet the safety standards for FreePBX anymore. The system, instead of using BMO, does direct calls to the database (which was normal in FreePBX installs at and before 1.8). This method is no longer optimal and shouldnā€™t be used.

Hi Dave, I hope you would find a time to finish this up. I bet much more people would appreciate your module if it would work on newer systems. Is there a legitimate approach as to how to modify the code or there is just no way it would work? Thanks.

Dave,

Iā€™m also wondering about the ā€œlegitimate approach as to how to modify the codeā€ or does it have to be completely re-written?

Iā€™m asking because my company has an army of programmers and I can probably get one to fix this all for FreePBX 13, but before I ask their manager to let me ā€˜borrowā€™ the programmer, I need to know if it is going to be a 1-day project or a 1-month project :smiley:

Thanks!

Probably three days. The basic code isnā€™t that challenging, but a lot of the groveling through the database and display code changed, so itā€™s going to take a couple of days just to get the framework figured out. Once you understand the framework, the rest is pretty straightforward (lots of reading through flat files and putting everything back in the right order).

Dave,

Thanks for the information. Hopefully I can get this working properly with fPBX13

Will let ya know!

I would like to know about if this is completed

I havenā€™t heard and I havenā€™t had any time.

Remember, the SCCP Manager (which is the GUI piece weā€™re talking about) is completely separate from the SCCP_Chan_B driver set, which is working flawlessly in Asterisk 13 and (albeit without a GUI) FreePBX 13.

Just an update.

Iā€™ve gotten most of the pages of this module to work with fPBX 13, just waiting on someone with greater PHP/SQL experience than myself to help out with the last few pages.

Cisco has disbanded SCCP. Time for you to do the same.