summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-mod-status
diff options
context:
space:
mode:
authorJan Hoffmann <jan@3e8.eu>2023-01-28 19:13:55 +0100
committerJan Hoffmann <jan@3e8.eu>2023-02-03 19:31:21 +0100
commit2f1c6fa7a1a4b68adaadd9f7b0f68b0153e76f51 (patch)
treef035985b3814159efbab591078590e0927bf9ed8 /modules/luci-mod-status
parent08f2312abf6ff49e6edc26e6b1516372e23fd606 (diff)
luci-mod-status: extend DSL metrics
Add the following metrics: - Bitswap and rate adaptation status - Impulse noise protection (INP) - Retransmission status (G.INP) - Channel error counters (CV-C, FEC-C) - G.INP counters (MINEFTR, LEFTRS, rtx-tx, rtx-c, rtx-uc) - Modem chipset and firmware version Signed-off-by: Jan Hoffmann <jan@3e8.eu>
Diffstat (limited to 'modules/luci-mod-status')
-rw-r--r--modules/luci-mod-status/htdocs/luci-static/resources/view/status/include/50_dsl.js29
1 files changed, 27 insertions, 2 deletions
diff --git a/modules/luci-mod-status/htdocs/luci-static/resources/view/status/include/50_dsl.js b/modules/luci-mod-status/htdocs/luci-static/resources/view/status/include/50_dsl.js
index 7de3fa2515..785fb773ec 100644
--- a/modules/luci-mod-status/htdocs/luci-static/resources/view/status/include/50_dsl.js
+++ b/modules/luci-mod-status/htdocs/luci-static/resources/view/status/include/50_dsl.js
@@ -9,6 +9,10 @@ var callDSLMetrics = rpc.declare({
expect: { '': {} }
});
+function format_on_off(val) {
+ return val ? _('on') : _('off');
+}
+
function format_latency(val) {
return '%.2f ms'.format(val / 1000);
}
@@ -38,7 +42,16 @@ function renderbox(dsl) {
L.itemlist(E('span'), [
_('Data Rate'), format_values('%1000.3mb/s', dsl.downstream.data_rate, dsl.upstream.data_rate),
_('Max. Attainable Data Rate (ATTNDR)'), format_values('%1000.3mb/s', dsl.downstream.attndr, dsl.upstream.attndr),
- _('Latency'), format_values_func(format_latency, dsl.downstream.interleave_delay, dsl.upstream.interleave_delay)
+ _('Min. Error-Free Throughput (MINEFTR)'), format_values('%1000.3mb/s', dsl.downstream.mineftr, dsl.upstream.mineftr)
+ ]),
+ L.itemlist(E('span'), [
+ _('Bitswap'), format_values_func(format_on_off, dsl.downstream.bitswap, dsl.upstream.bitswap),
+ _('Rate Adaptation Mode'), format_values('%s', dsl.downstream.ra_mode, dsl.upstream.ra_mode)
+ ]),
+ L.itemlist(E('span'), [
+ _('Latency'), format_values_func(format_latency, dsl.downstream.interleave_delay, dsl.upstream.interleave_delay),
+ _('Impulse Noise Protection (INP)'), format_values('%.1f symbols', dsl.downstream.inp, dsl.upstream.inp),
+ _('Retransmission (G.INP)'), format_values_func(format_on_off, dsl.downstream.retx, dsl.upstream.retx)
]),
L.itemlist(E('span'), [
_('Line Attenuation (LATN)'), format_values('%.1f dB', dsl.downstream.latn, dsl.upstream.latn),
@@ -51,7 +64,12 @@ function renderbox(dsl) {
_('Errored Seconds (ES)'), format_values('%d', dsl.errors.near.es, dsl.errors.far.es),
_('Severely Errored Seconds (SES)'), format_values('%d', dsl.errors.near.ses, dsl.errors.far.ses),
_('Loss of Signal Seconds (LOSS)'), format_values('%d', dsl.errors.near.loss, dsl.errors.far.loss),
- _('Unavailable Seconds (UAS)'), format_values('%d', dsl.errors.near.uas, dsl.errors.far.uas)
+ _('Unavailable Seconds (UAS)'), format_values('%d', dsl.errors.near.uas, dsl.errors.far.uas),
+ _('Seconds with Low Error-Free Throughput (LEFTRS)'), format_values('%d', dsl.errors.near.leftrs, dsl.errors.far.leftrs)
+ ]),
+ L.itemlist(E('span'), [
+ _('Channel CRC Errors (CV-C)'), format_values('%d', dsl.errors.near.cv_c, dsl.errors.far.cv_c),
+ _('Channel Errors Corrected by FEC (FEC-C)'), format_values('%d', dsl.errors.near.fec_c, dsl.errors.far.fec_c)
]),
L.itemlist(E('span'), [
_('ATM Header Error Code Errors (HEC)'), format_values('%d', dsl.errors.near.hec, dsl.errors.far.hec),
@@ -59,6 +77,13 @@ function renderbox(dsl) {
_('PTM Pre-emptive CRC Errors (CRCP-P)'), format_values('%d', dsl.errors.near.crcp_p, dsl.errors.far.crcp_p)
]),
L.itemlist(E('span'), [
+ _('Retransmitted DTUs (rtx-tx)'), format_values('%d', dsl.errors.far.tx_retransmitted, dsl.errors.near.tx_retransmitted),
+ _('Corrected DTUs (rtx-c)'), format_values('%d', dsl.errors.near.rx_corrected, dsl.errors.far.rx_corrected),
+ _('Uncorrected DTUs (rtx-uc)'), format_values('%d', dsl.errors.near.rx_uncorrected_protected, dsl.errors.far.rx_uncorrected_protected)
+ ]),
+ L.itemlist(E('span'), [
+ _('Modem Chipset'), dsl.chipset || '-',
+ _('Modem Firmware'), dsl.firmware_version || '-',
_('xTU-C Vendor ID'), dsl.atu_c.vendor || dsl.atu_c.vendor_id
]),
L.itemlist(E('span'), [