Koozali.org: home of the SME Server

A couple of problems with Selintra Sail

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« on: November 30, 2006, 02:27:59 PM »
Hi,
Thanks for the fantastic contrib.  Here is my setup:
Fresh install of SME 7.0 - no updates
Dell 420 sc, 2 x 160G drives in HW RAID (Dell SATA controller)
1G RAM
2 x X100Ps  (pretty sure they're clones)
selintra-sail-2.1.14-347
smeserver-asterisk-1.2.10-1
smeserver-asterisk-zappri-MPP-1.2.6-1

Firstly, the cards aren't detected automatically.  I have to do:
Code: [Select]
#modprobe zaptel
#modprobe wcfxo

#lspci
04:01.0 Communication controller: Motorola Wildcard X100P
04:02.0 Communication controller: Motorola Wildcard X100P

#dmesg
Zapata Telephony Interface Registered on major 196
Zaptel Version: 1.2.7 Echo Canceller: KB1
ACPI: PCI interrupt 0000:04:01.0[A] -> GSI 17 (level, low) -> IRQ 177
wcfxo: DAA mode is 'FCC'
Found a Wildcard FXO: Wildcard X100P
ACPI: PCI interrupt 0000:04:02.0[A] -> GSI 18 (level, low) -> IRQ 201
wcfxo: DAA mode is 'FCC'
Found a Wildcard FXO: Wildcard X100P

Then when I probe for the PCI cards they're found:
Code: [Select]
Loading zaptel...

Zaptel view of card in /proc/zaptel/1
 Span 1: ZTDUMMY/1 "ZTDUMMY/1 1"
 
 

Zaptel view of card in /proc/zaptel/2
 Span 2: WCFXO/0 "Wildcard X100P Board 1"
 
    1 WCFXO/0/0 FXSKS (In use)
 

Zaptel view of card in /proc/zaptel/3
 Span 3: WCFXO/1 "Wildcard X100P Board 2"
 
    2 WCFXO/1/0 FXSKS
and the trunks are added automatically.

Firstly, should ZTDUMMY still be there?

I've now taken delivery of a couple very cheap SIP phones which I've managed to make internal calls with and they also work with sjphone.

Secondly, I can make incoming calls but only one of the modems accepts calls.  Ive swapped the modems, swapped the cables and lines but this makes no difference.

Can anyone help me with the above please?

Kind regards
NTBlade

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #1 on: November 30, 2006, 06:40:11 PM »
Quote
Firstly, the cards aren't detected automatically. I have to do:


Hi NTBlade

There is a section on our docs pages which shows how to identify your clones to the selintra database.

http://81.149.154.14/docs/cgi-bin/view/Main/DocChapter258

Once done you can use the PCI panel to identify your cards and stop/start the pbx.

Quote
Firstly, should ZTDUMMY still be there?


Ideally, no.  However, it is likely that dummy was left over from a previous PCI detect.  If no boards are detected the database is udated to load dummy at startup.  YOu can remove it by doing an initialise in PCI panel.  You can manually remove it for a particular cycle by doing

rmmod ztdummy

It's difficult to comment upon why one of the X100's isn't taking calls because we aren't sure what state SAIL is in since you have somewhat circumvented the "normal" card detect stuff.   Can we suggest you define the cards properly to the database and then load them through the PCI panel?  If you do it this way and still have problems we will be able to simulate your problem here.  As it stands we aren't 100% sure what state your system is in.

btw - what cheap SIP phones are you using?  If they aren't ones we know we can update the database for the next out.  Also, do they suppport remote provisioning?

Kind Regards

Selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #2 on: December 01, 2006, 11:36:02 AM »
> Hi NTBlade
Hi Selintra, thanks for your reply.
>
> There is a section on our docs pages which shows how to identify your clones to the selintra database.

That worked a treat.  In case this helps others, here's what I did...
Code: [Select]
# lspci -vv
04:02.0 Communication controller: Motorola Wildcard X100P
        Subsystem: Motorola: Unknown device 0000
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B-
        Status: Cap+ 66Mhz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Latency: 64 (250ns min, 32000ns max)
        Interrupt: pin A routed to IRQ 201
        Region 0: I/O ports at dc00 [size=256]
        Region 1: Memory at dfbff000 (32-bit, non-prefetchable) [size=4K]
        Capabilities: [40] Power Management version 2
                Flags: PMEClk- DSI+ D1- D2+ AuxCurrent=55mA PME(D0+,D1-,D2+,D3hot+,D3cold+)
                Status: D0 PME-Enable- DSel=0 DScale=0 PME-

I have two identical cards and from your documentation the one above is in PCI slot 2 so...
Code: [Select]
# lspci -vn
04:02.0 Class 0780: 1057:5608
        Subsystem: 1057:0000
        Flags: bus master, medium devsel, latency 64, IRQ 201
        I/O ports at dc00 [size=256]
        Memory at dfbff000 (32-bit, non-prefetchable) [size=4K]
        Capabilities: [40] Power Management version 2

I checked the Vendor and Card id on the PCI ID Repository which confirmed the card as a Motorola Wildcard X100P then I added the new database tuple like this...
Code: [Select]
# /sbin/e-smith/db selintra-work set pci:1057:5608:1057:0000 sysdev
# /sbin/e-smith/db selintra-work setprop pci:1057:5608:1057:0000 probe wcfxo zzeor EOR

I then fired up my browser and opened the server-manager, chose globals in the sail section and issued a commit.  Probing for the cards was successful but the dummy module was still there so I followed your instructions and unloaded it...
Code: [Select]
# rmmod ztdummy
and re-probed for the cards and hey presto!  Two cards recognised and no dummy!  (I think I did an activate and commit the re-probe. - it was last night I did this) I can now make and take calls on both lines.  I haven't tried both at the same time yet.  Watch this space...
Quote
btw - what cheap SIP phones are you using? If they aren't ones we know we can update the database for the next out. Also, do they suppport remote provisioning?

They are identical to theses http://www.tigernetcom.com/Products_All%20VoIP%20Phone_IPPH%20202.htm but are unbranded and have the single RJ45.  They appear to be the same as the NetComm V85 but without the buttons down the side.  There is a web interface for setup but I'm not sure about how to check if they support provisioning.  ??
The manual that comes with them on CD isn't really clear on how to use the functions but I'll just have to keep trying.  :-)

