diff --git a/datahandler.js b/datahandler.js
index 248bf63..3b5283f 100644
--- a/datahandler.js
+++ b/datahandler.js
@@ -83,13 +83,13 @@ const callbacks = {
), 'callback_tp*'),
ta: koffi.register(rds => (
- value = rdsparser.get_ta(rds)
- //console.log('TA: ' + value)
+ value = rdsparser.get_ta(rds),
+ dataToSend.ta = value
), 'callback_ta*'),
ms: koffi.register(rds => (
- value = rdsparser.get_ms(rds)
- //console.log('MS: ' + value)
+ value = rdsparser.get_ms(rds),
+ dataToSend.ms = value
), 'callback_ms*'),
af: koffi.register((rds, value) => (
@@ -192,6 +192,8 @@ var dataToSend = {
st: false,
ps: '',
tp: false,
+ ta: 0,
+ ms: -1,
pty: 0,
af: [],
rt0: '',
diff --git a/userconfig.js b/userconfig.js
index 1e6c815..e4fd13a 100644
--- a/userconfig.js
+++ b/userconfig.js
@@ -2,15 +2,15 @@ const webServerHost = '0.0.0.0'; // IP of the web server
const webServerPort = 8080; // web server port
const webServerName = "Noobish's Server"; // web server name (will be displayed in title, bookmarks...)
-const audioDeviceName = "Microphone (High Definition Audio Device)"; // Audio device name in your OS
+const audioDeviceName = "Microphone (SADES Locust Plus)"; // Audio device name in your OS
const audioPort = 8081;
-const xdrdServerHost = '127.0.0.1'; // xdrd server IP (if it's running on the same machine, use 127.0.0.1)
+const xdrdServerHost = '192.168.1.15'; // xdrd server IP (if it's running on the same machine, use 127.0.0.1)
const xdrdServerPort = 7373; // xdrd server port
-const xdrdPassword = 'password'; // xdrd password (optional)
+const xdrdPassword = 'changememe'; // xdrd password (optional)
-const qthLatitude = ''; // your latitude, useful for maps.fmdx.pl integration
-const qthLongitude = ''; // your longitude, useful for maps.fmdx.pl integration
+const qthLatitude = '50.357935'; // your latitude, useful for maps.fmdx.pl integration
+const qthLongitude = '15.924395'; // your longitude, useful for maps.fmdx.pl integration
const verboseMode = false; // if true, console will display extra messages
diff --git a/web/css/3las/log_window.css b/web/css/3las/log_window.css
deleted file mode 100644
index 2649d48..0000000
--- a/web/css/3las/log_window.css
+++ /dev/null
@@ -1,66 +0,0 @@
-p#logwindowbutton
-{
- cursor: pointer;
- font-size: 8pt;
- -webkit-border-top-left-radius: 2pt;
- -moz-border-radius-topleft: 2pt;
- -o-border-radius-topleft: 2pt;
- border-top-left-radius: 2pt;
-
- -webkit-border-top-right-radius: 2pt;
- -moz-border-radius-topright: 2pt;
- -o-border-radius-topright: 2pt;
- border-top-right-radius: 2pt;
-
- -webkit-border-bottom-right-radius: 2pt;
- -moz-border-radius-bottomright: 2pt;
- -o-border-radius-bottomright: 2pt;
- border-bottom-right-radius: 2pt;
-
- -webkit-border-bottom-left-radius: 2pt;
- -moz-border-radius-bottomleft: 2pt;
- -o-border-radius-bottomleft: 2pt;
- border-bottom-left-radius: 2pt;
- background: #111111;
- color: #F0F0E1;
- padding: 2pt;
- width: 90pt;
-
- border: 1pt solid #777777;
-}
-
-ul#logwindow
-{
- font-family: monospace;
- font-size: 8pt;
- display: none;
- -webkit-border-top-left-radius: 2pt;
- -moz-border-radius-topleft: 2pt;
- -o-border-radius-topleft: 2pt;
- border-top-left-radius: 2pt;
-
- -webkit-border-top-right-radius: 2pt;
- -moz-border-radius-topright: 2pt;
- -o-border-radius-topright: 2pt;
- border-top-right-radius: 2pt;
-
- -webkit-border-bottom-right-radius: 2pt;
- -moz-border-radius-bottomright: 2pt;
- -o-border-radius-bottomright: 2pt;
- border-bottom-right-radius: 2pt;
-
- -webkit-border-bottom-left-radius: 2pt;
- -moz-border-radius-bottomleft: 2pt;
- -o-border-radius-bottomleft: 2pt;
- border-bottom-left-radius: 2pt;
- background: #CCCCCC;
- padding: 2pt;
-
- border: 1pt solid #EEEEEE;
-}
-
-ul#logwindow li
-{
- margin: 0;
- padding: 0;
-}
\ No newline at end of file
diff --git a/web/css/3las/main.css b/web/css/3las/main.css
deleted file mode 100644
index b998134..0000000
--- a/web/css/3las/main.css
+++ /dev/null
@@ -1,69 +0,0 @@
-div#viewcontainer
-{
- display: none;
-}
-
-div.errormessage
-{
- position: absolute;
- display: none;
- width: 200pt;
- height: 150pt;
- left: 0pt;
- top: 0pt;
- font-family: sans-serif;
- font-size: 20pt;
- font-weight: 200;
- color: #EE0000;
- background-color: #000000;
-}
-
-div#chromesuggestion
-{
- position: absolute;
- display: none;
- width: 200pt;
- height: 150pt;
- left: 0pt;
- top: 0pt;
- font-family: sans-serif;
- font-size: 15pt;
- font-weight: 200;
- color: #EEEEEE;
- background-color: #000000;
-}
-
-div#chromesuggestion a,span
-{
- text-decoration: none;
- color: #888888;
-}
-
-div#lightoff
-{
- position: absolute;
- width: 100%;
- height: 100%;
- left: 0pt;
- top: 0pt;
- z-index: 9999999;
- background: black;
- opacity: 0.9;
- cursor: not-allowed;
-}
-
-div#lightbutton
-{
- background-image: url(../../images/3las/light.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
- position: absolute;
- width: 50pt;
- height: 50pt;
- right: 0;
- top: 0;
- z-index: 99999999;
- cursor: pointer;
-}
\ No newline at end of file
diff --git a/web/css/3las/player_controls.css b/web/css/3las/player_controls.css
deleted file mode 100644
index fc9a7ca..0000000
--- a/web/css/3las/player_controls.css
+++ /dev/null
@@ -1,274 +0,0 @@
-div#audioplayer
-{
- position: relative;
- width: 180pt;
- height: 100pt;
-
- background: #4c4e5a;
- background: -moz-linear-gradient(top, #4c4e5a 0%, #2c2d33 100%);
- background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#4c4e5a), color-stop(100%,#2c2d33));
- background: -webkit-linear-gradient(top, #4c4e5a 0%,#2c2d33 100%);
- background: -o-linear-gradient(top, #4c4e5a 0%,#2c2d33 100%);
- background: -ms-linear-gradient(top, #4c4e5a 0%,#2c2d33 100%);
- background: linear-gradient(to bottom, #4c4e5a 0%,#2c2d33 100%);
-
- -webkit-border-top-left-radius: 2pt;
- -moz-border-radius-topleft: 2pt;
- -o-border-radius-topleft: 2pt;
- border-top-left-radius: 2pt;
-
- -webkit-border-top-right-radius: 2pt;
- -moz-border-radius-topright: 2pt;
- -o-border-radius-topright: 2pt;
- border-top-right-radius: 2pt;
-
- -webkit-border-bottom-right-radius: 2pt;
- -moz-border-radius-bottomright: 2pt;
- -o-border-radius-bottomright: 2pt;
- border-bottom-right-radius: 2pt;
-
- -webkit-border-bottom-left-radius: 2pt;
- -moz-border-radius-bottomleft: 2pt;
- -o-border-radius-bottomleft: 2pt;
- border-bottom-left-radius: 2pt;
-
- -webkit-user-select: none;
- -moz-user-select: none;
- -ms-user-select: none;
- user-select: none;
-}
-
-div#audioplayer div#volumebar
-{
- position: absolute;
- visibility: hidden;
- top: 65pt;
- left: 15pt;
- width: 150pt;
- height: 20pt;
-}
-
-div#audioplayer div#activityindicator
-{
- position: absolute;
- top: 5pt;
- left: 5pt;
- width: 20pt;
- height: 20pt;
- -webkit-border-top-left-radius: 10pt;
- -moz-border-radius-topleft: 10pt;
- -o-border-radius-topleft: 10pt;
- border-top-left-radius: 10pt;
-
- -webkit-border-top-right-radius: 10pt;
- -moz-border-radius-topright: 10pt;
- -o-border-radius-topright: 10pt;
- border-top-right-radius: 10pt;
-
- -webkit-border-bottom-right-radius: 10pt;
- -moz-border-radius-bottomright: 10pt;
- -o-border-radius-bottomright: 10pt;
- border-bottom-right-radius: 10pt;
-
- -webkit-border-bottom-left-radius: 10pt;
- -moz-border-radius-bottomleft: 10pt;
- -o-border-radius-bottomleft: 10pt;
- border-bottom-left-radius: 10pt;
-
-
- -webkit-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- -moz-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- -o-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
-
-}
-
-div#audioplayer div#activityindicator div#redlighton
-{
- position: absolute;
- visibility: hidden;
- top: 1pt;
- left: 1pt;
- width: 19pt;
- height: 19pt;
- background-image: url(../../images/3las/red_light_on.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
-}
-
-div#audioplayer div#activityindicator div#redlightoff
-{
- position: absolute;
- top: 1pt;
- left: 1pt;
- width: 19pt;
- height: 19pt;
- background-image: url(../../images/3las/red_light_off.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
-}
-
-div#audioplayer div#volumebar *
-{
- margin: 0px;
- padding: 0px;
- border: medium none;
- outline: medium none;
-}
-
-div#audioplayer div#volumebar div#totalvolume
-{
- position: absolute;
- top: 3pt;
- left: 0;
- width: 100%;
- height: 14pt;
-
-
- -webkit-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- -moz-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- -o-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
- box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3) inset, 1px 1px 1px rgba(255, 255, 255, 0.25);
-
- background: none repeat scroll 0% 0% rgb(33, 34, 39);
-
-
- -webkit-border-top-left-radius: 7pt;
- -moz-border-radius-topleft: 7pt;
- -o-border-radius-topleft: 7pt;
- border-top-left-radius: 7pt;
-
- -webkit-border-top-right-radius: 7pt;
- -moz-border-radius-topright: 7pt;
- -o-border-radius-topright: 7pt;
- border-top-right-radius: 7pt;
-
- -webkit-border-bottom-right-radius: 7pt;
- -moz-border-radius-bottomright: 7pt;
- -o-border-radius-bottomright: 7pt;
- border-bottom-right-radius: 7pt;
-
- -webkit-border-bottom-left-radius: 7pt;
- -moz-border-radius-bottomleft: 7pt;
- -o-border-radius-bottomleft: 7pt;
- border-bottom-left-radius: 7pt;
-}
-
-div#audioplayer div#volumebar div#currentvolume
-{
- position: absolute;
- top: 4pt;
- left: 1pt;
- width: 75pt;
- height: 12pt;
- background-image: url(../../images/3las/bar.svg);
- -webkit-border-top-left-radius: 6pt;
- -moz-border-radius-topleft: 6pt;
- -o-border-radius-topleft: 6pt;
- border-top-left-radius: 6pt;
- -webkit-border-bottom-left-radius: 6pt;
- -moz-border-radius-bottomleft: 6pt;
- -o-border-radius-bottomleft: 6pt;
- border-bottom-left-radius: 6pt;
-}
-
-div#audioplayer div#volumebar div#volumeknob
-{
- position: absolute;
- cursor: pointer;
- top: 0;
- left: 75pt;
- width: 20pt;
- height: 20pt;
- background-image: url(../../images/3las/knob.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
- margin-left: -10pt;
-}
-
-div#audioplayer div#playbuttonoverlay *
-{
- margin: 0px;
- padding: 0px;
- border: medium none;
- outline: medium none;
-}
-
-div#audioplayer div#playbuttonoverlay
-{
- position: absolute;
- top: 15pt;
- left: 15pt;
- width: 150pt;
- height: 70pt;
-}
-
-div#audioplayer div#playbuttonoverlay div#playbutton
-{
- position: absolute;
- cursor: pointer;
- top: 0pt;
- left: 40pt;
- width: 70pt;
- height: 70pt;
- background-image: url(../../images/3las/play.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
-}
-
-div#audioplayer div#controlbar *
-{
- margin: 0px;
- padding: 0px;
- border: medium none;
- outline: medium none;
-}
-
-div#audioplayer div#controlbar
-{
- position: absolute;
- visibility: hidden;
- top: 15pt;
- left: 15pt;
- width: 150pt;
- height: 50pt;
-}
-
-div#audioplayer div#controlbar div#mutebutton
-{
- position: absolute;
- cursor: pointer;
- top: 0pt;
- left: 51.5pt;
- width: 47pt;
- height: 40pt;
- background-image: url(../../images/3las/mute.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
-}
-
-div#audioplayer div#controlbar div#unmutebutton
-{
- visibility: hidden;
- position: absolute;
- cursor: pointer;
- top: 0pt;
- left: 51.5pt;
- width: 47pt;
- height: 40pt;
- background-image: url(../../images/3las/unmute.svg);
- -webkit-background-size: 100% 100%;
- -moz-background-size: 100% 100%;
- -o-background-size: 100% 100%;
- background-size: 100% 100%;
-}
\ No newline at end of file
diff --git a/web/css/breadcrumbs.css b/web/css/breadcrumbs.css
index cc69410..b741e4f 100644
--- a/web/css/breadcrumbs.css
+++ b/web/css/breadcrumbs.css
@@ -1,6 +1,7 @@
h2 {
color: var(--color-4);
margin-bottom: 0;
+ margin-top: 8px;
}
h3 {
@@ -44,8 +45,8 @@ h3 {
display:list-item;
padding: 0;
list-style-type: none;
- height: 425px;
- overflow-y: scroll;
- overflow-x: hidden;
margin-bottom: 0;
+ font-size: 14px;
+ max-height: 380px;
+ overflow-y: auto;
}
\ No newline at end of file
diff --git a/web/css/helpers.css b/web/css/helpers.css
index 3370115..917e0ad 100644
--- a/web/css/helpers.css
+++ b/web/css/helpers.css
@@ -59,7 +59,7 @@
}
.text-big {
- font-size: 60px;
+ font-size: 52px;
font-weight: 300;
}
@@ -77,10 +77,18 @@
font-size: 13px;
}
+.text-smaller {
+ font-size: 11px;
+}
+
.text-gray {
color: #666;
}
+.text-red {
+ color: #ff5776;
+}
+
.text-uppercase {
text-transform: uppercase;
}
diff --git a/web/css/main.css b/web/css/main.css
index b02ad56..443a2b1 100644
--- a/web/css/main.css
+++ b/web/css/main.css
@@ -53,14 +53,14 @@ body {
left: 50%;
transform: translate(-50%, -50%);
width: auto;
- max-width: 1240px;
+ max-width: 1180px;
}
@media (max-width: 960px) {
#wrapper {
position: static;
transform: none;
- margin: 0 auto;
+ margin: 50px auto;
}
}
diff --git a/web/css/panels.css b/web/css/panels.css
index 8cf4642..d3a4e5a 100644
--- a/web/css/panels.css
+++ b/web/css/panels.css
@@ -33,11 +33,6 @@
@media only screen and (max-width: 768px) {
- .panel-10, .panel-33, .panel-90 {
- width: 90%;
- margin: auto;
- margin-bottom: 20px;
- }
.panel-75 {
width: 90%;
}
@@ -49,4 +44,9 @@
width: 90%;
margin: auto;
}
+ [class^="panel-"] {
+ margin: auto;
+ width: 90%;
+ margin-bottom: 20px;
+ }
}
\ No newline at end of file
diff --git a/web/images/3las/bar.svg b/web/images/3las/bar.svg
deleted file mode 100644
index 2400b04..0000000
--- a/web/images/3las/bar.svg
+++ /dev/null
@@ -1,6 +0,0 @@
-
\ No newline at end of file
diff --git a/web/images/3las/knob.svg b/web/images/3las/knob.svg
deleted file mode 100644
index dd6d311..0000000
--- a/web/images/3las/knob.svg
+++ /dev/null
@@ -1,869 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/web/images/3las/light.svg b/web/images/3las/light.svg
deleted file mode 100644
index 07b46f3..0000000
--- a/web/images/3las/light.svg
+++ /dev/null
@@ -1,120 +0,0 @@
-
-
diff --git a/web/images/3las/mute.svg b/web/images/3las/mute.svg
deleted file mode 100644
index 42b170a..0000000
--- a/web/images/3las/mute.svg
+++ /dev/null
@@ -1,902 +0,0 @@
-
-
-
-
diff --git a/web/images/3las/pause.svg b/web/images/3las/pause.svg
deleted file mode 100644
index 28bf8c4..0000000
--- a/web/images/3las/pause.svg
+++ /dev/null
@@ -1,331 +0,0 @@
-
-
-
-
diff --git a/web/images/3las/play.svg b/web/images/3las/play.svg
deleted file mode 100644
index 845539a..0000000
--- a/web/images/3las/play.svg
+++ /dev/null
@@ -1,302 +0,0 @@
-
-
-
-
diff --git a/web/images/3las/red_light_off.svg b/web/images/3las/red_light_off.svg
deleted file mode 100644
index c4bde2b..0000000
--- a/web/images/3las/red_light_off.svg
+++ /dev/null
@@ -1,858 +0,0 @@
-
-
-
-
diff --git a/web/images/3las/red_light_on.svg b/web/images/3las/red_light_on.svg
deleted file mode 100644
index 74a3430..0000000
--- a/web/images/3las/red_light_on.svg
+++ /dev/null
@@ -1,830 +0,0 @@
-
-
-
-
diff --git a/web/images/3las/repeat.svg b/web/images/3las/repeat.svg
deleted file mode 100644
index 51ee92e..0000000
--- a/web/images/3las/repeat.svg
+++ /dev/null
@@ -1,136 +0,0 @@
-
-
\ No newline at end of file
diff --git a/web/images/3las/unmute.svg b/web/images/3las/unmute.svg
deleted file mode 100644
index 0b4dd9d..0000000
--- a/web/images/3las/unmute.svg
+++ /dev/null
@@ -1,847 +0,0 @@
-
-
-
-
diff --git a/web/images/bmc.png b/web/images/bmc.png
deleted file mode 100644
index 4c207cc..0000000
Binary files a/web/images/bmc.png and /dev/null differ
diff --git a/web/images/flags-16.png b/web/images/flags-16.png
index ac65eb5..fab9711 100644
Binary files a/web/images/flags-16.png and b/web/images/flags-16.png differ
diff --git a/web/index.html b/web/index.html
index 11514d7..4b738dc 100644
--- a/web/index.html
+++ b/web/index.html
@@ -49,7 +49,7 @@
-
+
@@ -57,12 +57,14 @@
-
+
TP
-
+ TA
-
+
+
+ MS
@@ -154,13 +156,14 @@
@@ -177,14 +180,17 @@
0
-
-
Join our Discord community!
+
+ Join our OpenRadio Discord community!
-
+
Support the developer!
FM-DX WebServer by Noobish & the OpenRadio community.
-
This app uses librdsparser by Konrad Kosmatka.
+
This app works thanks to these amazing projects:
+ - librdsparser by Konrad Kosmatka
+ - 3LAS by JoJoBond
+ - flat-flags by luishdez
diff --git a/web/js/3las/3las.js b/web/js/3las/3las.js
index 057e7e8..7879f4e 100644
--- a/web/js/3las/3las.js
+++ b/web/js/3las/3las.js
@@ -2,7 +2,7 @@ var _3LAS_Settings = /** @class */ (function () {
function _3LAS_Settings() {
this.SocketHost = document.location.hostname ? document.location.hostname : "127.0.0.1";
this.SocketPort = localStorage.getItem('audioPort') ? localStorage.getItem('audioPort') : 8081;
- this.SocketPath = "/audio";
+ this.SocketPath = "/";
this.WebRTC = new WebRTC_Settings();
this.Fallback = new Fallback_Settings();
}
diff --git a/web/js/3las/fallback/3las.liveaudioplayer.js b/web/js/3las/fallback/3las.liveaudioplayer.js
index 0aef6c6..2f75996 100644
--- a/web/js/3las/fallback/3las.liveaudioplayer.js
+++ b/web/js/3las/fallback/3las.liveaudioplayer.js
@@ -143,5 +143,4 @@ var LiveAudioPlayer = /** @class */ (function () {
// Hystersis value for speed up/down trigger
LiveAudioPlayer.OffsetVariance = 0.2;
return LiveAudioPlayer;
-}());
-//# sourceMappingURL=3las.liveaudioplayer.js.map
\ No newline at end of file
+}());
\ No newline at end of file
diff --git a/web/js/3las/fallback/formats/3las.formatreader.mpeg.js b/web/js/3las/fallback/formats/3las.formatreader.mpeg.js
index 85a1a70..d676238 100644
--- a/web/js/3las/fallback/formats/3las.formatreader.mpeg.js
+++ b/web/js/3las/fallback/formats/3las.formatreader.mpeg.js
@@ -280,5 +280,4 @@ var AudioFormatReader_MPEG = /** @class */ (function (_super) {
// Slot size (MPEG unit of measurement) - use [layer]
AudioFormatReader_MPEG.MPEG_slot_size = new Array(0, 1, 1, 4); // Rsvd, 3, 2, 1
return AudioFormatReader_MPEG;
-}(AudioFormatReader));
-//# sourceMappingURL=3las.formatreader.mpeg.js.map
\ No newline at end of file
+}(AudioFormatReader));
\ No newline at end of file
diff --git a/web/js/3las/fallback/formats/3las.formatreader.wav.js b/web/js/3las/fallback/formats/3las.formatreader.wav.js
index 33ca22a..18552d3 100644
--- a/web/js/3las/fallback/formats/3las.formatreader.wav.js
+++ b/web/js/3las/fallback/formats/3las.formatreader.wav.js
@@ -219,5 +219,4 @@ var AudioFormatReader_WAV = /** @class */ (function (_super) {
this.ErrorCallback();
};
return AudioFormatReader_WAV;
-}(AudioFormatReader));
-//# sourceMappingURL=3las.formatreader.wav.js.map
\ No newline at end of file
+}(AudioFormatReader));
\ No newline at end of file
diff --git a/web/js/3las/util/3las.helpers.js b/web/js/3las/util/3las.helpers.js
index 052f9a2..f1a5631 100644
--- a/web/js/3las/util/3las.helpers.js
+++ b/web/js/3las/util/3las.helpers.js
@@ -126,5 +126,4 @@ var WakeLock = /** @class */ (function () {
WakeLock.VideoWebm = 'GkXfo0AgQoaBAUL3gQFC8oEEQvOBCEKCQAR3ZWJtQoeBAkKFgQIYU4BnQI0VSalmQCgq17FAAw9CQE2AQAZ3aGFtbXlXQUAGd2hhbW15RIlACECPQAAAAAAAFlSua0AxrkAu14EBY8WBAZyBACK1nEADdW5khkAFVl9WUDglhohAA1ZQOIOBAeBABrCBCLqBCB9DtnVAIueBAKNAHIEAAIAwAQCdASoIAAgAAUAmJaQAA3AA/vz0AAA=';
WakeLock.VideoMp4 = 'AAAAHGZ0eXBpc29tAAACAGlzb21pc28ybXA0MQAAAAhmcmVlAAAAG21kYXQAAAGzABAHAAABthADAowdbb9/AAAC6W1vb3YAAABsbXZoZAAAAAB8JbCAfCWwgAAAA+gAAAAAAAEAAAEAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAIVdHJhawAAAFx0a2hkAAAAD3wlsIB8JbCAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAQAAAAAAIAAAACAAAAAABsW1kaWEAAAAgbWRoZAAAAAB8JbCAfCWwgAAAA+gAAAAAVcQAAAAAAC1oZGxyAAAAAAAAAAB2aWRlAAAAAAAAAAAAAAAAVmlkZW9IYW5kbGVyAAAAAVxtaW5mAAAAFHZtaGQAAAABAAAAAAAAAAAAAAAkZGluZgAAABxkcmVmAAAAAAAAAAEAAAAMdXJsIAAAAAEAAAEcc3RibAAAALhzdHNkAAAAAAAAAAEAAACobXA0dgAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAIAAgASAAAAEgAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABj//wAAAFJlc2RzAAAAAANEAAEABDwgEQAAAAADDUAAAAAABS0AAAGwAQAAAbWJEwAAAQAAAAEgAMSNiB9FAEQBFGMAAAGyTGF2YzUyLjg3LjQGAQIAAAAYc3R0cwAAAAAAAAABAAAAAQAAAAAAAAAcc3RzYwAAAAAAAAABAAAAAQAAAAEAAAABAAAAFHN0c3oAAAAAAAAAEwAAAAEAAAAUc3RjbwAAAAAAAAABAAAALAAAAGB1ZHRhAAAAWG1ldGEAAAAAAAAAIWhkbHIAAAAAAAAAAG1kaXJhcHBsAAAAAAAAAAAAAAAAK2lsc3QAAAAjqXRvbwAAABtkYXRhAAAAAQAAAABMYXZmNTIuNzguMw==';
return WakeLock;
-}());
-//# sourceMappingURL=3las.helpers.js.map
\ No newline at end of file
+}());
\ No newline at end of file
diff --git a/web/js/3las/util/3las.logging.js b/web/js/3las/util/3las.logging.js
index 12cdb1b..6b5906c 100644
--- a/web/js/3las/util/3las.logging.js
+++ b/web/js/3las/util/3las.logging.js
@@ -19,7 +19,7 @@ var Logging = /** @class */ (function () {
this.ParentElement.appendChild(line);
}
else {
- console.log(lineText);
+ //console.log(lineText);
}
};
return Logging;
diff --git a/web/js/main.js b/web/js/main.js
index b720e50..901b032 100644
--- a/web/js/main.js
+++ b/web/js/main.js
@@ -1,10 +1,21 @@
-$(document).ready(function() {
- var hostParts = window.location.host.split(':');
- var hostname = hostParts[0]; // Extract the hostname
- var port = hostParts[1] || '8080'; // Extract the port or use a default (e.g., 8080)
- var socketAddress = 'ws://' + hostname + ':' + port + '/text'; // Use 'wss' for secure WebSocket connections (recommended for external access)
- var socket = new WebSocket(socketAddress);
+var hostParts = window.location.host.split(':');
+var hostname = hostParts[0]; // Extract the hostname
+var port = hostParts[1] || '8080'; // Extract the port or use a default (e.g., 8080)
+var socketAddress = 'ws://' + hostname + ':' + port + '/text'; // Use 'wss' for secure WebSocket connections (recommended for external access)
+var socket = new WebSocket(socketAddress);
+
+const europe_programmes = [
+ "No PTY", "News", "Current Affairs", "Info",
+ "Sport", "Education", "Drama", "Culture", "Science", "Varied",
+ "Pop M", "Rock M", "Easy Listening", "Light Classical",
+ "Serious Classical", "Other Music", "Weather", "Finance",
+ "Children's Programmes", "Social Affairs", "Religion", "Phone-in",
+ "Travel", "Leisure", "Jazz Music", "Country Music", "National Music",
+ "Oldies Music", "Folk Music", "Documentary", "Alarm Test"
+];
+
+$(document).ready(function() {
var dataContainer = $('#data-container');
var canvas = $('#signal-canvas')[0];
var context = canvas.getContext('2d');
@@ -17,36 +28,6 @@ $(document).ready(function() {
var maxDataPoints = 300;
var pointWidth = (canvas.width - 80) / maxDataPoints;
- var europe_programmes = [
- "No PTY", "News", "Current Affairs", "Info",
- "Sport", "Education", "Drama", "Culture", "Science", "Varied",
- "Pop M", "Rock M", "Easy Listening", "Light Classical",
- "Serious Classical", "Other Music", "Weather", "Finance",
- "Children's Programmes", "Social Affairs", "Religion", "Phone-in",
- "Travel", "Leisure", "Jazz Music", "Country Music", "National Music",
- "Oldies Music", "Folk Music", "Documentary", "Alarm Test"
- ];
-
- function getInitialSettings() {
- $.ajax({
- url: '/static_data',
- dataType: 'json',
- success: function(data) {
- // Use the received data (data.qthLatitude, data.qthLongitude) as needed
- localStorage.setItem('qthLatitude', data.qthLatitude);
- localStorage.setItem('qthLongitude', data.qthLongitude);
- localStorage.setItem('webServerName', data.webServerName);
- localStorage.setItem('audioPort', data.audioPort);
- localStorage.setItem('streamEnabled', data.streamEnabled);
-
- document.title = 'FM-DX Webserver [' + data.webServerName + ']';
- },
- error: function(error) {
- console.error('Error:', error);
- }
- });
- }
-
getInitialSettings();
// Start updating the canvas
updateCanvas();
@@ -120,7 +101,7 @@ $(document).ready(function() {
context.fillStyle = color4;
context.font = '12px Titillium Web';
- const offset = signalToggle.prop('checked') ? 11.75 : 0;
+ const offset = signalToggle.prop('checked') ? 11.25 : 0;
context.textAlign = 'right';
context.fillText(`${(zoomMinValue - offset).toFixed(1)}`, 35, lowestY - 14);
context.fillText(`${(zoomMaxValue - offset).toFixed(1)}`, 35, highestY + 14);
@@ -136,37 +117,7 @@ $(document).ready(function() {
};
requestAnimationFrame(updateCanvas);
}
-
-
- function compareNumbers(a, b) {
- return a - b;
- }
-
- function escapeHTML(unsafeText) {
- let div = document.createElement('div');
- div.innerText = unsafeText;
- return div.innerHTML.replace(' ', ' ');
- }
-
- function processString(string, errors) {
- var output = '';
- const max_alpha = 70;
- const alpha_range = 50;
- const max_error = 10;
- errors = errors?.split(',');
-
- for (let i = 0; i < string.length; i++) {
- alpha = parseInt(errors[i]) * (alpha_range / (max_error + 1));
- if (alpha) {
- output += "
" + escapeHTML(string[i]) + "";
- } else {
- output += escapeHTML(string[i]);
- }
- }
-
- return output;
- }
-
+
function updatePanels(parsedData) {
const sortedAf = parsedData.af.sort(compareNumbers);
const scaledArray = sortedAf.map(element => element / 1000);
@@ -191,6 +142,14 @@ $(document).ready(function() {
$('#data-pi').html(parsedData.pi === '?' ? "
?" : parsedData.pi);
$('#data-ps').html(parsedData.ps === '?' ? "
?" : processString(parsedData.ps, parsedData.ps_errors));
$('#data-tp').html(parsedData.tp === false ? "
TP" : "TP");
+ $('#data-ta').html(parsedData.ta === 0 ? "
TA" : "TA");
+ $('#data-ms').html(parsedData.ms === 0
+ ? "
MS"
+ : (parsedData.ms === -1
+ ? "
MS"
+ : "
MS"
+ )
+ );
$('#data-pty').html(europe_programmes[parsedData.pty]);
$('#data-st').html(parsedData.st === false ? "
ST" : "ST");
$('#data-rt0').html(processString(parsedData.rt0, parsedData.rt0_errors));
@@ -203,7 +162,7 @@ $(document).ready(function() {
switch (signalUnit) {
case 'dbuv':
- signalValue = parsedData.signal - 11.75;
+ signalValue = parsedData.signal - 11.25;
signalText.text('dBµV');
break;
@@ -216,7 +175,6 @@ $(document).ready(function() {
signalText.text('dBf');
break;
}
- //const signalValue = signalToggle.is(':checked') ? (parsedData.signal - 11.75) : parsedData.signal;
const integerPart = Math.floor(signalValue);
const decimalPart = (signalValue - integerPart).toFixed(1).slice(1); // Adjusted this line
@@ -279,35 +237,20 @@ $(document).ready(function() {
});
document.onkeydown = checkKey;
+
+ $(window).on('wheel', function(e) {
+ var delta = e.originalEvent.deltaY;
- function checkKey(e) {
- e = e || window.event;
-
- getCurrentFreq();
-
- if (socket.readyState === WebSocket.OPEN) {
- if (e.keyCode == '38') {
- socket.send((currentFreq + 0.01).toFixed(2));
- }
- else if (e.keyCode == '40') {
- socket.send((currentFreq - 0.01).toFixed(2));
- }
- else if (e.keyCode == '37') {
- socket.send((currentFreq - 0.10).toFixed(1));
- }
- else if (e.keyCode == '39') {
- socket.send((currentFreq + 0.10).toFixed(1));
+ // Check if the scroll event originated from #af-list
+ if ($(e.target).closest('#af-list').length === 0) {
+ if (delta > 0) {
+ tuneDown();
+ } else {
+ tuneUp();
}
+ return false;
}
- }
-
- function getCurrentFreq() {
- currentFreq = $('#data-frequency').text();
- currentFreq = parseFloat(currentFreq).toFixed(3);
- currentFreq = parseFloat(currentFreq);
-
- return currentFreq;
- }
+ });
var freqUpButton = $('#freq-up')[0];
var freqDownButton = $('#freq-down')[0];
@@ -324,85 +267,161 @@ $(document).ready(function() {
$(freqContainer).on("click", function() {
textInput.focus();
});
+});
+
+function getInitialSettings() {
+ $.ajax({
+ url: '/static_data',
+ dataType: 'json',
+ success: function(data) {
+ // Use the received data (data.qthLatitude, data.qthLongitude) as needed
+ localStorage.setItem('qthLatitude', data.qthLatitude);
+ localStorage.setItem('qthLongitude', data.qthLongitude);
+ localStorage.setItem('webServerName', data.webServerName);
+ localStorage.setItem('audioPort', data.audioPort);
+ localStorage.setItem('streamEnabled', data.streamEnabled);
+
+ document.title = 'FM-DX Webserver [' + data.webServerName + ']';
+ },
+ error: function(error) {
+ console.error('Error:', error);
+ }
+ });
+}
+function compareNumbers(a, b) {
+ return a - b;
+}
+
+function escapeHTML(unsafeText) {
+ let div = document.createElement('div');
+ div.innerText = unsafeText;
+ return div.innerHTML.replace(' ', ' ');
+}
+
+function processString(string, errors) {
+ var output = '';
+ const max_alpha = 70;
+ const alpha_range = 50;
+ const max_error = 10;
+ errors = errors?.split(',');
- function tuneUp() {
- if (socket.readyState === WebSocket.OPEN) {
- getCurrentFreq();
+ for (let i = 0; i < string.length; i++) {
+ alpha = parseInt(errors[i]) * (alpha_range / (max_error + 1));
+ if (alpha) {
+ output += "
" + escapeHTML(string[i]) + "";
+ } else {
+ output += escapeHTML(string[i]);
+ }
+ }
+
+ return output;
+}
+
+function getCurrentFreq() {
+ currentFreq = $('#data-frequency').text();
+ currentFreq = parseFloat(currentFreq).toFixed(3);
+ currentFreq = parseFloat(currentFreq);
+
+ return currentFreq;
+}
+
+function checkKey(e) {
+ e = e || window.event;
+
+ getCurrentFreq();
+
+ if (socket.readyState === WebSocket.OPEN) {
+ if (e.keyCode == '38') {
+ socket.send((currentFreq + 0.01).toFixed(2));
+ }
+ else if (e.keyCode == '40') {
+ socket.send((currentFreq - 0.01).toFixed(2));
+ }
+ else if (e.keyCode == '37') {
+ socket.send((currentFreq - 0.10).toFixed(1));
+ }
+ else if (e.keyCode == '39') {
socket.send((currentFreq + 0.10).toFixed(1));
}
}
-
- function tuneDown() {
- if (socket.readyState === WebSocket.OPEN) {
- getCurrentFreq();
- socket.send((currentFreq - 0.10).toFixed(1));
- }
+}
+
+function tuneUp() {
+ if (socket.readyState === WebSocket.OPEN) {
+ getCurrentFreq();
+ socket.send((currentFreq + 0.10).toFixed(1));
}
+}
+
+function tuneDown() {
+ if (socket.readyState === WebSocket.OPEN) {
+ getCurrentFreq();
+ socket.send((currentFreq - 0.10).toFixed(1));
+ }
+}
+
+async function copyPs() {
+ var frequency = $('#data-frequency').text();
+ var pi = $('#data-pi').text();
+ var ps = $('#data-ps').text();
+ var signal = $('#data-signal').text();
+ var signalDecimal = $('#data-signal-decimal').text();
+ var signalUnit = $('#signal-units').text();
- async function copyPs() {
- var frequency = $('#data-frequency').text();
- var pi = $('#data-pi').text();
- var ps = $('#data-ps').text();
- var signal = $('#data-signal').text();
- var signalDecimal = $('#data-signal-decimal').text();
- var signalUnit = $('#signal-units').text();
+ try {
+ await copyToClipboard(frequency + " - " + pi + " | " + ps + " [" + signal + signalDecimal + " " + signalUnit + "]");
+ } catch(error) {
+ console.error(error);
+ }
+}
+
+async function copyRt() {
+ var rt0 = $('#data-rt0').text();
+ var rt1 = $('#data-rt1').text();
+
+ try {
+ await copyToClipboard("[0] RT: " + rt0 + "\n[1] RT: " + rt1);
+ } catch(error) {
+ console.error(error);
+ }
+}
+
+function copyToClipboard(textToCopy) {
+ // Navigator clipboard api needs a secure context (https)
+ if (navigator.clipboard && window.isSecureContext) {
+ navigator.clipboard.writeText(textToCopy)
+ .catch(function(err) {
+ console.error('Error:', err);
+ });
+ } else {
+ var textArea = $('
');
+ textArea.val(textToCopy);
+ textArea.css({
+ 'position': 'absolute',
+ 'left': '-999999px'
+ });
+
+ $('body').prepend(textArea);
+ textArea.select();
try {
- await copyToClipboard(frequency + " - " + pi + " | " + ps + " [" + signal + signalDecimal + " " + signalUnit + "]");
- } catch(error) {
- console.error(error);
+ document.execCommand('copy');
+ } catch (error) {
+ console.error('Error:', error);
+ } finally {
+ textArea.remove();
}
}
+}
+
+function findOnMaps() {
+ var frequency = $('#data-frequency').text();
+ var pi = $('#data-pi').text();
+ var latitude = localStorage.getItem('qthLongitude');
+ var longitude = localStorage.getItem('qthLatitude');
+ frequency = parseFloat(frequency).toFixed(1);
- async function copyRt() {
- var rt0 = $('#data-rt0').text();
- var rt1 = $('#data-rt1').text();
-
- try {
- await copyToClipboard("[0] RT: " + rt0 + "\n[1] RT: " + rt1);
- } catch(error) {
- console.error(error);
- }
- }
-
-
- function findOnMaps() {
- var frequency = $('#data-frequency').text();
- var pi = $('#data-pi').text();
- var latitude = localStorage.getItem('qthLongitude');
- var longitude = localStorage.getItem('qthLatitude');
- frequency = parseFloat(frequency).toFixed(1);
-
- var url = "https://maps.fmdx.pl/#qth=" + longitude + "," + latitude + "&freq=" + frequency + "&pi=" + pi;
- window.open(url, "_blank");
- }
-
- function copyToClipboard(textToCopy) {
- // Navigator clipboard api needs a secure context (https)
- if (navigator.clipboard && window.isSecureContext) {
- navigator.clipboard.writeText(textToCopy)
- .catch(function(err) {
- console.error('Error:', err);
- });
- } else {
- var textArea = $('
');
- textArea.val(textToCopy);
- textArea.css({
- 'position': 'absolute',
- 'left': '-999999px'
- });
-
- $('body').prepend(textArea);
- textArea.select();
-
- try {
- document.execCommand('copy');
- } catch (error) {
- console.error('Error:', error);
- } finally {
- textArea.remove();
- }
- }
- }
-});
\ No newline at end of file
+ var url = "https://maps.fmdx.pl/#qth=" + longitude + "," + latitude + "&freq=" + frequency + "&pi=" + pi;
+ window.open(url, "_blank");
+}
\ No newline at end of file
diff --git a/web/js/settings.js b/web/js/settings.js
index 1cc73c7..1d29b2d 100644
--- a/web/js/settings.js
+++ b/web/js/settings.js
@@ -1,21 +1,21 @@
/* Themes */
const themes = {
- theme1: ['#1d1838', '#8069fa'],
- theme2: ['#381818', '#ff7070'],
+ theme1: ['#111', '#aaa'],
+ theme2: ['#1f0c0c', '#ff7070'],
theme3: ['#121c0c', '#a9ff70'],
theme4: ['#0c1c1b', '#68f7ee'],
theme5: ['#171106', '#f5b642'],
theme6: ['#21091d', '#ed51d3'],
- theme7: ['#111', '#aaa']
+ theme7: ['#1d1838', '#8069fa'],
+ theme8: ['#000', '#888'],
};
-function setTheme(themeName) {
- const themeColors = themes[themeName];
- if (themeColors) {
- $(':root').css('--color-main', themeColors[0]);
- $(':root').css('--color-main-bright', themeColors[1]);
- }
-}
+/* Signal Units */
+const signalUnits = {
+ dbf: ['dBf'],
+ dbuv: ['dBµV'],
+ dbm: ['dBm'],
+};
$(document).ready(() => {
const themeSelector = $('#theme-selector');
@@ -31,16 +31,7 @@ $(document).ready(() => {
setTheme(selectedTheme);
localStorage.setItem('theme', selectedTheme);
});
-});
-/* Signal Units */
-const signalUnits = {
- dbf: ['dBf'],
- dbuv: ['dBµV'],
- dbm: ['dBm'],
-};
-
-$(document).ready(() => {
const signalSelector = $('#signal-selector');
if (localStorage.getItem('signalUnit')) {
@@ -51,4 +42,12 @@ $(document).ready(() => {
const selectedSignalUnit = event.target.value;
localStorage.setItem('signalUnit', selectedSignalUnit);
});
-});
\ No newline at end of file
+});
+
+function setTheme(themeName) {
+ const themeColors = themes[themeName];
+ if (themeColors) {
+ $(':root').css('--color-main', themeColors[0]);
+ $(':root').css('--color-main-bright', themeColors[1]);
+ }
+}