Archive for February 6th, 2008

My experience in installing Asterisk on WRT54GS

Wednesday, February 6th, 2008

 I followed the post on Asterisk on OpenWRT: Asterisk on OpenWRT part 2. Now, I report my process and problems here.

  • vi /etc/ipkg.conf (see updated info)
  • src whiterussian http://downloads.openwrt.org/whiterussian/packages
    src acvs http://12.176.248.4/ipkg
    dest root /
    dest ram /tmp

  • ipkg update
  • ipkg install asterisk-cvs
  • vi /etc/asterisk/modules.conf (slim modules)
  • [modules]
    autoload=yes
    noload => pbx_gtkconsole.so
    ;load => pbx_gtkconsole.so
    noload => pbx_kdeconsole.so
    noload => pbx_dundi.so
    noload => app_intercom.so
    ; load => chan_modem.so
    noload => res_musiconhold.so
    noload => chan_modem.so
    noload => cdr_pgsql.so
    noload => cdr_mysql.so
    noload => chan_alsa.so
    ;noload => chan_oss.so
    [global]
    ; chan_modem.so=yes
  • Set asterisk startup (see update info)
  • Please see below problems I got in the installationi process.
    1. When I run ipkg update, I got the following errors:

    root@OpenWrt:/etc# ipkg update
    Downloading http://openwrt.org/ipkg/Packages
    wget: openwrt.org: Unknown host
    Downloading http://12.176.248.4/ipkg/Packages
    wget: Unable to connect to remote host (12.176.248.4): Network is unreachable
    Downloading http://nthill.free.fr/openwrt/ipkg/stable/Packages
    wget: nthill.free.fr: Unknown host
    Downloading http://nthill.free.fr/openwrt/ipkg/testing/Packages
    wget: nthill.free.fr: Unknown host
    Downloading http://www.wildcatwireless.net/wrt54g/Packages
    wget: www.wildcatwireless.net: Unknown host
    An error ocurred, return value: 5.
    Collected errors:
    ipkg_download: ERROR: Command failed with return value 1: `wget –passive-ftp    -q -P /tmp/ipkg-mWFahm http://openwrt.org/ipkg/Packages’
    ipkg_download: ERROR: Command failed with return value 1: `wget –passive-ftp    -q -P /tmp/ipkg-mWFahm http://12.176.248.4/ipkg/Packages’
    ipkg_download: ERROR: Command failed with return value 1: `wget –passive-ftp    -q -P /tmp/ipkg-mWFahm http://nthill.free.fr/openwrt/ipkg/stable/Packages’
    ipkg_download: ERROR: Command failed with return value 1: `wget –passive-ftp    -q -P /tmp/ipkg-mWFahm http://nthill.free.fr/openwrt/ipkg/testing/Packages’
    ipkg_download: ERROR: Command failed with return value 1: `wget –passive-ftp    -q -P /tmp/ipkg-mWFahm http://www.wildcatwireless.net/wrt54g/Packages’
     

    Run route -n, I saw that gateway was 0.0.0.0.  I’m actually using it behind my dlink router which has LAN ip 192.168.0.1. So I changed WRT ip to 192.168.0.100 with gateway 192.168.0.1. My computer is connected to one LAN port on WRT. Another cable connect another LAN port on WRT to dlink LAN port.

    You could do it manually using the following commands or in the GUI:

    nvram set lan_ipaddr=192.168.0.100
    nvram set lan_gateway=192.168.0.1
    nvram set lan_dns=192.168.0.1
    where 192.168.0.1 is your gateway address
    if you use WAN connection, use the same command with  wan_gateway and wan_dns

    Then when I run “ipkg install asterisk-cvs” to install asterisk, I got an error “src openwrt http://openwrt.org/ipkg is unreachable”. But it seems asterisk was installed properly.

    2. When I run asterisk, I got the same problem as in the comment of the post:

    asterisk: can’t load library ‘libgcc_s.so.1′

    and

    asterisk: can’t load library ‘libssl.so.0.9.7′

    ln -s /usr/lib/libssl.so.0.9.8 /usr/lib/libssl.so.0.9.7

    and

    ln -s /lib/libc.so.0 /lib/libgcc_s.so.1

    This solved the problems.

    3. When I try to register user 3000 on asterisk server, I got an error message: Username/auth name mismatch.

    In sip.conf, host = dynamic instead of host = xx.xx.xx.xx solved the problem.

    4. Unable to connect to remote asterisk, can’t access to CLI with asterisk -r

    Receiving the following error message:
    Unable to connect to remote asterisk (does /var/run/asterisk.ctl exist?)

    /var/run/asterisk.ctl does exist and asterisk is running.

     The problem was:

    Edit your asterisk.conf file: /etc/asterisk/asterisk.conf

     then add these lines to it or just uncomment them if already exist.

     [files]
    astctlpermissions = 0660
    astctlowner = asterisk
    astctlgroup = pbx
    astctl = asterisk.ctl

    5. For the voicestick registering problem, I followed the post: http://www.asteriskextras.com/index.php?option=com_content&task=view&id=13&Itemid=2I will copy the post later.Comment by alen — February 4, 2007 @ 1:38 am | Edit This

    Problems continued:

    6. pap2 couldn’t register
    nat = yes
    problem solved.
    5. 503: service unavailabe
    I have sip.conf:[3000]
    type = friend
    context = default
    username = 3000
    host = dynamic
    mailbox = 3000
    dtmfmode = rfc2833
    nat = yes

     

    and

    [3001]
    type = friend
    context = default
    username = 3001
    host = dynamic
    mailbox = 3001
    dtmfmode = rfc2833
    nat = yes

    extension.conf:

    [internal]
    exten => 3000,1,Dial(SIP/3000,30,Ttm)
    exten => 3000,2,Playback(invalid)
    exten => 3000,3,Hangup
    exten => 3001,1,Dial(SIP/3001,30,Ttm)
    exten => 3001,2,Playback(invalid)
    exten => 3001,3,Hangup

    Result:
    3000 is fine.
    3001, I got 503: service unavailable

    Don’t know why. 

    Update:

    http://zandbelt.dyndns.org/asterisk.html

    asterisk for whiterussian has been taken down. Asterisk for OpenWRT is now obsolete.

    Kamikaze is now the official OpenWRT stable version. But it’m not sure if Kamikaze has a version for wrt54gs v1.0 v2.0 2.1.

    In the links in http://lestblood.imagodirt.net/archives/106-Asterisk-on-OpenWRT-part-2.html, only http://12.176.248.4/ipkg is still available.

    I put the following in the /etc/ipkg.conf:

    src libncurses http://download2.berlios.de/pub/xwrt/packages
    src acvs http://12.176.248.4/ipkg
    dest root /
    dest ram /tmp

    It seems it works. Or use the openwrt download links.

    src whiterussian http://downloads.openwrt.org/whiterussian/packages
    src non-free http://downloads.openwrt.org/whiterussian/packages/non-free
    src acvs http://12.176.248.4/ipkg
    dest root /
    dest ram /tmp

    Start Asterisk automatically at startup

    Add a simulink /etc/init.d/S60asterisk to asterisk

    ln -s asterisk S60asterisk 

    Then  put the following content in /etc/default/asterisk.

    vi /etc/default/asterisk:

    ## startup options for /etc/init.d/asterisk

    ENABLE_ASTERISK=”yes”
    OPTIONS=”"

    I checked later. It seems that if I make a simulink S99asterisk, it’ll work without vi /etc/default/asterisk: ln -s asterisk S60asterisk .

    For authenticate methods, please check here: http://blog.nyworldphone.com/2008/02/06/how-to-authenticate-users-by-callerid/.

    Sphere: Related Content

    Google Maps with My Location (beta)

    Wednesday, February 6th, 2008
    See your location on the map, with or without GPS. Save time and tedious keystrokes finding where you are, what's around you, and how to get there. Watch the video on the right to see how it works.

    Press “0″ and look for the blue dot: or

    If you have a GPS-enabled device, this blue dot corresponds to your GPS location. At times, or if you do not have a GPS-enabled phone, you might see the blue dot surrounded by a light blue circle (as shown on the right) to indicate uncertainty about your location.

    Why the uncertainty? The My Location feature takes information broadcast from mobile towers near you to approximate your current location on the map - it's not GPS, but it comes pretty close (approximately 1000m close, on average). We're still in beta, but we're excited to launch this feature and are constantly working to improve our coverage and accuracy.

    The My Location feature is available for most web-enabled mobile phones, including Java, BlackBerry, Windows Mobile, and Nokia/Symbian devices.

    Get more info on the My Location feature and supported devices, or discuss Google Maps and My Location with other users.

     
     

    source: http://www.google.com/gmm/mylocation.html?hl=en

    Sphere: Related Content

    Barablu: GTalk, Skype Users Talk Via WiFi VoIP

    Wednesday, February 6th, 2008

    Product Website

    AGEphone SoftPhone for mobile

    Wednesday, February 6th, 2008

    AGEphone is a software that allows you to make and receive telephone calls from your PC or Smartphone just like from a normal telephone.

    AGEphone offers great sound quality and a lot of features that come in handy, like importing your address book from Outlook, a speed dial function, an answering machine, call melodies, simultaneous use of multiple services and many more.

    download

    Sphere: Related Content

    Unlock the Motorola VT1000 ATA

    Wednesday, February 6th, 2008

    Link here

    Use serial port to do unlocking.

    How to read and write chinese on your WM5?

    Wednesday, February 6th, 2008

    How to read chinese on your WM5, without installing cestar/monster etc

    fontpatch for wm5: enable wm2005 to read chinese sms

    http://www.ppcsg.com/index.php?showtopic=67386&view=findpost&p=443007

    Loading Fonts from Storage space and not from RAM

    Chinese input

    Display Chinese unicode as well as BIG5, GB1232 etc

    Asus T9 Pinyin + Chinese font

    无敌快手IME版for WM5

    无敌快手IME版for wm2003

    Chinese font tweak

    Adding regional language in WM5

    PinYinIME

    spzhcn

    Dopod

    Sphere: Related Content

    Mobile Registry Editor

    Wednesday, February 6th, 2008

    PHM Registry Editor 0.70

    Mobile Registry Editor v1.11 (from PC)

    Links for PDA/PPC/SmartPhone

    Wednesday, February 6th, 2008

    http://www.ppcsg.com/index.php?showtopic=21507

    http://www.ppcsg.com/index.php?showtopic=58972

    http://www.ppcsg.com/index.php?showtopic=21507&st=60&p=307288&#entry307288

    http://www.ppcsg.com/index.php?showtopic=58687

    Sphere: Related Content

    Install Chinese or other regional Font in WM5

    Wednesday, February 6th, 2008

    Finally, I managed to install Chinese font in my Tmobile SDA smartphone with WM5.

    One I also succeeded is Chinese font tweak. But when I installed it, all the english fonts looked like SBC Case(widely separated). So I removed it. Finally, I succeeded with this post: http://www.airfagev.com/howtos_details.asp?id=77. But I changed something.

    I used the Unicode font file sunglobe.ttf from this post: http://forum.xda-developers.com/showthread.php?t=253867 or this one: http://www.ppcsg.com/index.php?showtopic=67386 instead of the SimSun.ttf (which is 10M). Actually, the font file from Chinese font tweak is pretty small, much smaller than sunglobe and worked. So maybe it’s better to change it to that considering the space. But I didn’t try it.

    Here is what I’ve done with this method, basically following the original post, followed by problems.

      1. Locate segoe.ttf & segoeb.ttf from your \Windows directory of WM5.0,
      2. copy the 2 files to \Windows\Fonts directory of the WM5.0
      3. Download the sunglobe.zip from the link above, unzip it and copy the ttf font file to \Windows\Fonts directory of the WM5.0
      4. Edit your WM5.0 registry with the following[HKEY_LOCAL_MACHINE\Software\Microsoft\FontPath]
      “FontPath”=”\\windows\\Fonts“[HKEY_LOCAL_MACHINE\Software\Microsoft\FontLink\SystemLink]
      “Segoe Condensed”=”\\windows\\Fonts\\sunglobe.ttf,UniSun

      [HKEY_LOCAL_MACHINE\System\GDI]
      “FontLinkMethods”=dword:00000001

      [HKEY_LOCAL_MACHINE\System\GDI\SYSFNT]
      “Nm”=”UniSun”

      5. Note: sunglobe.ttf is a chinese font, you may wanna replace it with another regional font. UniSun is the actual font name for sunglobe.ttf, therefore remember to rename the value in Step 4 Nm=FontName

    Result and problems:

    Now I have most english words are still good, working the same as before. File manager reads Chinese names, PIE and skype show Chinese words too. I don’t receive any Chinese SMS for a long time. But I believe it should be fine.

    But the titles showing on the top of the screen become bigger, like Chinese font treak did. Chinese TXT file can’t be read. Before I installed it, a file name in Chinese was shown as boxes. Different from that, the content in a txt file is shown like with a wrong encoding.

    I wonder how I can make it work properly totally. If I need/want to install another regional font, what should I do?

    Alen

    5 Comments »

    1. Thanks for the info. To fix the strange looking titles, change:
      [HKEY_LOCAL_MACHINE\System\GDI\SYSFNT]
      “Nm”=”UniSun”

      To

      “Nm”=”Segoe Condensed”

      Cheers,

      Comment by Yi — October 26, 2007 @ 3:17 am

    2. Thanks. works perfect.

      Comment by alen — October 26, 2007 @ 4:08 am

    3. Why waste space by copying segoe.ttf & segoeb.ttf from the windows folder to the fonts folder? Why not just copy your new font to the \windows folder and set
      “Segoe Condensed”=”\\windows\\sunglobe.ttf,UniSun“

      Also, I didn’t mess with the SYSFNT. Is it really needed if you don’t want to change your english text?

      Comment by badbob001 — November 18, 2007 @ 9:50 pm

    4. I followed the post I mentioned. Maybe you could try it and report it. Thanks.

      Comment by alen — November 19, 2007 @ 2:45 pm

    5. @badbod001, By the way, maybe you could also just try the way in this post: http://www.ppcsg.com/index.php?showtopic=67386. It’s like something you said.

      Comment by alen — November 19, 2007 @ 2:52 pm

    Sphere: Related Content

    GO-SIP SoftPhone Sip Client for Mobile

    Wednesday, February 6th, 2008

    http://www.go-sip.com/guides/images/smart/splash.png
    Finally I found a perfect sip softphone for my SDA.
    Compared to the following softphones, go-sip has a lot of advantages for my SDA and actually works.

    GO-SIP(from Peer2Phone): The required space and memory is acceptable. It works with my SDA seamlessly perfectly. I can use all features of it. I though it was in french because the guide on the website is in French. After I installed it, I see everything in English which is good for me. When we are tring to download, we need pick a brand or operator and device reference. I picked Tmobile as it’s operator. I don’t see the SDA in the device reference, so I picked any one with HTC. I turns out it doesn’t matter. We need also put in a voip operator like Bewip. It turns out that we could set it for any service provider. To use it for other providers, I need choose “other” as the operator to activate it when I start it. (I chose manually, but it didn’t go through.)

    After it’s activated, it runs. Then we need configure the settings for other service providers. I need restart it before it actually registers on my sip server.

    After installation, it’ll be put in the startup. If you don’t want it to run automatically when you restart your phone, you can remove it from startup.

    Besides voip calls, in the menu, there are some other features like my email, TV, maps, music etc.

    On it’s website, it states “Telephone and multimedia free of charge unlimited 24 hours a day and 7 days a week !”. So it’s free. I made a test call, the sound seemed good. I’ll use it for longer and see how it goes.

    Compared to Go-Sip, here are other softphones I tried.

    BeWip: 1. Evaluation version. 2. Complicated installation. 3. Taking much space. 4. Limited specific service providers.
    Actually, I didn’t make it work although I succeeded to install it.

    SpeaQ: It’s for PDA although it can run on some smartphones. It’s very small which is good.
    I installed it and registered it to my sip server, but I can’t press any buttons to make calls. And there are some other problems. If I go to home screen, SpeaQ will shutdown. Once I put in the settings, I can’t change it in the settings, instead I have to change the sipconfig.txt file.

    Kapanga Softphone: It works with my SDA with some disadvantages as follows. It’s comparatively large. It put a lot of stuff in my phone, and takes much memory to run. I got some problems when I used it. I have to change the txt file if I need do any settings. Setting is a little complicated because there are a lot of pamarameters. The software main window doesn’t fit my screen perfectly. Maybe there’s a value to set the position of the window. I can’t go to home screen. To do that, the only way is to quit.

    ESCSoftPhone: It’s IAX client and worked on my SDA. But what I used is demo version and expired very soon. Otherwise it’s not free. It’s very tight. Actually I’ll like it without considering money.

    Sphere: Related Content