Skip to content

Commit

Permalink
Merge pull request #2 from waluwaz/New_metriclist_for_VOO
Browse files Browse the repository at this point in the history
New metriclist for voo
  • Loading branch information
waluwaz authored Mar 21, 2022
2 parents 53fe521 + 893a383 commit e701e74
Show file tree
Hide file tree
Showing 11 changed files with 1,794 additions and 77 deletions.
24 changes: 17 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/91af8db9cd354643a8ef6a7117be90fb)](https://www.codacy.com/app/jackyaz/modmon?utm_source=github.com&utm_medium=referral&utm_content=jackyaz/modmon&utm_campaign=Badge_Grade)
![Shellcheck](https://github.com/jackyaz/modmon/actions/workflows/shellcheck.yml/badge.svg)

## v0.1.0-alpha
## v0.2.0-alpha
### Updated on 2022-03-16
## About
modmon is a tool that tracks your cable modem's stats (such as signal power levels) for AsusWRT Merlin with charts for daily, weekly and monthly summaries. It was created by JackYaz. This repository has a derivative work based on modmon and customized to work with another modem, the Technicolor CGA4233 from VOO in Belgium. It doesn't have a specific name, because I'm not sure how to change the name without breaking it; also because it probably couldn't coexist with the original modmon, and finally because I can't imagine a scenario where someone would concurrently need the original modmon and my hack.
modmon is a tool that tracks your cable modem's stats (such as signal power levels) for AsusWRT Merlin with charts for daily, weekly and monthly summaries. It was created by JackYaz. This repository has a derivative work based on modmon and customized to work with another modem, the Technicolor CGA4233 from VOO in Belgium. It doesn't have a specific name, because I'm not sure how to change the name without breaking it ;-) ; also because it probably couldn't coexist with the original modmon, and finally because I can't imagine a scenario where someone would concurrently need the original modmon and my hack.

So, my work tries to support the Technicolor CGA4233 from VOO in Belgium. Compared to the version of Jack, it hammers the modem every 3 minutes (in order to keep the session alive). It needs you to update the curl command around line 815 of modmon.sh, and paste the tokens for PHP session and authentication (also in CSRF). I got them with F12 (Developer tools)/Network/Reload/Copy as curl. And you need to either start modmon fast, or keep the session alive until it starts. You have 5 minutes at most... I usually have a ssh session active, cd /jffs/scripts, rm modmon, vi modmon, ESC-i, copy/paste the text with the center mouse button, ESC-:wq, chmod a+x (or something similar, or whatever works with your favourite editor)
So, my work tries to support the Technicolor CGA4233 from VOO in Belgium. Compared to the version of Jack, it hammers the modem every 15 minutes. It probably needs you to update the curl command around line 815 of modmon.sh, and paste the tokens for PHP session and authentication (also in CSRF). I got them with F12 (Developer tools)/Network/Reload/Copy as curl.

modmon is free to use under the [GNU General Public License version 3](https://opensource.org/licenses/GPL-3.0) (GPL 3.0).
modmon voo is free to use under the [GNU General Public License version 3](https://opensource.org/licenses/GPL-3.0) (GPL 3.0).

### Supporting development
Love the script ? Any and all donations gratefully sent to JackYaz who did 100% of the work for the original modmon, which means 99% of the work for this. For more reliability, please navigate to Jack's repo and click Paypal from his repo.
Expand All @@ -19,8 +19,8 @@ You must be running firmware Merlin 384.15/384.13_4 or Fork 43E5 (or later) [Asu

## Installation
Install the original modmon from JackYaz in version 1.1.8. See his instructions.
Replace the modmon file in /jffs/scripts with the modmon from my repo. ! The name in the router must be modmon, not modmon.sh.
(NB: In the future, I might customize other files which would also need to be copied to the router. The commit dates might give you a clue.)
Replace the modmon file in /jffs/scripts with the modmon.sh from my repo. ! The name in the router must be modmon, not modmon.sh.
(NB: In the future, I might customize other files which would also need to be copied to the router. The commit dates might give you a clue.) Also update the .asp file at /jffs/addons/modmon.d
The modmon file on the router must be executable (chmod a+x).
I guess my Master branch is your best bet.

Expand All @@ -32,7 +32,7 @@ Using your preferred SSH client/terminal, copy and paste the following command,
/usr/sbin/curl --retry 3 "https://raw.githubusercontent.com/waluwaz/modmon/master/modmon.sh" -o "/jffs/scripts/modmon" && chmod 0755 /jffs/scripts/modmon && /jffs/scripts/modmon install
```

And anyway, don't forget the special dance to adapt the script to an active session. See above. This modiofication might have to be renewed, e.g. if the modem reboots for instance.
And anyway, don't forget the special dance to adapt the script to an active session. See above. This modification might have to be renewed, e.g. if the modem reboots for instance.

## Usage
### WebUI
Expand All @@ -57,3 +57,13 @@ You can post about any issues and problems here: [Asuswrt-Merlin AddOns on SNBFo
but I don't get there often, and I probably won't be available to help.

I guess you already understood, this is not a well-rounded solution for a large audience. This is proof that it could work for me; and if your setup is similar; and you have a similar skillset, you will probably be able to get there with less effort than I did originally. Use it if you like, if you are interested in experimenting, not if you need a reliable solution.

Known issues:
The timestamps in the log table are wrong. The order is probably wrong too.
Legend is so dynamic that channel 22 in chart A may have a different colour than 22 in chart B.
Count of "graphic lines" in charts is somewhat buggy. The filtering is usually not display, even though it shoud be displayed.
!! Filtering not working on Uncorrectable, that has only 16 channels, instead of 20.
The choice of timeslice (daily, weekly, monthly) should apply to all graphs.
The choice of timeslice in zoom (e.g. from 19:00 'til 22:00) should apply to all graphs.

?? debug draw_chart
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
,ojadot,satellite-r850,21.03.2022 18:46,file:///home/ojadot/.config/libreoffice/4;
6 changes: 5 additions & 1 deletion documentation/Technicolor_CGA4233_VOO/01_curl_sample_full.sh
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
curl 'http://192.168.100.1/api/v1/modem/exUSTbl,exDSTbl,USTbl,DSTbl,ErrTbl?_=1647091502526' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' -H 'Accept-Encoding: gzip, deflate' -H 'X-CSRF-TOKEN: e2e17093a9d053ef75f634b21b7918a0' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' -H 'Referer: http://192.168.100.1/' -H 'Cookie: lang=fr; PHPSESSID=mhtal0ckajf2hsjsec5ch4m76a; auth=e2e17093a9d053ef75f634b21b7918a0' -H 'DNT: 1' -H 'Sec-GPC: 1' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache'
curl 'http://192.168.100.1/api/v1/modem/exUSTbl,exDSTbl,USTbl,DSTbl,ErrTbl?_=1647091502526' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' -H 'Accept-Encoding: gzip, deflate' -H 'X-CSRF-TOKEN: e2e17093a9d053ef75f634b21b7918a0' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' -H 'Referer: http://192.168.100.1/' -H 'Cookie: lang=fr; PHPSESSID=mhtal0ckajf2hsjsec5ch4m76a; auth=e2e17093a9d053ef75f634b21b7918a0' -H 'DNT: 1' -H 'Sec-GPC: 1' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache'



curl 'http://192.168.100.1/api/v1/modem/LogTbl?_=1647800130683' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' -H 'Accept-Encoding: gzip, deflate' -H 'X-CSRF-TOKEN: 85e9e2137f59ed1caa27cafd40f6657f' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' -H 'Referer: http://192.168.100.1/' -H 'Cookie: PHPSESSID=chqblofn34v2rsqju5ajodrs0v; lang=fr; auth=85e9e2137f59ed1caa27cafd40f6657f' -H 'DNT: 1' -H 'Sec-GPC: 1' -H 'Pragma: no-cache' -H 'Cache-Control: no-cache'
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
curl -fs --retry 3 --connect-timeout 15 'http://192.168.100.1/api/v1/modem/LogTbl' -H 'User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0' -H 'Accept: */*' -H 'X-CSRF-TOKEN: 7d298d27f7ede0df78c9292cdca2cd57' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' -H 'Cookie: lang=fr; PHPSESSID=9csugaomqu52rqc6vgul600b91; auth=7d298d27f7ede0df78c9292cdca2cd57' > "$shstatsfile_curl"
1 change: 1 addition & 0 deletions documentation/Technicolor_CGA4233_VOO/09_json_log_raw.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"error":"ok","message":"all values retrieved","data":{"LogTbl":[{"__id":"1","time":"Mon Mar 14 09:57:05 2022\n","id":"2436694066","level":"6","text":"Honoring MDD; IP provisioning mode = IPv4"},{"__id":"2","time":"Mon Mar 14 09:57:07 2022\n","id":"68000300","level":"5","text":"DHCP WARNING - Non-critical field invalid in response ;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"3","time":"Mon Mar 14 09:57:07 2022\n","id":"73040100","level":"6","text":"TLV-11 - unrecognized OID;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"4","time":"Mon Mar 14 09:57:22 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"5","time":"Mon Mar 14 09:57:26 2022\n","id":"84020300","level":"5","text":"MDD message timeout;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"6","time":"Mon Mar 14 09:57:27 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"7","time":"Mon Mar 14 09:57:33 2022\n","id":"82000400","level":"3","text":"Received Response to Broadcast Maintenance Request, But no Unicast Maintenance opportunities received - T4 time out;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"8","time":"Mon Mar 14 09:57:34 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"9","time":"Mon Mar 14 09:59:15 2022\n","id":"82000400","level":"3","text":"Received Response to Broadcast Maintenance Request, But no Unicast Maintenance opportunities received - T4 time out;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"10","time":"Mon Mar 14 09:59:20 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:00:00:00:00:00;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"11","time":"Mon Mar 14 09:59:58 2022\n","id":"2436694066","level":"6","text":"Honoring MDD; IP provisioning mode = IPv4"},{"__id":"12","time":"Mon Mar 14 10:00:01 2022\n","id":"68000300","level":"5","text":"DHCP WARNING - Non-critical field invalid in response ;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"13","time":"Mon Mar 14 10:00:02 2022\n","id":"73040100","level":"6","text":"TLV-11 - unrecognized OID;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"14","time":"Mon Mar 14 10:00:33 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"15","time":"Mon Mar 14 10:00:36 2022\n","id":"84020300","level":"5","text":"MDD message timeout;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"16","time":"Mon Mar 14 10:00:36 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"17","time":"Mon Mar 14 10:00:42 2022\n","id":"84020300","level":"5","text":"MDD message timeout;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"18","time":"Mon Mar 14 10:00:42 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"19","time":"Mon Mar 14 10:01:22 2022\n","id":"82000700","level":"3","text":"Unicast Ranging Received Abort Response - Re-initializing MAC;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"20","time":"Mon Mar 14 10:01:36 2022\n","id":"2436694066","level":"6","text":"Honoring MDD; IP provisioning mode = IPv4"},{"__id":"21","time":"Mon Mar 14 10:01:39 2022\n","id":"68000300","level":"5","text":"DHCP WARNING - Non-critical field invalid in response ;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"22","time":"Mon Mar 14 10:01:39 2022\n","id":"73040100","level":"6","text":"TLV-11 - unrecognized OID;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"23","time":"Mon Mar 14 20:02:24 2022\n","id":"84000500","level":"3","text":"SYNC Timing Synchronization failure - Loss of Sync;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"24","time":"Mon Mar 14 20:02:27 2022\n","id":"82001100","level":"5","text":"RNG-RSP CCAP Commanded Power Exceeds Value Corresponding to the Top of the DRW;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"25","time":"Mon Mar 14 20:02:27 2022\n","id":"2436694061","level":"5","text":"Dynamic Range Window violation"},{"__id":"26","time":"Tue Mar 15 03:27:35 2022\n","id":"68010300","level":"4","text":"DHCP RENEW WARNING - Field invalid in response v4 option;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"27","time":"Sun Mar 20 11:18:56 2022\n","id":"84000100","level":"3","text":"SYNC Timing Synchronization failure - Failed to acquire QAM\/QPSK symbol timing;;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"28","time":"Sun Mar 20 11:19:03 2022\n","id":"82000200","level":"3","text":"No Ranging Response received - T3 time-out;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"29","time":"Sun Mar 20 11:20:11 2022\n","id":"82001100","level":"5","text":"RNG-RSP CCAP Commanded Power Exceeds Value Corresponding to the Top of the DRW;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"30","time":"Sun Mar 20 11:20:11 2022\n","id":"2436694061","level":"5","text":"Dynamic Range Window violation"},{"__id":"31","time":"Sun Mar 20 11:20:11 2022\n","id":"82001100","level":"5","text":"RNG-RSP CCAP Commanded Power Exceeds Value Corresponding to the Top of the DRW;CM-MAC=e4:bf:fa:25:01:63;CMTS-MAC=00:af:1f:1e:7d:ce;CM-QOS=1.1;CM-VER=3.1;"},{"__id":"32","time":"Sun Mar 20 11:20:11 2022\n","id":"2436694061","level":"5","text":"Dynamic Range Window violation"}]}}
Loading

0 comments on commit e701e74

Please sign in to comment.