Skip to content

Commit

Permalink
add "strict" option to limit plot to d=1 or snr=0 seconds
Browse files Browse the repository at this point in the history
  • Loading branch information
beerriot committed Feb 13, 2021
1 parent 60c6fad commit cb7d275
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,12 @@ The checkboxes determine which data is displayed.
signal-to-noise ratio. Rectangles will be darker grey when the
signal was low and the noise was high.

* "strict": Reduce the rendering to only cases where all pings were
dropped for the second (d=1) for obstructed, beta downtime, and no
satellites. This seems to be what the "Ping Success" plot at the
top of Starlink's own statistics view shows. This checkbox also
reduces the signal-to-noise ratio plot to only cases where snr=0.

## Results

The idea behind the viewer is that the beam between the dish and the
Expand Down
1 change: 1 addition & 0 deletions viewer/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
<input id="betadown" type="checkbox">beta downtime</input>
<input id="nosatellite" type="checkbox">no satellites</input>
<input id="snr" type="checkbox">signal-to-noise ratio</input>
<input id="strict" type="checkbox">strict</input>
</div>
</div>
<script src="viewer.js"></script>
Expand Down
9 changes: 7 additions & 2 deletions viewer/viewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ var display = {
"betadown": false,
"nosatellite": false,
"snr": false,
"strict": false
};

var lengthBox = document.getElementById("stripeLength")
Expand Down Expand Up @@ -95,6 +96,7 @@ attachCheckbox("obstructed");
attachCheckbox("betadown");
attachCheckbox("nosatellite");
attachCheckbox("snr");
attachCheckbox("strict");

function attachButtons(prefix, actionFunc) {
var buttons = {
Expand Down Expand Up @@ -146,13 +148,16 @@ function plot() {
for (var i = offset; i < data.length; i++) {
var boxX = ((i-offset) % stripeLength) * boxWidth
var boxY = Math.floor((i-offset) / stripeLength) * boxHeight
if (display["snr"] && data[i].n < 9) {
if (display["snr"] &&
((!display["strict"] && data[i].n < 9) ||
(display["strict"] && data[i].n == 0))) {
viewer.append(makeBox(boxX, boxY, "#999999", 1-(data[i].n/9)));
}
if (((display["obstructed"] && data[i].o) ||
(display["nosatellite"] && !data[i].s) ||
(display["betadown"] && data[i].s && !data[i].o)) &&
data[i].d < 1) {
((!display["strict"] && data[i].d > 0) ||
(display["strict"] && data[i].d == 1))) {

var red = (data[i].o && display["obstructed"]) ? "ff" : "00"
var green = (!data[i].s && display["nosatellite"]) ? "ff" : "00"
Expand Down

0 comments on commit cb7d275

Please sign in to comment.