Thursday, October 18, 2012

Update : OpenWrt on a Belkin Share Max N300 (F7D3301 or F7D7301)

Please refer to my old blog post for the details on the modifications. This is just an update from the earlier patches, and some of the content in earlier blog apply here as well.

Below are the exact steps to produce a trx file, which can be flashed via CFE.
1. Checkout openwrt (a specific version)
svn checkout --revision=33760 svn://svn.openwrt.org/openwrt/trunk
Other versions may work, but I have not tested any other version for these patches.

2.  Apply My custom patches and George's patches
    Download from here: 
000-openwrt4716-TARGET_brcm4716-clone-brcm47xx.patch
001-openwrt4716-TARGET_brcm4716.patch
002-openwrt4716-TARGET_brcm4716-deps.patch
004-f7d7301.r33760.patch


    patch -p1 < 000-openwrt4716-TARGET_brcm4716-clone-brcm47xx.patch
    patch -p1 < 001-openwrt4716-TARGET_brcm4716.patch
    patch -p1 < 002-openwrt4716-TARGET_brcm4716-deps.patch
    patch -p1 < 004-f7d7301.r33760.patch

3. make menuconfig     select Target System -> Broadcom BCM94716
     select Target Profile -> Belkin PlayMax F7D4301
     make

You will have the trx in the usual place after a successful compile.
Look for the file: bin/brcm4716/openwrt-brcm4716-f7d3301-squashfs.trx

For reference one trx I compiled is here : openwrt-brcm4716-f7d7301-squashfs-r33760.trx

Please note the below points if you flash the above trx.
1. default IP address at LAN side is 192.168.2.1
2. telnet can be accessed at default IP,
3. I have added a custom pre-init script to enable me do USB Booting. But it should not affect anything, if you dont do USB boot, except for a few more seconds boot time. I will add the details on how to do USB booting and publish the USB kernel modifications in another section.
For reference the custom preinit is here: /etc/preinit
4. For additional reference, the contents of the root file system : root-brcm4716.tar.gz

Suggestions are welcome, and I will try to learn from your suggestions. But please note that I dont have much time to spend on keeping the trx upto date with openwrt releases, or to add/delete packages or modules.


Wednesday, August 22, 2012

Yate-4.2 on Openwrt with Google Voice support

==================================
Update: August 22, 2012
Yate 4.2 is already out and so I updated the below instructions and updated the makefile. This time I also took some time to find the exact dependancies and added that in the makefile.


1. Goto your openwrt compile environment base directory.
2. mkdir package/yate4
3. Download Makefile.yate4.2 to package/yate4/Makefile
----
Note: if you dont have compiled openwrt in this directory, you might have to build the toolchain before the next step.
make tools/install
make toolchain/install
----
4. make package/yate4/compile
5. make package/yate4/install

==================================

Saturday, June 2, 2012

Yate-4.1 on Openwrt with Google Voice support

==================================

Update: August 22, 2012
Yate 4.2 is already out and so I updated the below instructions and adde a new Makefile. See the related blog on Yate 4.2 at the link below:

Yate-4.2 on Openwrt with Google Voice support


==================================
Puiblished: June 2, 2012

I had been using Yate4 for sometime and it is an excellent telephony application. As of this writing openwrt trunk only includes yate-3.2 and this limits some of the advancements in the application. I like a lot of things about yate, even though it may not be categorized as a replacement for asterisk. For a lot of folks, the excellent Google Voice support in yate, makes it a must have item in their embedded device running openwrt.

I will explain how to make yate 4.1working in openwrt. There are help pages available in openwrt for
1. how to create custom feeds
2. how to create a package
And they both explain a lot of detail on how you can achive getting custom feeds in clean way. So I am not planning to put a lot of effort on explaining those, and will focus on the core part, the makefile.

Also I will show you how to create an ipk file which you can install on your openwrt platform. The cleaner way of doing is create a custom feed and put yate4 package with the makefile in the custom feed.

Here is the makefile you can use for this purpose.
Makefile.yate

