Menu

PSTN number ending with #

Help
brian_p
2009-04-28
2013-04-30
  • brian_p

    brian_p - 2009-04-28

    I'm using the kb2kskype_0.3.8-1_i386.lenny5 package and skype-debian_2.0.0.72-1 and B2K mode is set to PSTN. When a PSTN number beginning 00 is dialed and terminated with a # the telbox switches to USB mode and the call goes through skype.

    Should I have expected this behaviour and, if so, is there any way of altering it?

    Thanks,

    Brian.

     
    • brian_p

      brian_p - 2009-04-30

      To add to my previous message:

      My understanding of the documentation is that for a unit in a default PSTN mode
      everything goes via USB after the * key is pressed, and that is indeed what
      happens. I then assumed that left in PSTN mode everything would take the PSTN
      route, which turns out not to be the case when the hash key is used to send out
      the number.

      I have a very meagre understanding of how programs are put together but by
      looking through the source code for kb2kskype I have managed to concoct a
      reason (which may or may not be correct) for the behaviour I observed.

      b2kinterface.cpp and skypeapidlg.cpp deal with sending out calls. The first
      file has a reference to the hash key. Pressing it tells kb2kskype to send the
      number to skype unless (and this is from the second file) it is

      1. Not a speed-dial number

      or

      2. The number has less than 4 digits.

      Using the --debugmessages switch confirms this.

      If the number is a speed-dial number or exceeds 4 digits in length and skype
      sees either as valid it will return a message containing 'CALL' and 'STATUS
      ROUTING'. kb2kskype detects this and switches to USB. If the number is not
      valid as far as skype is concerned the switch to USB does not happen and the
      call goes out over the PSTN.

      My problem is the LINE of the unit is connected to a SIP ATA and I want a valid
      number followed by the hash key to be sent out to the ATA, not to skype. The
      only solution I can think of is to recompile the .deb with the 4 in

      if (!str.contains(rx) || (!speedmatch && (str.length() < 4))){

      altered to something like 15.

       
    • Simon_6162

      Simon_6162 - 2009-05-01

      ok I get what you mean. I'll fix it.

      I'm away at the moment so can't make any changes till next week.  Can you post the debug window output (with numbers blanked or set to 5555) of you making a pstn call that gets sent to skype.

      Thanks

      Simon 

       
    • brian_p

      brian_p - 2009-05-01

      Here we go:

      HANDSET ON (from telbox)
      FOCUS (from telbox)
      FOCUS (sent to skype)
      OK (message from skype)
      CALL 0044800xxxxxx (from telbox)
      CALL 0044800xxxxxx (sent to skype)
      CALL 751 STATUS UNPLACED (message from skype)
      CALL 751 STATUS UNPLACED (message from skype)
      CALL 751 STATUS ROUTING (message from skype)
      Try to switch to usb from pstn
      SWITCH USB (from telbox)
      CALL 751 STATUS RINGING (message from skype)
      CALL 751 STATUS EARLYMEDIA (message from skype)
      CALL 751 VAA_INPUT_STATUS FALSE (message from skype)
      CALL 751 RATE 0 (message from skype)
      CALL 751 RATE_PRECISION 3 (message from skype)
      CALL 751 RATE_CURRENCY EUR (message from skype)
      CALL 751 STATUS INPROGRESS (message from skype)
      CALL 751 DURATION 1 (message from skype)
      CALL 751 DURATION 2 (message from skype)
      HANDSET OFF (from telbox)
      SET CALL 751 STATUS FINISHED (sent to skype)
      MINIMIZE (sent to skype)
      SWITCH PSTN (from telbox)
      CALL 751 STATUS INPROGRESS (message from skype)
      OK (message from skype)
      CALL 751 STATUS FINISHED (message from skype)

      Without your program my telbox would be gathering dust on a shelf. So many thanks for your work on it.

      Cheers,

      Brian.

       
    • brian_p

      brian_p - 2009-05-11

      I solved this by replacing

              //hash key place the call
              else if(q.contains("KEY  0c", false))

      in src/ b2kinterface.cpp

      with

              //hash key place the call
              else if(q.contains("KEY  0c", false) && (currentMode == USB))

      Is there any downside to this?

      Brian.

       

Log in to post a comment.