Many thanks for your help :-)
NTB

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #3 on: December 01, 2006, 12:32:31 PM »
Hi,
Is there info on minimising the echo I'm getting when making calls via PSTN?
I've tried the quite line test on BT and also *52* and the echo is very apparent.  Any pointers please?

Oh,  looks like the X100P clones are meant for the FCC/Japan market as mine have the si3012 ks DAAs  :-(  Will that make a huge diference in the UK?

Thanks again

NTB

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #4 on: December 01, 2006, 04:59:34 PM »
Quote
s there info on minimising the echo I'm getting when making calls via PSTN?


Try here

http://www.asteriskdocs.org/modules/tinycontent/content/docbook/current/docs-html/x1695.html

and here

http://www.voip-info.org/wiki/view/Asterisk+fxotune

Good start point for zapata in UK is

rxgain=8.0
txgain=-2.0
echotraining=800

You can get FXOtune and ZTMonitor from our download site here...

ftp://81.149.154.14/utilities

to fetch them in to your server use

wget ftp://81.149.154.14/utilities/fxotune
wget ftp://81.149.154.14/utilities/ztmonitor

We can also give you a fix to load fxotune parameters at asterisk start-up.

usually with a couple of hours headbanging and fiddlin' about you can get  echo down to an acceptable level but the gain settings should be done first in isolation.  Get them right (ish) and the echo canceler has less work to do.

Japanese telephony is, AFAIK, pretty much vanilla Ma Bell so you should be OK.


Kind Regards

selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #5 on: December 01, 2006, 07:35:09 PM »
Thanks.  Before trying what you've suggested I would first lke to try seting the DAA mode on the card.  I found this while googling - http://www.sigsegv.cx/sip-2.html...

Quote
Zapata sources must be compiled with the linux26 target and run under Linux 2.6 to provide echo cancellation when using the X100P card. With the MARK2 algorithm selected in the Makefile the echo cancellation is quite reasonable. It may be necessary to adjust the txlevel a bit to ensure that the people on the other side hear you OK and there is no distortion.

It is also essential to select the corect DAA mode. The card defaults to DAA mode 0 which is FCC and which does not set the line impedance and gain correctly for UK lines. This is immediately visible in dmesg: wcfxo: DAA mode is 'FCC' (correct for EU is CTR21). Note that the information on X100p clones in the VOIP Wiki is not quite correct. The newer Wildcards can be programmed for correct line parameters and setting opermode definitely makes a difference. For UK modprobe needs to be passed a "opermode=1".

Would it be worth giving this a try and then attempting the echo cancelation?
How do I pass the parameter to modprobe if the modules are already being loaded automatically?

Cheers
NTB

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #6 on: December 01, 2006, 08:34:06 PM »
Quote
Would it be worth giving this a try and then attempting the echo cancelation?

In the spirit of adventurers and shit kickers the world over - anything is worth a try - :-)
Quote
How do I pass the parameter to modprobe if the modules are already being loaded automatically?

By being fiendishly wos'name, er... clever...

Open up /etc/modprobe.conf in your favourite editor and look for the line which reads

install wcfxo /sbin/modprobe --ignore-install wcfxo  && /sbin/ztcfg

Gently replace it with

install wcfxo opermode=UK /sbin/modprobe --ignore-install wcfxo  && /sbin/ztcfg

