From 15242cc18648c324619b7a3a78cce7e66daaeea7 Mon Sep 17 00:00:00 2001 From: Simone Bortolin Date: Sat, 3 Dec 2022 00:30:02 +0100 Subject: Add info on China, SF, Rooted firmware for huawei MA5671a (#47) * add info on huawei ma * add missing point 2 of huawei root and replace tik with $() * fix counter reset * Update _ont/ont-huawei-ma5671a-rooted.md Co-authored-by: Ernesto Castellotti --- _ont/ont-huawei-ma5671a-rooted.md | 172 +++++++++++++++++++++++++++++++++++++- 1 file changed, 168 insertions(+), 4 deletions(-) (limited to '_ont/ont-huawei-ma5671a-rooted.md') diff --git a/_ont/ont-huawei-ma5671a-rooted.md b/_ont/ont-huawei-ma5671a-rooted.md index b4b3884..a4a6d14 100644 --- a/_ont/ont-huawei-ma5671a-rooted.md +++ b/_ont/ont-huawei-ma5671a-rooted.md @@ -7,10 +7,174 @@ layout: default # General setting -[Edit sfp_a2_info file](https://forum.openwrt.org/t/support-ma5671a-sfp-gpon/48042/24) + +{% include alert.html content="Unlike the other firmware in this firmware, the data must be modified in a base64-encoded file. To simplify this, you can use the following web application." alert="Info" icon="svg-info" color="blue" %} + +## Web procedure + + +1. Get `sfp_a2_info` and paste into the form + +
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ +
+
+ + +
+
+ + +{:style="counter-reset:none"} +2. Transfer modified file back into variable `sfp_a2_info`, replace `` with the output of web form. + +```shell +fw_setenv sfp_a2_info "" +``` + +## Temporary file procedure + +1. Save `sfp_a2_info` in into temporary file + +```shell +fw_printenv sfp_a2_info | sed "s/^sfp_a2_info=//" > /tmp/sfp_a2.txt +``` +And print a pretty version: +```shell +fw_printenv sfp_a2_info | sed "s/^sfp_a2_info=//" | tr '@' '\n' +``` + +2. Setting S/N + +The S/N is stored on the 6th line, for sample `4857544311223344` (where `48575443` are hex encoding of `HWTC`) are stored: +``` +AAAAAAAAAAJIV1RDESIzRP///////////////////wAAAAAAAAAAAAAAAAAA +00000000000000024857544311223344ffffffffffffffffffffffffffffff0000000000000000000000000000 +``` + +The entire S/N, including the PON ID, is encoded first in hex and then in base64 + +3. Setting Ploam Password + +The Ploam Password is stored on the 5th line, for sample (`1234567890`) are stored: +``` +ffffffffffffffff00021437d77db7df7e37e77eb7ef7f37f77d00000000000000000000000000000000000000 +//////////8AAhQ31323334353637383930AAAAAAAAAAAAAAAAAAAAAAAAA +``` + +The entire Ploam, is encoded first in hex and then in base64 + +4. Setting MAC Address + +The Ploam Password is stored on the 9th line, for sample (`48:57:02:da:be:ef`) are stored: +``` +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAASFcC2r7vAAAAAAAAAAAAAAAAAAAA +000000000000000000000000000000000000000000000000485702dabeef000000000000000000000000000000 +``` + +5. Transfer modified file back into variable `sfp_a2_info` + +```shell +fw_setenv sfp_a2_info $(cat /tmp/sfp_a2.txt) +``` + +## Review and testing + +After reboot I check for new variables: + +```shell +fw_printenv nPassword +fw_printenv gSerial +fw_printenv ethaddr +``` + +After reboot I check for new variables: + +## Check registration status for O5 (successful) + +```shell +onu ploamsg +``` # Disable dying gasp -```sh -# fw_setenv nDyingGaspEnable 0 -``` \ No newline at end of file +```shell +fw_setenv nDyingGaspEnable 0 +``` + +# Miscellaneous Links + +- [Edit sfp_a2_info file](https://forum.openwrt.org/t/support-ma5671a-sfp-gpon/48042/25) -- cgit v1.2.3