0 Basic OPENWRT Firmware compilation

Source: Internet
Author: User
Tags lenovo

0 Basic OPENWRT Firmware compilation

Camp David Education "Internet of Things/smart Home Development" course series

1.OpenWRT Project Introduction

OpenWrt is a Linux distribution dedicated to wireless router devices. Router devices that support a multitude of chip schemes, from x86 to arm,mips and so on.

The current stable version is: BARRIER breaker (14.07)

The current development version is: Chaos Calmer (trunk)

For more information, see the official website: https://openwrt.org

2. Smart Router with OpenWrt
    • pole route
    • Xiaomi Route
    • Youku routing
    • Thunderbolt route
    • 360 safe route
    • Huawei Glory Cubic
    • Lenovo Newwifi
    • Custom routing for other commercial WiFi ads
    • ...
3. Development Board with OpenWrt
    • Wrtnode
    • Vocore
4. Get the source code for OPENWRT

We can go to the official website of the project to get its source code, via SVN or Git way, official developer site: Https://dev.openwrt.org/wiki/GetSource

Trunk (main development tree)

    • Main Repository
git clone git://git.openwrt.org/openwrt.git

14.07 Branch (Barrier breaker)-Main repository

git clone git://git.openwrt.org/14.07/openwrt.git

Of course, before we formally start compiling, we need to prepare the premise dependent environment and source code.

Open the virtual terminal and execute the following command:

[email protected]:~$  sudo apt-get install git Build-essential libncurses5-dev gawk libssl-dev subversion [Email protected]:~$  mkdir-p  $HOME /opensource [Email protected]:~$  CD   $HOME / Opensource [Email protected]:~/opensource$  git clone git://git.openwrt.org/ Openwrt.git# #上面命令会克隆远程仓库到本地, depending on the network environment, takes a longer time. 

After the source code cloning down, our source and compilation environment is basically OK.

5. OPENWRT Official firmware compilation

Go to the source directory to update and "install" the package.

[email protected]:~/opensource$  CD  openwrt [Email protected]:~/opensource/openwrt$ ./scripts/feeds update-a  [Email protected]:~/opensource/openwrt$ ./scripts/feeds Install- A  

After executing the above script, we can compile settings for the type of device we like. The following command enters the buildroot compile configuration interface under the terminal:

make menuconfig;

The CPU chip of the device we used in the tutorial is the MT7620 series (mt7620a/n), the following begins the most basic configuration for the MT7620 series of devices, the steps are as follows: 1.Target System (Atheros AR7xxx/AR9xxx) --->Enter the next turn after the space selectionRalink RT288x/RT3xxxThen return to the back, and the compile target is:Target System (Ralink RT288x/RT3xxx) --->The 2.Subtarget (RT3x5x/RT5350 based boards) --->Enter down press space to select(X) MT7620 based boardsThen enter back, and the child target of the compilation is:Subtarget (MT7620 based boards) --->The 3.LuCI --->Enter in.1. Collections --->Go back in, then. Select the first of the spaces<*> luci(new), and then go back to the main menu at exit. 4. Exit the configuration and save in the main menu exit.

That's all. The basic configuration is so simple. Below starts our life "the first" router firmware compiles, is not very tense ah? What ever. The first time you always have to go through it, you should face it positively.

We use the following command to compile the firmware:

V=s

Just such a command will open the entire build system, fully automated to compile the firmware we need. So, this process is going to be a long wait. If the Internet network is relatively smooth, then the first time we compile this will take about 2-3 hours. Because the building system needs to go to the Internet to download a variety of library source code, and then compile one by one, and finally integrate and build the firmware we need.

During this time, we can go out to the Xiangjiang River to stroll around, across the river to look at Chairman Mao, and then back to our Camp David to see the results.

After the stroll back, the compilation may end, and so on at this time, our firmware will obediently lie in the current directory under bin/ramips/ this path.

[Email Protected]:~/opensource/openwrt$ LS bin/ramips/md5sums OPENWRT-RAMIPS-MT7620-RP_N53-SQUASHFS-SYSUPGR         Ade.binopenwrt-ramips-mt7620-ai-br100-squashfs-sysupgrade.bin       Openwrt-ramips-mt7620-rt-n14u-squashfs-sysupgrade.binopenwrt-ramips-mt7620-archerc20i-squashfs-sysupgrade.bin         Openwrt-ramips-mt7620-uimage.binopenwrt-ramips-mt7620-dir-810l-squashfs-sysupgrade.bin Openwrt-ramips-mt7620-vmlinux.binopenwrt-ramips-mt7620-e1700-squashfs-factory.bin Openwrt-ramips-mt7620-vmli Nux.elfopenwrt-ramips-mt7620-e1700-squashfs-sysupgrade.bin Openwrt-ramips-mt7620-whr-1166d-squashfs-sysupgrade.        Binopenwrt-ramips-mt7620-lenovo-y1-squashfs-sysupgrade.bin        Openwrt-ramips-mt7620-whr-300hp2-squashfs-sysupgrade.binopenwrt-ramips-mt7620-lenovo-y1s-squashfs-sysupgrade.bin           Openwrt-ramips-mt7620-whr-600d-squashfs-sysupgrade.binopenwrt-ramips-mt7620-mlw221-squashfs-sysupgrade.bin openwrt-ramips-mt7620-wmr-300-squashfs-sysupgrade.bInopenwrt-ramips-mt7620-mlwg2-squashfs-sysupgrade.bin Openwrt-ramips-mt7620-wr8305rt-squashfs-sysupgrade.binope   Nwrt-ramips-mt7620-mt7620a_mt7530-squashfs-sysupgrade.bin Openwrt-ramips-mt7620-wrtnode-squashfs-sysupgrade.binopenwrt-ramips-mt7620-mt7620a_  Mt7610e-squashfs-sysupgrade.bin          Openwrt-ramips-mt7620-wt3020-8m-squashfs-factory.binopenwrt-ramips-mt7620-mt7620a-squashfs-sysupgrade.bin Openwrt-ramips-mt7620-wt3020-8m-squashfs-sysupgrade.binopenwrt-ramips-mt7620-mt7620a_    V22sg-squashfs-sysupgrade.bin        Openwrt-ramips-mt7620-xiaomi-miwifi-mini-squashfs-sysupgrade.binopenwrt-ramips-mt7620-mzk-750dhp-squashfs-sysupgrade.bin            Openwrt-ramips-mt7620-zbt-wa05-squashfs-sysupgrade.binopenwrt-ramips-mt7620-na930-squashfs-sysupgrade.bin Packagesopenwrt-ramips-mt7620-root.squashfs

At this point, the router firmware for our MT7620 series of chips has been compiled. We can choose our appropriate model of the firmware to brush the machine. Some campers get the Beijing Pea Robot Team Development Board Wrtnode corresponding firmware file is: openwrt-ramips-mt7620-wrtnode-squashfs-sysupgrade.bin Some campers get the Iron box router is a neutral packaging engineering products, although and other well-known brands in the appearance of differences, but big can not care about these differences. They all have the same configuration. The corresponding firmware file for the Iron box model WR8305RT is:openwrt-ramips-mt7620-wr8305rt-squashfs-sysupgrade.bin

The equipment picture is as follows: Wrtnode

Wr8305rt

Thank you, welcome to communicate and correct me.

----Big Tea Garden Ding @ Camp David Education

Http://io.diveinedu.com

Http://www.diveinedu.com

Https://github.com/DiveinEdu-CN

0 Basic OPENWRT Firmware compilation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.