The steps to compile your own ipk is below. The pre-requisite for this is that you already have setup your openwrt compile environment, and know how to compile openwrt from source.

1. Goto your openwrt compile environment base directory.
2. mkdir package/yate
3. Download Makefile.yate to package/yate/Makefile
----
Note: if you dont have compiled openwrt in this directory, you might have to build the toolchain before the next step.
make tools/install
make toolchain/install
----
4. make package/yate/compile
5. make package/yate/install

You will have the yate4 ipk file under bin/packages
Now you can use opkg install yate4.ipk to install this package to your openwrt platform.

How to make google voice working. I was going to explain this detail here, and was documenting how I made it working. But I realized that now there is an excellent documenation in the official yate webpage.
Here is the link:  Yate4-ConnectingToGoogleVoice

Follow that link to make google voice working.

Note: For a handful of folks, who dont have an openwrt compile environment, and want to have an ipk, please post a comment with the exact router model you have (to know the cpu) and your kernel version. If I already have an ipk compatable for the model, I will share it with you. (please dont expect a reply if I dont have the ipk for you.)

Wednesday, May 16, 2012

OpenWrt on a Belkin Share Max N300 (F7D3301 or F7D7301)


Please see the update on thistopic at below link:
=====================================

=====================================


OpenWrt on a Belkin Share Max N300 (F7D3301 or F7D7301)

It was not a difficult job. Had to write a couple of patches to get it working. But a lot of work had been done by "George Kashperko" for Asus-RT-N16 . I took his patches, and applied some Belkin Specific patches.

The main modifications I made are:

1. Belkin trx headers: For some reason Belkin chose to use a custom header for trx. So modified the Makefiles to generate trx files with this custom header. Without this custom header Belkin CFE wont allow flashing the trx. And I preferred to not touch the CFE.

2. LZMA loader: Due to above modification, now I had to add some more code in the lzma decompressor and loader, to recognize the belkin headers. Without this the lzma loader will load, but wont boot, since it doest understand the new trx format.

3. Bridge setups. The virtual lan setup files needed some modification because of changes in port connections.

4. Diag and LED/GPIOs. Needed some modification to recognize the correct gpio pins and power/diag/usb leds.

Below are the exact steps to produce a trx file, which can be flashed via CFE.

1. Checkout openwrt (a specific version)
svn checkout --revision=30776 svn://svn.openwrt.org/openwrt/trunk

2.  Apply George's patches
    Download from here: 
000-openwrt4716-TARGET_brcm4716-clone-brcm47xx.patch
001-openwrt4716-TARGET_brcm4716.patch
002-openwrt4716-TARGET_brcm4716-deps.patch

    patch -p1 < 000-openwrt4716-TARGET_brcm4716-clone-brcm47xx.patch
    patch -p1 < 001-openwrt4716-TARGET_brcm4716.patch
    patch -p1 < 002-openwrt4716-TARGET_brcm4716-deps.patch

3. Apply my patch
   Download from here: 003-belkin-f7d3301.patch
   patch -p0 < 003-belkin-f7d3301.patch

4. make menuconfig
     select Target System -> Broadcom BCM94716
     select Target Profile -> Belkin PlayMax F7D4301
     make

You will have the trx in the usual place after a successful compile.
Look for the file: bin/brcm4716/openwrt-brcm4716-f7d3301-squashfs.trx

For reference one trx I compiled is here : openwrt-brcm4716-f7d7301-squashfs.trx
This is for reference ONLY. Even though I can see many users finding this good enough, I suggest you compile your own trx, when you see your needs are different. If you flash the above trx, you will have telnet access at 192.168.1.1 to your router.

You can install packages from openwrt trunk. But for that you have to addthe below lines to /etc/opkg.conf . Please dont install kernel modules from trunk snapshot, that may lead to kernel instability. But other packages should work without much issue. But as always, if something doesnt work from trunk snapshot, try compile that yourself using proper menuconfig.
#-------------
arch all 100
arch brcm4716 200
arch brcm47xx 300
#-------------

For details on opkg look here : opkg reference


Have fun...