Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
toh:huawei:hg622 [2019/02/16 00:03] – [Huawei EchoLife HG622] willytoh:huawei:hg622 [2023/05/21 16:58] – fix links danitool
Line 4: Line 4:
 {{section>meta:infobox:broadcom_dsl#infobox_for_dataentries&noheader&nofooter&noeditbutton}} {{section>meta:infobox:broadcom_dsl#infobox_for_dataentries&noheader&nofooter&noeditbutton}}
  
-The HG622 is an adsl wifi router mainly distributed by [[wp>Jazztel]] to their customers.+The HG622 is an ADSL wifi router mainly distributed by [[wp>Jazztel]] to their customers. 
 + 
 +{{:media:huawei:hg622:hg622.png|}}
  
-{{:media:huawei:hg622.png?|}} 
  
-:!: It's a good idea to backup the cal_data area at the flash-chip. The WLAN calibration data is specific for your device.  If you wipe it accidentally it will be difficult to restore, it cannot be restored by flashing back a vendor firmware. A serial to TTL converter is needed to obtain the cal_data area at the flash-chip. A procedure is under construction. 
 ===== Supported Versions ===== ===== Supported Versions =====
 ---- datatable ---- ---- datatable ----
-cols    : Brand, Model, Versions, Supported Current Rel, OEM device homepage URL_url, OWrt Forum Topic URL_url, Device Techdata_pageid +cols    : Brand, Model, Supported Since Rel, Supported Current Rel, Forum search_search-forums, Device Techdata_pageid 
-headers : Brand, Model, Version, Current Release, OEM Info, Forum Topic, Technical Data+headers : Brand, Model, Supported Since, Current Release, Forum Search, Technical Data
 align   : c,c,c,c,c,c,c align   : c,c,c,c,c,c,c
 filter  : Model=HG622 filter  : Model=HG622
Line 40: Line 40:
 ---- ----
  
--[[docs:guide-user:installation:generic.flashing|Install OpenWrt (generic explanation)]]+<WRAP center round important 60%> 
 +**Warning**The **cal_data** partition got corrupted/erased after installing **17.01.6, 18.06.1 or 18.06.2 versions**, leaving the wifi not usable for any firmware unless you restore again this partition. See [[#backup_and_restore_wifi_calibration_data|instructions below]] how to backup and restore the cal_data partition.
  
 +**BUG fixed** in this commit -> [[https://git.openwrt.org/?p=openwrt/openwrt.git;a=commitdiff;h=4b633affff972bf19|brcm63xx: drop linux,part-probe usage where possible]]. 
  
-[[#serial|serial]] (UARTadapter is required to install OpenWrt+**17.01.4 < <color red>Stable versions with the //cal_data// bug</color> < 18.06.4** 
 +</WRAP> 
 + 
 + 
 +==== Old firmwares ==== 
 +These firmwares were fully tested, and they're known to work 100% ok. 
 + 
 +^ Version ^ Release date ^ firmware link ^ Notes ^ kernel ^ Tested ^ 
 +| **LEDE Reboot 17.01.4 r3560** | 2017 Oct | http://downloads.lede-project.org/releases/17.01.4/targets/brcm63xx/generic/ | LuCI included, USB and wireless drivers included, Based on OpenWrt. cal_data partition must be restored from previous backup. | 4.4.92 |  ✔  | 
 + 
 +-> [[docs:guide-user:installation:generic.flashing|Install OpenWrt (generic explanation)]]
  
  
 ==== OEM installation using the TFTP method ==== ==== OEM installation using the TFTP method ====
  
-For installing the Openwrt firmware you will need to use the CFE serial console:+For installing the OpenWrt firmware you will need to use the CFE serial console:
   * Connect a [[docs:techref:hardware:port.serial|serial]] TTL cable to send commands to CFE via serial console software, for loading the firmware via TFTP.   * Connect a [[docs:techref:hardware:port.serial|serial]] TTL cable to send commands to CFE via serial console software, for loading the firmware via TFTP.
   * Start a TFTP server in your PC. Copy the //**firmware.bin**// file to the TFTP server's directory.   * Start a TFTP server in your PC. Copy the //**firmware.bin**// file to the TFTP server's directory.
-  * Set the IP at your pc to 192.168.1.35 (or any compatible), and connect the ethernet cable to the router. +  * Set the IP at your PC to 192.168.1.35 (or any compatible), and connect the ethernet cable to the router. 
-  * Power ON the router, press any key in the serial console to break into the CFE command line interpreter.+  * Press the reset button (**very important**), and power ON the router while continue pressing the reset button till you see the CFE command line interpreter. It seems that if the reset button is not pressed, the integrated TFTP client does not activate.
   * Execute the command: ''f 192.168.1.35:firmware.bin''   * Execute the command: ''f 192.168.1.35:firmware.bin''
 This is a session of flashing via TFTP: This is a session of flashing via TFTP:
Line 67: Line 79:
 </code> </code>
  
-=== CFE upgrade === +You may have to try several times, because the time window the TFTP client has to connect to the TFTP server is very short.
-If you want to have a web server for easy flashing you can upgrade the bootloader with a new modded one+
  
-<WRAP center round download 60%> 
-[[https://drive.google.com/uc?export=download&id=0B-EMoBe-_OdBX1MtTjMyWXBjbXM|CFE_HG622-dummy_firmware.bin]] (dummy firmware, only CFE and void firmware) 
- 
-</WRAP> 
- 
-Use the same procedure, as described above. This is a session of upgrading the bootloader 
-<WRAP bootlog> 
-<nowiki>CFE version 1.0.37-102.6 for BCM96368 (32bit,SP,BE) 
-Build Date: Sun Jul 24 16:58:20 CST 2011 (wangxinfeng@build.huawei.com) 
-Copyright (C) 2000-2008 Broadcom Corporation. 
- 
-Parallel flash device: name AM29LV320MT, id 0x2201, size 16384KB 
-CPU type 0x2A031: 400MHz, Bus: 160MHz, Ref: 64MHz 
-CPU running TP0 
-Total memory: 33554432 bytes (32MB) 
-Boot Address 0xb8000000 
- 
- 
-Board IP address                  : 192.168.1.1:ffffff00 
-Host IP address                   : 192.168.1.100 
-Gateway IP address                : 
-Run from flash/host (f/h)         : f 
-Default host run file name        : vmlinux 
-Default host flash file name      : bcm963xx_fs_kernel 
-Boot delay (0-9 seconds)          : 3 
-Boot image (0=latest, 1=previous) : 0 
-Board Id (0-5)                    : 96368MVWG_hg622 
-Number of MAC Addresses (1-32)    : 11 
-Base MAC Address                  : 00:e0:fc:09:09:09 
-PSI Size (1-64) KBytes            : 64 
-Main Thread Number [0|1]          : 0 
- 
-*** Press any key to stop auto run (3 seconds) *** 
-Auto run second count down: 1 
-web info: Waiting for connection on socket 0. 
-CFE> 
-CFE> f 192.168.1.100:CFW_HG622-dummy_firmware.bin 
-Loading 192.168.1.100:CFE_HG622-dummy_firmware.bin ... 
-Finished loading 87360 bytes 
- 
-Flashing CFE: .. 
- 
-readNvramData() CRC ERROR !!!!!! 
- 
-writeNvramData   write ..... 
- 
-Flashing root file system and kernel at 0xb8020000: .. 
- 
- 
-Clear Flags ok! 
-. 
-*** Image flash done *** ! 
- 
-CFE timeout,reboot 
- 
-Resetting board... 
- 
-CFE version 2.0.3 for BCM63XX (32bit,SP,BE) 
-Build Date: Tue Dec 15 18:07:41 CET 2015 (dani@tool) 
-Copyright (C) 2000-2009 Broadcom Corporation. 
- 
-Parallel flash device: name AM29LV320MT, id 0x2201 size 16384KB 
-Total Flash size: 16384K with 128 sectors 
-Chip ID: BCM6368B2, MIPS: 400MHz 
-Main Thread: TP0 
-Total Memory: 33554432 bytes (32MB) 
-Boot Address: 0xb8000000 
- 
-*** Upgrading NVRAM (version 5 to version 6) *** 
- 
-Board IP address                  : 192.168.1.1:ffffff00 
-Host IP address                   : 192.168.1.100 
-Gateway IP address                : 
-Run from flash/host (f/h)         : f 
-Default host run file name        : vmlinux 
-Default host flash file name      : bcm963xx_fs_kernel 
-Boot delay (0-9 seconds)          : 3 
-Board Id (0-15)                   : 96368MVWG_hg622 
-Number of MAC Addresses (1-32)    : 11 
-Base MAC Address                  : 00:e0:fc:09:09:09 
-PSI Size (1-64) KBytes            : 64 
-Enable Backup PSI [0|1]           : 0 
-System Log Size (0-256) KBytes    : 0 
-Main Thread Number [0|1]          : 0 
-Voice Board Configuration (0-19)  : 
- 
-*** Press any key to stop auto run (3 seconds) *** 
-Auto run second count down: 0 
-Booting from only image (0xb8020000) ... 
-Code Address: 0x00000000, Entry Address: 0x00000000 
-Failed to decompress image.  Corrupted image? 
-web info: Waiting for connection on socket 0. 
-web info: Waiting for connection on socket 1. 
-web info: Waiting for connection on socket 2. 
-web info: Waiting for connection on socket 0. 
-web info: Waiting for connection on socket 1. 
-web info: Waiting for connection on socket 3. 
-web warning: Unexpected TCP disconnect. 
-web warning: Unexpected TCP disconnect. 
-web warning: Unexpected TCP disconnect. 
-web info: Waiting for connection on socket 0. 
-web info: Upload 4587524 bytes, Broadcom image format. 
-CFE> 
- 
-</nowiki> 
-</WRAP>\\ 
-After CFE upgrade you will have a web server at ''%%http://192.168.1.1/%%'' for upgrading new firmwares. No need anymore the serial console, just press the reset button when powering on the router and wait for accesing the CFE webserver flashing interface. 
  
 ==== Flash Layout ==== ==== Flash Layout ====
Line 220: Line 124:
  
 How to connect to the Serial Port of this specific device: How to connect to the Serial Port of this specific device:
-^ J4  + 
-| TX  +^ J4    
-| GND | +| TX    
-| VCC | +| GND   
-| nc  +| VCC   
-| RX  |+| nc    
 +| RX    | 
 Serial works at 3.3V 115200N1, see pin assignments above Serial works at 3.3V 115200N1, see pin assignments above
 |<code>Speed (baud)     - 115200 |<code>Speed (baud)     - 115200
Line 232: Line 138:
 Parity           - None Parity           - None
 Flow control     - None</code>| Flow control     - None</code>|
- 
- 
  
  
Line 243: Line 147:
 {{media:huawei:hg622_jtag.jpg?direct&300|}} {{media:huawei:hg622_jtag.jpg?direct&300|}}
  
-^ J5 ^ +<a2s> 
-| TDI  +         #-----+-----# 
-| TMS  +      TX | #-# | .-. | TDI 
-| TDO  +         | #-# | '-' 
-| TRST | +         |         | 
-| TCK  |+     GND | .-. | .-. | TMS 
 +         | '-' | '-' 
 +         |         | 
 +     VCC | .-. | .-. | TDO 
 +         | '-' | '-' 
 +         |         | 
 +      NC | .-. | .-. | TRST 
 +         | '-' | '-' 
 +         |         | 
 +      RX | .-. | .-. | TCK 
 +         '-' | '-'
 +         #-----+-----# 
 +           J4     J5  
 +</a2s> 
  
 === URJTAG === === URJTAG ===
Line 289: Line 207:
  
 You can use a different JTAG cable, only the first line will be different You can use a different JTAG cable, only the first line will be different
 +
 ^ JTAG adapter ^ command ^ ^ JTAG adapter ^ command ^
 | Altera USB Blaster adapter | <code>cable usbblaster</code> | Altera USB Blaster adapter | <code>cable usbblaster</code>
 | [[docs:techref:hardware:port.jtag.cable.buffered|WIGGLER parallel port adapter]] | <code>cable wiggler ppdev /dev/parport0</code> | | [[docs:techref:hardware:port.jtag.cable.buffered|WIGGLER parallel port adapter]] | <code>cable wiggler ppdev /dev/parport0</code> |
-| [[docs:techref:hardware:port.jtag.cable.unbuffered|DLC5 parallel port adapter]]| <code>cable dlc5 ppdev /dev/parport0</code> |+| [[docs:techref:hardware:port.jtag.cable.unbuffered|DLC5 parallel port adapter]]  | <code>cable dlc5 ppdev /dev/parport0</code> |
  
  
Line 322: Line 241:
  
  
-===== Bootloader mods =====+===== Backup and restore Wifi calibration data ===== 
 +In theory each wifi chip (it doesn't matter if they are exactly the same model) has its own wifi calibration data. In this router the data is stored in an area of the flash chip. This area is the cal_data partiton in OpenWrt firmwares.
  
 +  * Without the cal_data, wifi will not work
 +  * The WLAN calibration data is specific for your device, i.e. cal_data from another device will most likely not work
 +  * If you wipe it accidentially it will be difficult to restore
 +  * It cannot be restored by flashing back a vendor firmware
 +
 +-> It's a good idea to backup this partition **before** flashing OpenWrt.
 +
 +
 +==== Backup cal_data partition ====
 +A serial to TTL converter is needed to access the router's CFE console, once connected, we turn on the router and we have three seconds to press the space bar to stop the boot and access the CFE command line. The command line will only be available for a few seconds, the router restarts automatically if we do not enter commands or take a long time to write them, so we have to be very quick to execute the commands. It is best to write the commands that we will use in a text editor, copy them and then simply paste them on the command line by pressing the right mouse button. Do not use ctrl + v.
 +
 +What we need is to save the information that contains the partition cal_data, but the command "save" is not available, so we will have to use the command "dm" (dump). In this router the cal_data partition has a size of 20000 starting at the pointer B8FA0000 and the command to use would be like this:
 +<code>dm B8FA0000 20000</code>
 +But there are only valid data from 0 to 200, so we would use this one:
 +<code>dm B8FA0000 200</code>
 +With the execution of this command we will obtain a console dump.
 +The content of the cal_data partition is something like this:
 +<code>b8fa0000: 62 30 01 00 ac e8 7b 30 ef b4 62 30 14 18 01 80    b0....{0..b0....
 +b8fa0010: 00 00 62 30 14 18 00 00 01 00 6a ff 0c 00 ff ff    ..b0......j.....
 +b8fa0020: ff ff ff ff b0 92 ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0030: ff ff ff ff 22 08 24 00 ff ff 2d 01 ff ff d9 fa    ....".$...-.....
 +b8fa0040: cc 88 ff ff 0d ff 00 00 03 00 00 00 00 00 ff ff    ................
 +b8fa0050: ff ff 11 11 10 10 0f 0f 0e 0e 0d 0d 0c 0c 0c 0c    ................
 +b8fa0060: 09 09 08 08 07 07 07 07 08 08 08 08 08 08 ff ff    ................
 +b8fa0070: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0090: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa00a0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa00b0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa00c0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa00d0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff 55 55    ..............UU
 +b8fa00e0: 88 88 77 77 66 66 66 66 66 66 66 66 66 66 66 66    ..wwffffffffffff
 +b8fa00f0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0110: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0120: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0130: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0140: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0150: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0160: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0170: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0180: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa0190: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01a0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01b0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01c0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01d0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01e0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff    ................
 +b8fa01f0: ff ff ff ff ff ff ff ff ff ff ff ff ff 06 86 93    ................
 +</code>
 +
 +We select the text in the console, copy it and paste it in a text editor, then open a hex editor and copy and paste only the hexadecimal part of each of the lines, until we have in the hex editor the same as in the dump. It just takes a little patience. Do it so because when you paste the text of the console in the hex editor, you also copy the memory pointers and the ascii part, so the final result is not valid. Now we just need to save the file, for example cal_data_hg622.bin. There is an easy way below.
 +
 +Now we install OpenWrt, and once installed, we copy the file with the calibration data to the router. To do so we use WinSCP, we will copy the file cal_data_hg622.bin to the folder "/etc" in the router and we will have it available to restore the calibration data.
 +The problem is that the partitions are protected and can not be modified, to do so we will have to install the **kmod-mtd-rw** module, which allows us to modify the partitions if we execute the command ''insmod mtd-rw i_want_a_brick=1''.
 +<WRAP center round download 60%>
 +If you lost your calibration data, here is the cal_data partition for this model:
 +{{:media:huawei:hg622:cal_data_hg622.rar|}}
 +</WRAP>
 +==== Restore cal_data partition ====
 +If you have already lost the calibration data, download {{:media:huawei:hg622:cal_data_hg622.rar|}} and follow these instructions:
 +
 +First of all, transfer the cal_data_hg622.bin file into your router with WinSCP to "/etc" folder.
 +
 +The router has to have [[#Basic_internet_configuration|access to the internet]], then we access the router by SSH and execute
 +<code>opkg update
 +opkg install kmod-mtd-rw</code>
 +With this we install the necessary module to unprotect the partitions, then execute
 +<code>insmod mtd-rw i_want_a_brick=1</code>
 +We can now modify the data of the partition cal_data.
 +
 +**Optional**: If you have installed the snapshot version, it will be useful to have Luci
 +<code>opkg install luci</code>
 +Then we check the partition mtd(x) that contains the calibration data by executing:
 +<code>root@OpenWrt:~#cat /proc/mtd
 +dev:    size   erasesize  name
 +mtd0: 00020000 00020000 "CFE"
 +mtd1: 00f80000 00020000 "linux"
 +mtd2: 001a56a8 00020000 "kernel"
 +mtd3: 00dda858 00020000 "rootfs"
 +mtd4: 00bc0000 00020000 "rootfs_data"
 +mtd5: 00020000 00020000 "cal_data"
 +mtd6: 00020000 00020000 "nvram"</code>
 +And finally
 +<code>dd if=/etc/cal_data_hg622.bin of=/dev/mtd5  *File names are case sensitive</code>
 +  * **Restart** OpenWrt and check if wifi works.
 +
 +  * Other considerations:
 +The MAC is in the first line, in this example it is "ac e8 7b 30 ef b4", but it is not the same as in the sticker, the last two characters are different "ac e8 7b 30 ef ac". Anyway if we start the router before making the modifications connected by serial port, we can find the line "Main bssid = ac: e8: 7b: 30: ef: b4", which as we see informs us of the MAC that appears in the calibration data. Now we just have to edit the file with hex editor and put the MAC of our router, and then follow the whole procedure.
 +
 +If you accidentially erased your cal_data partition and you didn't make your own backup, you can use the above data to fill the erased partition (note the MAC address is specific for each calibration data). Or try this:
 +  * Generate a bin file with the cal_data. You don't need to do this step if you already have your own backup. Make it at your PC with a **linux** distro:<code>echo '62300100ACE87B30EFB4623014180180000062301418000001006AFF0C00FFFFFFFFFFFFB092FFFFFFFFFFFFFFFFFFFFFFFFFFFF22082400FFFF2D01FFFFD9FACC88FFFF0DFF0000030000000000FFFFFFFF111110100F0F0E0E0D0D0C0C0C0C0909080807070707080808080808FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF555588887777666666666666666666666666FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF068693' | xxd -r -p > cal_data_hg622.bin</code>
 +  * Also, if you don't have a **linux** distro, copy the next content in a hex editor:<code>62300100ACE87B30EFB4623014180180000062301418000001006AFF0C00FFFFFFFFFFFFB092FFFFFFFFFFFFFFFFFFFFFFFFFFFF22082400FFFF2D01FFFFD9FACC88FFFF0DFF0000030000000000FFFFFFFF111110100F0F0E0E0D0D0C0C0C0C0909080807070707080808080808FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF555588887777666666666666666666666666FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF068693</code>
 +
 +  * Now transfer the **cal_data_hg622.bin** file into your router and flash the **cal_data** partition<code>mtd write /etc/cal_data_hg622.bin cal_data</code> or <code>dd if=/etc/cal_data_hg622.bin of=/dev/mtd5  *File names are case sensitive</code>
 +  * **Restart** OpenWrt and check if wifi works.
 +
 +==== Basic internet configuration ====
 +You can set a basic internet configuration with uci commands. Assuming your main router (gateway) has the IP 192.168.1.1 (the most common). Follow these steps.
 +
 +  - Connect only the ethernet cable from the HG622 to your computer, and telnet it or ssh.
 +  - Execute these commands <code>uci set network.lan.ipaddr=192.168.1.254
 +uci set network.lan.netmask=255.255.255.0
 +uci set network.lan.gateway=192.168.1.1
 +uci set network.lan.dns='8.8.8.8 192.168.1.1'
 +uci commit network</code>
 +  - You may also need to disable the dhcp server <code>/etc/init.d/dnsmasq disable</code>
 +  - Reboot the HG622 and connect the ethernet cable to the main router (gateway).
 +  - Now the HG622 IP is 192.168.1.254, telnet or ssh it.
 +  - Ping any internet address, or install a package <code>opkg update
 +opkg install luci</code>
 +
 +
 +===== Bootloader mods =====
  
 ^ bootloader ^ download link ^ description ^ ^ bootloader ^ download link ^ description ^
-| CFE | [[https://drive.google.com/uc?export=download&id=0B-EMoBe-_OdBZ25Pdi1PU0ZweTA|CFE-HG622-CUSTOM.bin]]| moded bootloader: web interface added, reset button detect for stopping the bootloader, no double image, no rootfs CRC check |+| CFE | [[https://drive.google.com/uc?export=download&id=1bh67A4yjtGy2kTaa7hVKcNS8r876ylgf|CFE-HG622-CUSTOM.bin]]| moded bootloader: web interface added, reset button detect for stopping the bootloader, no double image, no rootfs CRC check | 
 + 
 +==== CFE upgrade ==== 
 +If you want to have a web server for easy flashing you can upgrade the bootloader with a new modded one. 
 + 
 +<WRAP center round download 60%> 
 +[[https://drive.google.com/uc?export=download&id=17sx3piiqlSo584fOJJXWWZjKbvytnSag|CFE_HG622-dummy_firmware.bin]] (dummy firmware, only CFE and void firmware) 
 + 
 +</WRAP> 
 + 
 +Use the same procedure, as described above. This is a session of upgrading the bootloader 
 +<WRAP bootlog> 
 +<nowiki>CFE version 1.0.37-102.6 for BCM96368 (32bit,SP,BE) 
 +Build Date: Sun Jul 24 16:58:20 CST 2011 (wangxinfeng@build.huawei.com) 
 +Copyright (C) 2000-2008 Broadcom Corporation. 
 + 
 +Parallel flash device: name AM29LV320MT, id 0x2201, size 16384KB 
 +CPU type 0x2A031: 400MHz, Bus: 160MHz, Ref: 64MHz 
 +CPU running TP0 
 +Total memory: 33554432 bytes (32MB) 
 +Boot Address 0xb8000000 
 + 
 + 
 +Board IP address                  : 192.168.1.1:ffffff00 
 +Host IP address                   : 192.168.1.100 
 +Gateway IP address                : 
 +Run from flash/host (f/h)         : f 
 +Default host run file name        : vmlinux 
 +Default host flash file name      : bcm963xx_fs_kernel 
 +Boot delay (0-9 seconds)          : 3 
 +Boot image (0=latest, 1=previous) : 0 
 +Board Id (0-5)                    : 96368MVWG_hg622 
 +Number of MAC Addresses (1-32)    : 11 
 +Base MAC Address                  : 00:e0:fc:09:09:09 
 +PSI Size (1-64) KBytes            : 64 
 +Main Thread Number [0|1]          : 0 
 + 
 +*** Press any key to stop auto run (3 seconds) *** 
 +Auto run second count down: 1 
 +web info: Waiting for connection on socket 0. 
 +CFE> 
 +CFE> f 192.168.1.100:CFW_HG622-dummy_firmware.bin 
 +Loading 192.168.1.100:CFE_HG622-dummy_firmware.bin ... 
 +Finished loading 87360 bytes 
 + 
 +Flashing CFE: .. 
 + 
 +readNvramData() CRC ERROR !!!!!! 
 + 
 +writeNvramData   write ..... 
 + 
 +Flashing root file system and kernel at 0xb8020000: .. 
 + 
 + 
 +Clear Flags ok! 
 +
 +*** Image flash done *** ! 
 + 
 +CFE timeout,reboot 
 + 
 +Resetting board... 
 + 
 +CFE version 2.0.3 for BCM63XX (32bit,SP,BE) 
 +Build Date: Tue Dec 15 18:07:41 CET 2015 (dani@tool) 
 +Copyright (C) 2000-2009 Broadcom Corporation. 
 + 
 +Parallel flash device: name AM29LV320MT, id 0x2201 size 16384KB 
 +Total Flash size: 16384K with 128 sectors 
 +Chip ID: BCM6368B2, MIPS: 400MHz 
 +Main Thread: TP0 
 +Total Memory: 33554432 bytes (32MB) 
 +Boot Address: 0xb8000000 
 + 
 +*** Upgrading NVRAM (version 5 to version 6) *** 
 + 
 +Board IP address                  : 192.168.1.1:ffffff00 
 +Host IP address                   : 192.168.1.100 
 +Gateway IP address                : 
 +Run from flash/host (f/h)         : f 
 +Default host run file name        : vmlinux 
 +Default host flash file name      : bcm963xx_fs_kernel 
 +Boot delay (0-9 seconds)          : 3 
 +Board Id (0-15)                   : 96368MVWG_hg622 
 +Number of MAC Addresses (1-32)    : 11 
 +Base MAC Address                  : 00:e0:fc:09:09:09 
 +PSI Size (1-64) KBytes            : 64 
 +Enable Backup PSI [0|1]           : 0 
 +System Log Size (0-256) KBytes    : 0 
 +Main Thread Number [0|1]          : 0 
 +Voice Board Configuration (0-19) 
 + 
 +*** Press any key to stop auto run (3 seconds) *** 
 +Auto run second count down: 0 
 +Booting from only image (0xb8020000) ... 
 +Code Address: 0x00000000, Entry Address: 0x00000000 
 +Failed to decompress image.  Corrupted image? 
 +web info: Waiting for connection on socket 0. 
 +web info: Waiting for connection on socket 1. 
 +web info: Waiting for connection on socket 2. 
 +web info: Waiting for connection on socket 0. 
 +web info: Waiting for connection on socket 1. 
 +web info: Waiting for connection on socket 3. 
 +web warning: Unexpected TCP disconnect. 
 +web warning: Unexpected TCP disconnect. 
 +web warning: Unexpected TCP disconnect. 
 +web info: Waiting for connection on socket 0. 
 +web info: Upload 4587524 bytes, Broadcom image format. 
 +CFE> 
 +</nowiki> 
 +</WRAP>\\ 
 + 
 +After CFE upgrade you will have a web server at ''%%http://192.168.1.1/%%'' for upgrading new firmwares. No need anymore the serial console, just press the reset button when powering on the router and wait for accessing the CFE webserver flashing interface.
  
 ===== OpenWrt bootlog ===== ===== OpenWrt bootlog =====
Line 499: Line 644:
 [   23.976000] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready</nowiki> [   23.976000] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready</nowiki>
 </WRAP>\\ </WRAP>\\
- 
  
 ===== Tags ===== ===== Tags =====
 [[meta:tags|How to add tags]] [[meta:tags|How to add tags]]
-{{tag>bcm63xx bcm6368 TRNG 16flash 32ram}}+{{tag>bcm63xx bcm6368 16flash 32ram 4port fastethernet TRNG}}
  • Last modified: 2024/10/05 16:24
  • by danitool