diff options
Diffstat (limited to 'ont-technicolor-afm0002.md')
-rw-r--r-- | ont-technicolor-afm0002.md | 83 |
1 files changed, 47 insertions, 36 deletions
diff --git a/ont-technicolor-afm0002.md b/ont-technicolor-afm0002.md index a8adb16..f5e52af 100644 --- a/ont-technicolor-afm0002.md +++ b/ont-technicolor-afm0002.md @@ -4,12 +4,10 @@ has_children: false parent: ONT --- -# Technicolor AFM0002TIM/FWB/WND - -## Hardware Specifications +# Hardware Specifications | | | -|-------------|-------------------------------------------------| +| ----------- | ----------------------------------------------- | | Vendor | Technicolor | | Model | AFM0002TIM/FWB/WND | | Alias | | @@ -24,32 +22,33 @@ parent: ONT | SSH | ✅ user `admin`, password `system` | | Form Factor | miniONT SFP | -![](../../assets/img/afm0002tim.jpg) +{% include image.html file="afm0002tim.jpg" alt="AFM0002TIM" caption="AFM0002TIM" %} + -## Hardware revision +# Hardware revision - AFM0002TIM (IP address: 192.168.2.1) - AFM0002FWB (IP address: 169.0.0.1) - AFM0002WND -Warning -{: .label .label-red } +{% include warning.html content="On this page we discuss AFM0002TIM" %} +{% include info.html content="The AFM0002FWB can be transformed into AFM0002TIM. The AFM0002FWB has an older sw version." %} + + +# Serial -- On this page we discuss AFM0002TIM. -- The AFM0002FWB can be transformed into AFM0002TIM. -- The AFM0002FWB has an older sw version. -## List of software versions +# List of software versions - V1_7_8_180122 - V1_7_8_180725 - V1_7_8_181123 - V1_7_8_210928 - V1_7_8_210412 -## List of partitions +# List of partitions | dev | size | erasesize | name | -|-------------|-------------------------------------------------|-----------|-----------------| +| ----- | -------- | --------- | --------------- | | mtd0 | 00040000 | 00001000 | "boot" | | mtd1 | 00002000 | 00001000 | "env" | | mtd2 | 00002000 | 00001000 | "env2" | @@ -69,13 +68,13 @@ This stick supports dual boot. `k0` and `r0` contains respectively the kernel and firmware of the first image, `k1` and `r1` of the second one -## List of firmware and files -### Useful files +# List of firmware and files +## Useful files - `/var/config/lastgood.xml` - Contains the user portion of the configuration - `/var/config/lastgood-hs.xml` - Contains the "hardware" configuration (i.e. that _should_ not be changed) - `/tmp/omcilog` - OMCI messages logs (must be enabeled, see below) -### Useful binaries +## Useful binaries - `/etc/scripts/flash` - Used to manipulate the config files in a samewhat safe manner - `xmlconfig` - Used to low-level manipulate the XML config files. Called by `flash` - `nv` - Used to manipulate the nvram storage, including persistent config entries via `nv setenv`/`nv getenv` @@ -83,14 +82,14 @@ This stick supports dual boot. - `omci_app` - The OMCI daemon - `diag` - Used to run low-level diagnostics commands on the stick -## Useful commands +# Useful commands -### Enable the Web UI +## Enable the Web UI ```sh # /bin/iptables -D INPUT -p tcp --dport 80 -j DROP ``` -### Check the currently active image +## Check the currently active image ```sh # nv getenv sw_active sw_activ=1 @@ -100,35 +99,40 @@ sw_version0=V1_7_8_210412 sw_version1=V1_7_8_210412 ``` -### Boot to a different image +## Boot to a different image ```sh # nv setenv sw_commit 0|1 # reboot ``` -### Get/Set the ONT S/N +## Get/Set the ONT S/N ```sh # /etc/scripts/bin flash get GPON_SN GPON_SN=TMBB00000000 # /etc/scripts/bin flash set GPON_SN TMBB0A1B2C3D ``` -### Get/Set the ONT PLOAM password -Note: the password is in ASCII format +## Get/Set the ONT PLOAM password + +{% include info.html content="The PLOAM password is in ASCII format" %} + ```sh # /etc/scripts/bin flash get GPON_PLOAM_PASSWD GPON_PLOAM_PASSWD=AAAAAAAAAA # /etc/scripts/bin flash set GPON_PLOAM_PASSWD AAAAAAAAAA ``` -### Query a particular OMCI ME +## Query a particular OMCI ME ```sh # omcicli mib get MIB_IDX ``` -## Low level modding -Note: this section is based on version `V1_7_8_210412` of the stick -### Trasnfer files from/to the stick +# Low level modding + +{% include warning.html content="This section is based on version `V1_7_8_210412` of the stick" %} + + +## Trasnfer files from/to the stick Works with binary files too, just run md5sum on source and destination to make sure you are not corrupting anything... From the stick to the PC: ```sh @@ -138,14 +142,19 @@ From the PC to the stick ```sh # cat lastgood.xml | ssh admin@192.168.2.1 "cat > /var/config/lastgood.xml" ``` -**Note:** on windows replace type with cat and run the commands from cmd (not powershell) -### Extract and repack the rootfs + +{% include warning.html content="on windows replace type with cat and run the commands from cmd (not powershell)" %} + +## Extract and repack the rootfs ```sh # unsquashfs mtd5.bin # mksquashfs squashfs-root rootfs -b 131072 -comp lzma -no-recovery ``` -### Flash a new rootfs -**Note: you can only flash the inactive image**. So mtd4/5 if you are on image1, mtd6/7 if you are on image0. +## Flash a new rootfs + +{% include info.html content="you can only flash the inactive image" %} + +So mtd4/5 if you are on image1, mtd6/7 if you are on image0. The follwing examples flashes a new rootfs to image1 and boots to it ```sh @@ -154,7 +163,7 @@ The follwing examples flashes a new rootfs to image1 and boots to it # nv setenv sw_commit=1 # reboot ``` -### Add support to configurable SW and HW versions, VENDOR ID and much more +## Add support to configurable SW and HW versions, VENDOR ID and much more We can patch `/etc/scripts/flash` in order to add support for some variables implemented in `omci_app` but removed from `xmlconfig`. The patch is below (change the values to suit your needs) ```patch --- squashfs-root/etc/scripts/flash 2021-09-28 10:38:52.000000000 +0200 @@ -188,7 +197,7 @@ We can patch `/etc/scripts/flash` in order to add support for some variables imp if [ "$?" = "0" ]; then exit 0 ``` -### Increase the length of the software version from 13 to 14 characters +## Increase the length of the software version from 13 to 14 characters `omci_app` has an hard-coded limit of 13 characters for the software version, which is too low. We can binary patch it to increase it to 14 (or more, if you dare/need) ``` JVhEWjAwNCUAAAAIAAgACAAAAAAAAAAAAAAAAAAAAABvbWNpX2FwcG9tY2lfYXBwH4sIAAAAAAAA @@ -212,7 +221,7 @@ For reference, the patch changes the follwing section of the omci_app: The original file md5sum is: `4aea2f72bacc11256b7e2c1583d2ad4f` The patched file md5sum is: `da20327c4c002e4c27f82f6ee63dbc1a` -### Enable PLOAM logging +## Enable PLOAM logging ```sh /etc/scripts/bin flash set OMCI_DBGLVL 1 /etc/scripts/bin flash set OMCI_DBGLOGFILE 1 @@ -225,4 +234,6 @@ reboot If you want to log everything since the stick boots, you can create a custom rootfs. Place the last command inside `etc/runomci.sh` as the last line of the file -## Miscellaneous Links
\ No newline at end of file + + +# Miscellaneous Links
\ No newline at end of file |