mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2026-04-29 18:25:58 +00:00
Propagation conditions page #92
This commit is contained in:
@@ -33,16 +33,16 @@ SOLAR_STORM_SCALES = [
|
||||
]
|
||||
|
||||
GEOMAG_STORM_DESCRIPTIONS = [
|
||||
(9, "Solar storm. Complete HF blackout, S30+ noise"),
|
||||
(8, "Solar storm. HF sporadic only, S20-30 noise"),
|
||||
(7, "Solar storm. HF intermittent, S9-20 noise"),
|
||||
(6, "Solar storm. HF fading at higher latitudes, S6-9 noise"),
|
||||
(5, "Solar storm. HF fading at higher latitudes, S4-6 noise"),
|
||||
(4, "Active. Minor HF fading at higher latitudes, S2-3 noise"),
|
||||
(3, "Unsettled. Minor HF fading at higher latitudes, S2-3 noise"),
|
||||
(2, "Inactive. No impact, S0-2 noise"),
|
||||
(1, "Quiet. No impact, S0-2 noise"),
|
||||
(0, "Quiet. No impact, S0-2 noise"),
|
||||
(9, "Complete HF blackout"),
|
||||
(8, "HF sporadic only"),
|
||||
(7, "HF intermittent"),
|
||||
(6, "HF fading at higher latitudes"),
|
||||
(5, "HF fading at higher latitudes"),
|
||||
(4, "Minor HF fading at higher latitudes"),
|
||||
(3, "Minor HF fading at higher latitudes"),
|
||||
(2, "No impact"),
|
||||
(1, "No impact"),
|
||||
(0, "No impact"),
|
||||
]
|
||||
|
||||
GEOMAG_STORM_SCALES = [
|
||||
|
||||
@@ -97,7 +97,7 @@ class HamQSL(HTTPSolarConditionsProvider):
|
||||
"aurora_latitude": float_val("latdegree"),
|
||||
"solar_wind": float_val("solarwind"),
|
||||
"magnetic_field": float_val("magneticfield"),
|
||||
"geomag_field": text("geomagfield"),
|
||||
"geomag_field": (lambda v: "Unsettled" if v == "Unsettld" else v)(text("geomagfield").title()) if text("geomagfield") else None,
|
||||
"geomag_noise": text("signalnoise"),
|
||||
"hf_conditions": hf_conditions,
|
||||
"vhf_conditions": vhf_conditions
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
<p>This software is dedicated to the memory of Tom G1PJB, SK, a friend and colleague who sadly passed away around the time I started writing it in Autumn 2025. I was looking forward to showing it to you when it was done.</p>
|
||||
</div>
|
||||
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-about").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -69,8 +69,8 @@
|
||||
|
||||
</div>
|
||||
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/add-spot.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/add-spot.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-add-spot").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -56,8 +56,8 @@
|
||||
|
||||
</div>
|
||||
|
||||
<script src="/js/common.js?v=1774699419"></script>
|
||||
<script src="/js/alerts.js?v=1774699419"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/alerts.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-alerts").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -62,9 +62,9 @@
|
||||
<script>
|
||||
let spotProvidersEnabledByDefault = {% raw json_encode(web_ui_options["spot-providers-enabled-by-default"]) %};
|
||||
</script>
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774699418"></script>
|
||||
<script src="/js/bands.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774768423"></script>
|
||||
<script src="/js/bands.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-bands").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -46,10 +46,10 @@
|
||||
crossorigin="anonymous"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/tinycolor2@1.6.0/cjs/tinycolor.min.js"></script>
|
||||
|
||||
<script src="https://misc.ianrenton.com/jsutils/utils.js?v=1774699418"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/storage.js?v=1774699418"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/ui-ham.js?v=1774699418"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/geo.js?v=1774699418"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/utils.js?v=1774768423"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/storage.js?v=1774768423"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/ui-ham.js?v=1774768423"></script>
|
||||
<script src="https://misc.ianrenton.com/jsutils/geo.js?v=1774768423"></script>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -3,25 +3,91 @@
|
||||
|
||||
<div class="card mt-5">
|
||||
<div class="card-header">
|
||||
Propagation
|
||||
Band Conditions
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="row row-cols-1 row-cols-md-2 g-3">
|
||||
<div class="col">
|
||||
<div class="card h-100">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">HF Conditions</h5>
|
||||
<h5 class="card-title">HF</h5>
|
||||
<table class="table table-sm mt-2">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Band</th>
|
||||
<th>Day</th>
|
||||
<th>Night</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>80-40m</td>
|
||||
<td id="hf-conditions-80m-40m-day"></td>
|
||||
<td id="hf-conditions-80m-40m-night"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>30-20m</td>
|
||||
<td id="hf-conditions-30m-20m-day"></td>
|
||||
<td id="hf-conditions-30m-20m-night"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>17-15m</td>
|
||||
<td id="hf-conditions-17m-15m-day"></td>
|
||||
<td id="hf-conditions-17m-15m-night"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>12-10m</td>
|
||||
<td id="hf-conditions-12m-10m-day"></td>
|
||||
<td id="hf-conditions-12m-10m-night"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col">
|
||||
<div class="card h-100">
|
||||
<div class="card-body">
|
||||
<h5 class="card-title">VHF Conditions</h5>
|
||||
<h5 class="card-title">VHF</h5>
|
||||
<table class="table table-sm mt-2">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Propagation Mode</th>
|
||||
<th>Condition</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Sporadic-E 6m (Europe)</td>
|
||||
<td id="vhf-conditions-es-6m-eu"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Sporadic-E 4m (Europe)</td>
|
||||
<td id="vhf-conditions-es-4m-eu"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Sporadic-E 2m (Europe)</td>
|
||||
<td id="vhf-conditions-es-2m-eu"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Sporadic-E 2m (North America)</td>
|
||||
<td id="vhf-conditions-es-2m-na"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Aurora (Northern Hemisphere)</td>
|
||||
<td id="vhf-conditions-aurora"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Aurora Minimum Latitude</td>
|
||||
<td id="vhf-conditions-aurora-lat"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-text mt-2">Data from <a href="https://hamqsl.net">HamQSL.net</a>.</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -34,8 +100,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/conditions.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/conditions.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-conditions").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -70,9 +70,9 @@
|
||||
<script>
|
||||
let spotProvidersEnabledByDefault = {% raw json_encode(web_ui_options["spot-providers-enabled-by-default"]) %};
|
||||
</script>
|
||||
<script src="/js/common.js?v=1774699419"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774699419"></script>
|
||||
<script src="/js/map.js?v=1774699419"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774768423"></script>
|
||||
<script src="/js/map.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-map").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -87,9 +87,9 @@
|
||||
<script>
|
||||
let spotProvidersEnabledByDefault = {% raw json_encode(web_ui_options["spot-providers-enabled-by-default"]) %};
|
||||
</script>
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774699418"></script>
|
||||
<script src="/js/spots.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/spotsbandsandmap.js?v=1774768423"></script>
|
||||
<script src="/js/spots.js?v=1774768423"></script>
|
||||
<script>$(document).ready(function() { $("#nav-link-spots").addClass("active"); }); <!-- highlight active page in nav --></script>
|
||||
|
||||
{% end %}
|
||||
@@ -59,8 +59,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="/js/common.js?v=1774699418"></script>
|
||||
<script src="/js/status.js?v=1774699418"></script>
|
||||
<script src="/js/common.js?v=1774768423"></script>
|
||||
<script src="/js/status.js?v=1774768423"></script>
|
||||
<script>
|
||||
$(document).ready(function() { $("#nav-link-status").addClass("active"); }); <!-- highlight active page in nav -->
|
||||
</script>
|
||||
|
||||
@@ -1,7 +1,37 @@
|
||||
// Load solar conditions
|
||||
function loadSolarConditions() {
|
||||
$.getJSON('/api/v1/solar', function(jsonData) {
|
||||
const hfConditionClass = { 'Good': 'table-success', 'Fair': 'table-warning', 'Poor': 'table-danger' };
|
||||
|
||||
if (jsonData.hf_conditions) {
|
||||
jsonData.hf_conditions.forEach(function(entry) {
|
||||
const cell = $('#hf-conditions-' + entry.band + '-' + entry.time);
|
||||
cell.text(entry.condition);
|
||||
const cls = hfConditionClass[entry.condition];
|
||||
if (cls) { cell.addClass(cls); }
|
||||
});
|
||||
}
|
||||
|
||||
const vhfIdMap = {
|
||||
'vhf-aurora|northern_hemi': 'vhf-conditions-aurora',
|
||||
'E-Skip|europe_6m': 'vhf-conditions-es-6m-eu',
|
||||
'E-Skip|europe_4m': 'vhf-conditions-es-4m-eu',
|
||||
'E-Skip|europe': 'vhf-conditions-es-2m-eu',
|
||||
'E-Skip|north_america':'vhf-conditions-es-2m-na',
|
||||
};
|
||||
if (jsonData.vhf_conditions) {
|
||||
jsonData.vhf_conditions.forEach(function(entry) {
|
||||
const id = vhfIdMap[entry.phenomenon + '|' + entry.location];
|
||||
if (id) {
|
||||
const cell = $('#' + id);
|
||||
cell.text(entry.condition);
|
||||
cell.addClass(entry.condition === 'Band Closed' ? 'table-danger' : 'table-success');
|
||||
}
|
||||
});
|
||||
}
|
||||
if (jsonData.aurora_latitude !== null && jsonData.aurora_latitude !== undefined) {
|
||||
$('#vhf-conditions-aurora-lat').text(jsonData.aurora_latitude + '°');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user