Save it back and run...

depmod

and.... Robert's your pater's masculine sibling!

:-)

Kind Regards

Selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #7 on: December 04, 2006, 02:10:48 PM »
Thanks again,
I did...
Quote
install wcfxo opermode=UK /sbin/modprobe --ignore-install wcfxo && /sbin/ztcfg

I tried with opermode=1 and opermode=UK and I still get...
Code: [Select]
DAA mode is 'FCC'
Also...
Code: [Select]
# fxotune -i
Tuning module /dev/zap/1
Unable to set impedance on fd 4
Failure!
Tuning module /dev/zap/2
Unable to set impedance on fd 4
Failure!
/dev/zap/3 absent: No such file or directory
/dev/zap/4 absent: No such file or directory


So, it looks like my X100ps aren't suitable for UK use.

Is all lost?
NTB :cry:  :cry:

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #8 on: December 04, 2006, 03:20:01 PM »
Hi Ntb
Quote
Is all lost?

I'm afraid it doesn't look too good from here.  Short of sticking them together with superglue and advertising them to Her Majesty's Navy as an anchor, we're pretty much out of ideas on this one.  You can still set the gains correctly using the ztmonitor and you should be able to set echo training on.  It may be OK.  Doesn't hurt to give it a try.  

We've just received a shipment of AX100P's to try.  They aren't expensive so we'll let you know how we get on with them.

Kind Regards and commiserations

Selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #9 on: December 04, 2006, 03:44:40 PM »
Been looking at AX100Ps as well but no idea of what DAAs they have.
Do you know yet?

Also,  do I need to reboot / restart asterisk after setting the echocancel in /etc/asterisk/zapata.conf ?

NTBlade

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #10 on: December 04, 2006, 10:13:13 PM »
Quote
Been looking at AX100Ps as well but no idea of what DAAs they have.
Do you know yet?


Not yet - we'll let you know

Quote
Also, do I need to reboot / restart asterisk after setting the echocancel in /etc/asterisk/zapata.conf ?


Sure do.  Asterisk can load most settings by just doing a reload at the console; but not for zap.

Kind Regards

Selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #11 on: December 05, 2006, 05:17:00 PM »
Thanks for the reply again,
I'll leave the X100 config for now.  I've purchased a VOIP account from Voiptalk and an 0845 number which I've pointed to my (IAX) IP address and forwarded port 4569 to my server.  However, when I dial out the asterisk CLI gives me:
WARNING[5049]: chan_iax2.c:7075 socket_read: Call rejected by 217.14.138.49: No such context/extension

I've a feeling that maybe I've configured the trunk incorrectly.

Incoming calls seem OK apart from some echo  :?

Any ideas anyone?
Thanks
NTB

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
A couple of problems with Selintra Sail
« Reply #12 on: December 05, 2006, 10:47:26 PM »
Hi NTB

Well, the good news is you are getting to Telappliant OK.  Their IAX IP address is 217.14.138.49.  The rejection is probably occuring because you have miscoded your voiptalk password OR, as is sometimes the case with their somewhat confusing site, you have purchased an inbound ONLY 0845 number.  

If you want us to have a proper look at it then send your iax.conf file to us at admin@selintra.com.

On the inbound,you should NOT be getting echo unless you are using a softphone or low-quality handset.  Telappliant are, in our opinion, the best pre-pay supplier/carrier in the UK right now and they don't give echo(they're also mates of ours which makes us somewhat biased but still... they're pretty damn good :-))

Kind Regards

Selintra

Offline ntblade

  • *
  • 252
  • +0/-0
A couple of problems with Selintra Sail
« Reply #13 on: December 05, 2006, 11:57:53 PM »
Thanks for the help with this.
I read in another post that you were soon to offering VOIP services yourself.  Wish I'd seen it sooner.!

Anyway.  The site is mighty confusing.  Can't seem to find much.

I wasn't aware that there was an inbound only number!  WTF?

Off to bed now.  I've mailed my iax.conf.

NTB

Offline del

  • *
  • 765
  • +0/-0
A couple of problems with Selintra Sail
« Reply #14 on: December 06, 2006, 01:17:10 AM »
Hi NTB,

You should try sipgate at sipgate.co.uk, they work great with SAIL/Asterisk and you get a local STD code if you are located in the UK (they check your IP) and an 0845 number if you are outside the UK. I helped my mate in the UK to set his SAIL/Asterisk server and he has a 01905 number with them, works great and sipgate to sipgate calls are of course free. It costs nothing to give them a try. Only thing to beware of is the user name you choose is NOT the user name for setting up the trunk, this caught me out :oops:  The user name is in the email they send you.

Regards,
Del :pint:
If at first you don't succeed, then sky-diving is not for you!
"Life is like a coin. You can spend it anyway you wish, but you can only spend it once." --Author Unknown