„javascript.h“ ändern
This commit is contained in:
parent
6cbd947787
commit
9b58db178c
213
javascript.h
213
javascript.h
@ -1,132 +1,125 @@
|
|||||||
const char JAVASCRIPT[] PROGMEM = R"=====(
|
const char JAVASCRIPT[] PROGMEM = R"=====(
|
||||||
<script>
|
<script>
|
||||||
var okaytogo = true;
|
|
||||||
var vu_meters_loaded = false;
|
var vu_meters_loaded = false;
|
||||||
|
|
||||||
// Function for drawing the LED bar graphs
|
// Function for drawing the LED bar graphs
|
||||||
function vumeter(elem, config){
|
function vumeter(elem, config){
|
||||||
|
// Settings
|
||||||
|
var max = config.max || 100;
|
||||||
|
var boxCount = config.boxCount || 10;
|
||||||
|
var boxCountRed = config.boxCountRed || 2;
|
||||||
|
var boxCountYellow = config.boxCountYellow || 3;
|
||||||
|
var boxGapFraction = config.boxGapFraction || 0.2;
|
||||||
|
var jitter = 0;//config.jitter || 0.02;
|
||||||
|
|
||||||
// Settings
|
// Colours
|
||||||
var max = config.max || 100;
|
var redOn = 'rgba(255,47,30,0.9)';
|
||||||
var boxCount = config.boxCount || 10;
|
var redOff = 'rgba(64,12,8,0.9)';
|
||||||
var boxCountRed = config.boxCountRed || 2;
|
var yellowOn = 'rgba(255,215,5,0.9)';
|
||||||
var boxCountYellow = config.boxCountYellow || 3;
|
var yellowOff = 'rgba(64,53,0,0.9)';
|
||||||
var boxGapFraction = config.boxGapFraction || 0.2;
|
var greenOn = 'rgba(53,255,30,0.9)';
|
||||||
var jitter = 0;//config.jitter || 0.02;
|
var greenOff = 'rgba(13,64,8,0.9)';
|
||||||
|
|
||||||
// Colours
|
// Derived and starting values
|
||||||
var redOn = 'rgba(255,47,30,0.9)';
|
var width = elem.width;
|
||||||
var redOff = 'rgba(64,12,8,0.9)';
|
var height = elem.height;
|
||||||
var yellowOn = 'rgba(255,215,5,0.9)';
|
var curVal = 0;
|
||||||
var yellowOff = 'rgba(64,53,0,0.9)';
|
|
||||||
var greenOn = 'rgba(53,255,30,0.9)';
|
|
||||||
var greenOff = 'rgba(13,64,8,0.9)';
|
|
||||||
|
|
||||||
// Derived and starting values
|
// Gap between boxes and box height
|
||||||
var width = elem.width;
|
var boxHeight = height / (boxCount + (boxCount+1)*boxGapFraction);
|
||||||
var height = elem.height;
|
var boxGapY = boxHeight * boxGapFraction;
|
||||||
var curVal = 0;
|
|
||||||
|
|
||||||
// Gap between boxes and box height
|
var boxWidth = width - (boxGapY*2);
|
||||||
var boxHeight = height / (boxCount + (boxCount+1)*boxGapFraction);
|
var boxGapX = (width - boxWidth) / 2;
|
||||||
var boxGapY = boxHeight * boxGapFraction;
|
|
||||||
|
|
||||||
var boxWidth = width - (boxGapY*2);
|
// Canvas starting state
|
||||||
var boxGapX = (width - boxWidth) / 2;
|
var c = elem.getContext('2d');
|
||||||
|
|
||||||
// Canvas starting state
|
// Main draw loop
|
||||||
var c = elem.getContext('2d');
|
var draw = function(){
|
||||||
|
var targetVal = parseInt(elem.dataset.val, 10);
|
||||||
|
|
||||||
// Main draw loop
|
// Gradual approach
|
||||||
var draw = function(){
|
if (curVal <= targetVal){
|
||||||
|
curVal += (targetVal - curVal) / 5;
|
||||||
|
} else {
|
||||||
|
curVal -= (curVal - targetVal) / 5;
|
||||||
|
}
|
||||||
|
curVal = targetVal;
|
||||||
|
|
||||||
var targetVal = parseInt(elem.dataset.val, 10);
|
// Apply jitter
|
||||||
|
if (jitter > 0 && curVal > 0){
|
||||||
// Gradual approach
|
var amount = (Math.random()*jitter*max);
|
||||||
if (curVal <= targetVal){
|
if (Math.random() > 0.5){
|
||||||
curVal += (targetVal - curVal) / 5;
|
amount = -amount;
|
||||||
} else {
|
}
|
||||||
curVal -= (curVal - targetVal) / 5;
|
curVal += amount;
|
||||||
}
|
}
|
||||||
curVal = targetVal;
|
if (curVal < 0) {
|
||||||
|
curVal = 0;
|
||||||
// Apply jitter
|
|
||||||
if (jitter > 0 && curVal > 0){
|
|
||||||
var amount = (Math.random()*jitter*max);
|
|
||||||
if (Math.random() > 0.5){
|
|
||||||
amount = -amount;
|
|
||||||
}
|
|
||||||
curVal += amount;
|
|
||||||
}
|
|
||||||
if (curVal < 0) {
|
|
||||||
curVal = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
c.save();
|
|
||||||
c.beginPath();
|
|
||||||
c.rect(0, 0, width, height);
|
|
||||||
c.fillStyle = 'rgb(32,32,32)';
|
|
||||||
c.fill();
|
|
||||||
c.restore();
|
|
||||||
drawBoxes(c, curVal);
|
|
||||||
|
|
||||||
requestAnimationFrame(draw);
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
// Draw the boxes
|
|
||||||
function drawBoxes(c, val){
|
|
||||||
c.save();
|
|
||||||
c.translate(boxGapX, boxGapY);
|
|
||||||
for (var i = 0; i < boxCount; i++){
|
|
||||||
var id = getId(i);
|
|
||||||
|
|
||||||
c.beginPath();
|
|
||||||
if (isOn(id, val)){
|
|
||||||
c.shadowBlur = 10;
|
|
||||||
c.shadowColor = getBoxColor(id, val);
|
|
||||||
}
|
|
||||||
c.rect(0, 0, boxWidth, boxHeight);
|
|
||||||
c.fillStyle = getBoxColor(id, val);
|
|
||||||
c.fill();
|
|
||||||
c.translate(0, boxHeight + boxGapY);
|
|
||||||
}
|
|
||||||
c.restore();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get the color of a box given it's ID and the current value
|
c.save();
|
||||||
function getBoxColor(id, val){
|
c.beginPath();
|
||||||
// on colours
|
c.rect(0, 0, width, height);
|
||||||
if (id > boxCount - boxCountRed){
|
c.fillStyle = 'rgb(32,32,32)';
|
||||||
return isOn(id, val)? redOn : redOff;
|
c.fill();
|
||||||
}
|
c.restore();
|
||||||
if (id > boxCount - boxCountRed - boxCountYellow){
|
drawBoxes(c, curVal);
|
||||||
return isOn(id, val)? yellowOn : yellowOff;
|
|
||||||
}
|
|
||||||
return isOn(id, val)? greenOn : greenOff;
|
|
||||||
}
|
|
||||||
|
|
||||||
function getId(index){
|
requestAnimationFrame(draw);
|
||||||
// The ids are flipped, so zero is at the top and
|
};
|
||||||
// boxCount-1 is at the bottom. The values work
|
|
||||||
// the other way around, so align them first to
|
|
||||||
// make things easier to think about.
|
|
||||||
return Math.abs(index - (boxCount - 1)) + 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
function isOn(id, val){
|
// Draw the boxes
|
||||||
// We need to scale the input value (0-max)
|
function drawBoxes(c, val){
|
||||||
// so that it fits into the number of boxes
|
c.save();
|
||||||
var maxOn = Math.ceil((val/max) * boxCount);
|
c.translate(boxGapX, boxGapY);
|
||||||
return (id <= maxOn);
|
for (var i = 0; i < boxCount; i++){
|
||||||
}
|
var id = getId(i);
|
||||||
|
|
||||||
draw();
|
c.beginPath();
|
||||||
|
if (isOn(id, val)){
|
||||||
|
c.shadowBlur = 10;
|
||||||
|
c.shadowColor = getBoxColor(id, val);
|
||||||
|
}
|
||||||
|
c.rect(0, 0, boxWidth, boxHeight);
|
||||||
|
c.fillStyle = getBoxColor(id, val);
|
||||||
|
c.fill();
|
||||||
|
c.translate(0, boxHeight + boxGapY);
|
||||||
|
}
|
||||||
|
c.restore();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Get the color of a box given it's ID and the current value
|
||||||
|
function getBoxColor(id, val){
|
||||||
|
// on colours
|
||||||
|
if (id > boxCount - boxCountRed){
|
||||||
|
return isOn(id, val)? redOn : redOff;
|
||||||
|
}
|
||||||
|
if (id > boxCount - boxCountRed - boxCountYellow){
|
||||||
|
return isOn(id, val)? yellowOn : yellowOff;
|
||||||
|
}
|
||||||
|
return isOn(id, val)? greenOn : greenOff;
|
||||||
|
}
|
||||||
|
|
||||||
|
function getId(index){
|
||||||
|
// The ids are flipped, so zero is at the top and
|
||||||
|
// boxCount-1 is at the bottom. The values work
|
||||||
|
// the other way around, so align them first to
|
||||||
|
// make things easier to think about.
|
||||||
|
return Math.abs(index - (boxCount - 1)) + 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
function isOn(id, val){
|
||||||
|
// We need to scale the input value (0-max)
|
||||||
|
// so that it fits into the number of boxes
|
||||||
|
var maxOn = Math.ceil((val/max) * boxCount);
|
||||||
|
return (id <= maxOn);
|
||||||
|
}
|
||||||
|
draw();
|
||||||
}
|
}
|
||||||
|
|
||||||
setInterval(function() {
|
setInterval(function() {
|
||||||
// Call a function repetatively
|
|
||||||
okaytogo = !okaytogo;
|
|
||||||
getDATA();
|
getDATA();
|
||||||
}, 500);
|
}, 500);
|
||||||
|
|
||||||
@ -150,11 +143,10 @@ function load_vu_meters() {
|
|||||||
|
|
||||||
// plays a beep sound
|
// plays a beep sound
|
||||||
function beep() {
|
function beep() {
|
||||||
var snd = new Audio("data:audio/wav;base64,//uQRAAAAWMSLwUIYAAsYkXgoQwAEaYLWfkWgAI0wWs/ItAAAGDgYtAgAyN+QWaAAihwMWm4G8QQRDiMcCBcH3Cc+CDv/7xA4Tvh9Rz/y8QADBwMWgQAZG/ILNAARQ4GLTcDeIIIhxGOBAuD7hOfBB3/94gcJ3w+o5/5eIAIAAAVwWgQAVQ2ORaIQwEMAJiDg95G4nQL7mQVWI6GwRcfsZAcsKkJvxgxEjzFUgfHoSQ9Qq7KNwqHwuB13MA4a1q/DmBrHgPcmjiGoh//EwC5nGPEmS4RcfkVKOhJf+WOgoxJclFz3kgn//dBA+ya1GhurNn8zb//9NNutNuhz31f////9vt///z+IdAEAAAK4LQIAKobHItEIYCGAExBwe8jcToF9zIKrEdDYIuP2MgOWFSE34wYiR5iqQPj0JIeoVdlG4VD4XA67mAcNa1fhzA1jwHuTRxDUQ//iYBczjHiTJcIuPyKlHQkv/LHQUYkuSi57yQT//uggfZNajQ3Vmz+Zt//+mm3Wm3Q576v////+32///5/EOgAAADVghQAAAAA//uQZAUAB1WI0PZugAAAAAoQwAAAEk3nRd2qAAAAACiDgAAAAAAABCqEEQRLCgwpBGMlJkIz8jKhGvj4k6jzRnqasNKIeoh5gI7BJaC1A1AoNBjJgbyApVS4IDlZgDU5WUAxEKDNmmALHzZp0Fkz1FMTmGFl1FMEyodIavcCAUHDWrKA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TTdNa325mImNg3TTPV9q3pmY0xoO6bv3r00y+IDGid/9aaaZTGMuj9mpu9Mpio1dXrr5HERTZSmqU36A3CumzN/9Robv/Xx4v9ijkSRSNLQhAWumap82WRSBUqXStV/YcS+XVLnSS+WLDroqArFkMEsAS+eWmrUzrO0oEmE40RlMZ5+ODIkAyKAGUwZ3mVKmcamcJnMW26MRPgUw6j+LkhyHGVGYjSUUKNpuJUQoOIAyDvEyG8S5yfK6dhZc0Tx1KI/gviKL6qvvFs1+bWtaz58uUNnryq6kt5RzOCkPWlVqVX2a/EEBUdU1KrXLf40GoiiFXK///qpoiDXrOgqDR38JB0bw7SoL+ZB9o1RCkQjQ2CBYZKd/+VJxZRRZlqSkKiws0WFxUyCwsKiMy7hUVFhIaCrNQsKkTIsLivwKKigsj8XYlwt/WKi2N4d//uQRCSAAjURNIHpMZBGYiaQPSYyAAABLAAAAAAAACWAAAAApUF/Mg+0aohSIRobBAsMlO//Kk4soosy1JSFRYWaLC4qZBYWFRGZdwqKiwkNBVmoWFSJkWFxX4FFRQWR+LsS4W/rFRb/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////VEFHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAU291bmRib3kuZGUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMjAwNGh0dHA6Ly93d3cuc291bmRib3kuZGUAAAAAAAAAACU=");
|
var snd = new Audio("data:audio/wav;base64,//uQRAAAAWMSLwUIYAAsYkXgoQwAEaYLWfkWgAI0wWs/ItAAAGDgYtAgAyN+QWaAAihwMWm4G8QQRDiMcCBcH3Cc+CDv/7xA4Tvh9Rz/y8QADBwMWgQAZG/ILNAARQ4GLTcDeIIIhxGOBAuD7hOfBB3/94gcJ3w+o5/5eIAIAAAVwWgQAV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BYWFRGZdwqKiwkNBVmoWFSJkWFxX4FFRQWR+LsS4W/rFRb/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////VEFHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAU291bmRib3kuZGUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMjAwNGh0dHA6Ly93d3cuc291bmRib3kuZGUAAAAAAAAAACU=");
|
||||||
snd.play();
|
snd.play();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Converts a String to Integer
|
// Converts a String to Integer
|
||||||
function strtoint(x) {
|
function strtoint(x) {
|
||||||
const parsed = parseInt(x);
|
const parsed = parseInt(x);
|
||||||
@ -260,7 +252,6 @@ function getDATA() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
document.getElementById("VSWRValue").innerHTML = data[6];
|
document.getElementById("VSWRValue").innerHTML = data[6];
|
||||||
//document.getElementById("RLValue").innerHTML = data[7];
|
|
||||||
document.getElementById("BANDValue").innerHTML = data[8]; // displays the chosen band
|
document.getElementById("BANDValue").innerHTML = data[8]; // displays the chosen band
|
||||||
document.getElementById("AntennaName").innerHTML = data[10]; // displays the name of the antenna
|
document.getElementById("AntennaName").innerHTML = data[10]; // displays the name of the antenna
|
||||||
document.getElementById("max_led_pwr_fwd").innerHTML = data[12]; // sets the FWD LED bar max value
|
document.getElementById("max_led_pwr_fwd").innerHTML = data[12]; // sets the FWD LED bar max value
|
||||||
|
Loading…
Reference in New Issue
Block a user