kopia lustrzana https://github.com/dl9rdz/rdz_ttgo_sonde
Build @ Thu May 16 21:33:54 CEST 2024
rodzic
eacd92c742
commit
8bdccc09ae
|
@ -0,0 +1,2 @@
|
|||
fix AXP2101 battery voltage
|
||||
fix AXP2101 battery voltage
|
Plik binarny nie jest wyświetlany.
|
@ -1 +1 @@
|
|||
<html><body><p>devel20240316-B17</p></body></html>
|
||||
<html><body><p>devel20240514-B17</p></body></html>
|
||||
|
|
|
@ -1,324 +1,3 @@
|
|||
cfg.js 8061
|
||||
var cfgs = [
|
||||
[ "", "General configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/General-configuration" ],
|
||||
[ "wifi", "Wifi mode (0=off, 1=client, 2=AP, 3=client or AP, 4=client-noscan)" ],
|
||||
[ "mdnsname", "Network mDNS name"],
|
||||
[ "ephftp", "FTP server for ephemeris data (RS92 decoder)"],
|
||||
[ "debug", "Debug mode (0/1)" ],
|
||||
[ "maxsonde", "Maximum number of QRG entries (must be ≤ 50)" ],
|
||||
[ "rxlat", "Receiver fixed latitude"],
|
||||
[ "rxlon", "Receiver fixed longitude"],
|
||||
[ "rxalt", "Receiver fixed altitude"],
|
||||
[ "", "OLED/TFT display configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Display-configuration" ],
|
||||
[ "screenfile", "Screen config (0=automatic; 1-5=predefined; other=custom)" ],
|
||||
[ "display", "Display screens (scan, default, ...)" ],
|
||||
[ "dispsaver", "Display saver (0=never/1=always/2=ifnorx [+10*n: after n sec.])" ],
|
||||
[ "dispcontrast", "OLED contrast (-1=use default; 0..255=set contrast)" ],
|
||||
[ "norx_timeout", "No-RX-timeout in seconds (-1=disabled)"],
|
||||
[ "tft_orient", "TFT orientation (0/1/2/3), OLED flip: 3"],
|
||||
[ "", "Spectrum display configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Spectrum-configuration" ],
|
||||
[ "spectrum", "Show spectrum on start (-1=no, 0=forever, >0=time [sec])" ],
|
||||
[ "startfreq", "Start frequency (MHz, default 400)" ],
|
||||
[ "channelbw", "Bandwidth (kHz)" ],
|
||||
[ "marker", "Spectrum MHz marker" ], // maybe remove, assume always ==1?
|
||||
[ "noisefloor", "Spectrum noisefloor" ],
|
||||
[ "", "Receiver configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Receiver-configuration" ],
|
||||
[ "freqofs", "RX frequency offset (Hz)"],
|
||||
[ "rs41.agcbw", "RS41 AGC bandwidth"],
|
||||
[ "rs41.rxbw", "RS41 RX bandwidth"],
|
||||
[ "rs92.rxbw", "RS92 RX (and AGC) bandwidth"],
|
||||
[ "rs92.alt2d", "RS92 2D fix default altitude"],
|
||||
[ "dfm.agcbw", "DFM AGC bandwidth"],
|
||||
[ "dfm.rxbw", "DFM RX bandwidth"],
|
||||
[ "m10m20.agcbw", "M10/M20 AGC bandwidth"],
|
||||
[ "m10m20.rxbw", "M10/M20 RX bandwidth"],
|
||||
[ "mp3h.agcbw", "MP3H AGC bandwidth"],
|
||||
[ "mp3h.rxbw", "MP3H RX bandwidth"],
|
||||
[ "", "KISS TNC/AXUDP/AXTCP data feed configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Data-feed-configuration"],
|
||||
[ "call", "Call"],
|
||||
[ "passcode", "Passcode"],
|
||||
[ "kisstnc.active", "KISS TNC (port 14590) (needs reboot)"],
|
||||
[ "axudp.active", "AXUDP active"],
|
||||
[ "axudp.host", "AXUDP host"],
|
||||
[ "axudp.port", "AXUDP port"],
|
||||
[ "axudp.highrate", "Rate limit"],
|
||||
[ "tcp.active", "APRS TCP active"],
|
||||
[ "tcp.timeout", "APRS TCP timeout [s] (0=off, 25=on)"],
|
||||
[ "tcp.host", "APRS TCP host"],
|
||||
[ "tcp.port", "APRS TCP port"],
|
||||
[ "tcp.highrate", "Rate limit"],
|
||||
[ "tcp.objcall", "APRS object call"],
|
||||
[ "tcp.beaconsym", "APRS tracker symbol"],
|
||||
[ "tcp.chase", "APRS location reporting (0=off, 1=fixed, 2=chase/GPS, 3=auto)"],
|
||||
[ "tcp.comment", "APRS location comment"],
|
||||
[ "", "MQTT data feed configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/MQTT-configuration"],
|
||||
[ "mqtt.active", "MQTT active (needs reboot)"],
|
||||
[ "mqtt.id", "MQTT client ID"],
|
||||
[ "mqtt.host", "MQTT server hostname"],
|
||||
[ "mqtt.port", "MQTT port"],
|
||||
[ "mqtt.username", "MQTT username"],
|
||||
[ "mqtt.password", "MQTT password"],
|
||||
[ "mqtt.prefix", "MQTT prefix"],
|
||||
[ "", "Chasemapper settings", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Chasemapper-configuration"],
|
||||
[ "cm.active", "Chasemapper active (0=disabled, 1=active)"],
|
||||
[ "cm.host", "Chasemapper UDP host"],
|
||||
[ "cm.port", "Chasemapper UDP port"],
|
||||
[ "", "SondeHub settings", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/SondeHub-settings"],
|
||||
[ "sondehub.active", "SondeHub reporting (0=disabled, 1=active)"],
|
||||
[ "sondehub.chase", "SondeHub location reporting (0=off, 1=fixed, 2=chase/GPS, 3=auto)"],
|
||||
[ "sondehub.host", "SondeHub host (DO NOT CHANGE)"],
|
||||
[ "sondehub.callsign", "Callsign"],
|
||||
[ "sondehub.antenna", "Antenna (optional, visisble on SondeHub tracker)"],
|
||||
[ "sondehub.email", "SondeHub email (optional, only used to contact in case of upload errors)"],
|
||||
[ "", "SondeHub frequency import", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/SondeHub-import" ],
|
||||
[ "sondehub.fiactive", "SondeHub frequency import active (0=disabled, 1=active)" ],
|
||||
[ "sondehub.fiinterval", "Import frequency (minutes, ≥ 5)" ],
|
||||
[ "sondehub.fimaxdist", "Import maximum distance (km, ≤ 700)" ],
|
||||
[ "sondehub.fimaxage", "Import maximum age (hours, ≤ 48)" ],
|
||||
[ "", "Hardware configuration (requires reboot)", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Hardware-configuration"],
|
||||
[ "disptype", "Display type (0=OLED/SSD1306, 1=ILI9225, 2=OLED/SH1106, 3=ILI9341, 4=ILI9342, 5=ST7789)"],
|
||||
[ "oled_sda", "OLED SDA/TFT SDA"],
|
||||
[ "oled_scl", "OLED SCL/TFT CLK"],
|
||||
[ "oled_rst", "OLED RST/TFT RST (needs reboot)"],
|
||||
[ "tft_rs", "TFT RS"],
|
||||
[ "tft_cs", "TFT CS"],
|
||||
[ "tft_spifreq", "TFT SPI speed"],
|
||||
[ "button_pin", "Button input port"],
|
||||
[ "button2_pin", "Button 2 input port"],
|
||||
[ "button2_axp", "Use AXP192 PWR as Button 2"],
|
||||
[ "touch_thresh", "Touch button threshold<br>(0 for calib mode)"],
|
||||
[ "power_pout", "Power control port"],
|
||||
[ "led_pout", "LED output port"],
|
||||
[ "gps_rxd", "GPS RXD pin (-1 to disable)"],
|
||||
[ "gps_txd", "GPS TXD pin (not really needed)"],
|
||||
[ "batt_adc", "Battery measurement pin"],
|
||||
[ "sx1278_ss", "SX1278 SS"],
|
||||
[ "sx1278_miso", "SX1278 MISO"],
|
||||
[ "sx1278_mosi", "SX1278 MOSI"],
|
||||
[ "sx1278_sck", "SX1278 SCK"],
|
||||
];
|
||||
|
||||
function mkcfg(id, key, label, value) {
|
||||
var s = "<tr style=\"visibility: collapse;\" class=\"cfgpanel\"><td>" + label + "</td><td><input name=\"" + key + "\" type=\"text\" value=\"" + value + "\"/></td></tr>\n";
|
||||
return s;
|
||||
}
|
||||
function mkcfgbtn(id, key, label, value) {
|
||||
var touch = "";
|
||||
var v = value;
|
||||
if(v != -1 && (v&128)) {
|
||||
touch = " checked";
|
||||
v = v & 127;
|
||||
}
|
||||
var s = "<tr style=\"visibility:collapse\" class=\"cfgpanel\"><td>" + label + "</td><td><input name=\"" + key + "\" type=\"text\" size=\"3\" value=\"" + v + "\"/>";
|
||||
s += "<input type=\"checkbox\" name=\"" + key + "#\" "+touch+"> Touch</td></tr>\n";
|
||||
return s;
|
||||
}
|
||||
|
||||
function mksep(id,label,url) {
|
||||
return "<tr class=\"cfgheader\"><th class=\"cfg\" align=\"left\" colspan=\"2\">"+label+" <a href=\""+url+"\" target=\”_blank\">[wiki]</a></th></tr>\n";
|
||||
}
|
||||
function rowdisp(id,disp) {
|
||||
var matches = document.querySelectorAll("tr."+id);
|
||||
matches.forEach(function(e) { if(disp) e.hidden=true; else e.removeAttribute('hidden');});
|
||||
hid=id; nid="N"+id;
|
||||
if(!disp) { hid=nid; nid=id; }
|
||||
document.querySelector("span."+hid).hidden=true;
|
||||
document.querySelector("span."+nid).removeAttribute('hidden');
|
||||
}
|
||||
function configTable() {
|
||||
// iterate over cfgs
|
||||
var tab = "<table width=\"100%\"><tr><th>Option</th><th>Value</th></tr>\n";
|
||||
var id=0;
|
||||
for(i=0; i<cfgs.length; i++) {
|
||||
var key = cfgs[i][0];
|
||||
var lbl = cfgs[i][1];
|
||||
if(key) {
|
||||
if(key=="button_pin" || key=="button2_pin") {
|
||||
tab += mkcfgbtn("s"+id, key, lbl, cf.get(key));
|
||||
} else if (key=="display") {
|
||||
tab += mkcfg("s"+id, key, lbl, cf.get(key));
|
||||
tab += "<tr style=\"visibility:collapse\" class=\"cfgpanel\"><td>"+scr+"</td><td></td></tr>"
|
||||
} else {
|
||||
tab += mkcfg("s"+id, key, lbl, cf.get(key));
|
||||
}
|
||||
} else {
|
||||
id++;
|
||||
tab += mksep("s"+id, lbl, cfgs[i][2]);
|
||||
}
|
||||
}
|
||||
tab += "</table>";
|
||||
var cfgdiv = document.getElementById("cfgtab");
|
||||
cfgdiv.innerHTML = tab;
|
||||
// enable collapse / expand of items below a header
|
||||
var acc = document.getElementsByClassName("cfgheader");
|
||||
for(i=0; i<acc.length; i++) {
|
||||
acc[i].firstChild.innerHTML = "[+] " + acc[i].firstChild.innerHTML;
|
||||
acc[i].addEventListener("click", function(e) {
|
||||
if(e.target.nodeName=="A") return;
|
||||
achar = "[+]";
|
||||
if(this.classList.toggle("active")) achar = "[\u2212]";
|
||||
this.firstChild.innerHTML = achar + this.firstChild.innerHTML.substring(3);
|
||||
var panel = this;
|
||||
console.log(panel);
|
||||
while( panel = panel.nextElementSibling) {
|
||||
console.log(panel);
|
||||
if ( panel.className!="cfgpanel") { break; }
|
||||
if(panel.style.visibility==="collapse") {
|
||||
panel.style.visibility="visible";
|
||||
} else {
|
||||
console.log("none");
|
||||
panel.style.visibility="collapse";
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
acc[0].click();
|
||||
}
|
||||
livemap.html 720
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>rdzTTGOSonde Server LiveMap</title>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
||||
<link rel="stylesheet" type="text/css" href="style.css" />
|
||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.8.0/dist/leaflet.css" />
|
||||
<script>var mapcenter=[%MAPCENTER%];</script>
|
||||
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
|
||||
<script src="https://unpkg.com/leaflet@1.8.0/dist/leaflet.js"></script>
|
||||
<script src="https://unpkg.com/leaflet.marker.slideto@0.2.0/Leaflet.Marker.SlideTo.js"></script>
|
||||
<script src="livemap.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
</body>
|
||||
</html>
|
||||
map.html 1206
|
||||
<html>
|
||||
<head>
|
||||
<script>
|
||||
maptype = "SH"; // TODO: Get from config
|
||||
|
||||
const maps = {
|
||||
"WS": ["https://www.wettersonde.net/map.php", (s)=>"?sonde="+s, (lat,lon)=>""],
|
||||
"SH": ["https://sondehub.org/", (s)=>s, (lat,lon)=>'#!mz=8&mc=' + lat + ',' + lon],
|
||||
"RS": ["https://radiosondy.info/", (s)=>"sonde.php?sondenumber="+s, (lat,lon)=>""],
|
||||
"OW": ["https://v2.openwx.de/start.php", (s)=>"?sonde="+s, (lat,lon)=>"?mode=mobile"],
|
||||
};
|
||||
|
||||
data = ["T4420541",63.5,-20.0];
|
||||
document.addEventListener("DOMContentLoaded", function(){
|
||||
fetch('live.json')
|
||||
.then((response) => response.json())
|
||||
.then((data) => {
|
||||
if (data.gps===undefined) { data.gps={} };
|
||||
console.log(data.gps.lat, data.gps.lon, data.sonde.ser);
|
||||
if( (data.sonde.ser||'')=='' && !(data.gps.lat===undefined) ) {
|
||||
urlarg = maps[maptype][2](data.gps.lat, data.gps.lon);
|
||||
} else {
|
||||
urlarg = maps[maptype][1](data.sonde.ser||'');
|
||||
}
|
||||
iftxt='<iframe src="' + maps[maptype][0] + urlarg + '" style="border:1px solid #00A3D3;border-radius:20px;height:98vh;width:100%"></iframe>';
|
||||
document.getElementsByTagName('body')[0].innerHTML = iftxt;
|
||||
})
|
||||
})
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
||||
rdz.js 1843
|
||||
let stypes=new Map();
|
||||
stypes.set('4', 'RS41');
|
||||
stypes.set('R', 'RS92');
|
||||
stypes.set('D', 'DFM');
|
||||
stypes.set('M', 'M10/M20');
|
||||
stypes.set('3', 'MP3H');
|
||||
|
||||
function footer() {
|
||||
document.addEventListener("DOMContentLoaded", function(){
|
||||
var form = document.querySelector(".wrapper");
|
||||
form.addEventListener("input", function() {
|
||||
document.querySelector(".save").disabled = false;
|
||||
});
|
||||
document.querySelector(".save").disabled = true;
|
||||
});
|
||||
}
|
||||
|
||||
/* Used by qrg.html in RX_FSK.ino */
|
||||
function prep() {
|
||||
var stlist=document.querySelectorAll("input.stype");
|
||||
for(txt of stlist){
|
||||
var val=txt.getAttribute('value'); var nam=txt.getAttribute('name');
|
||||
if(val=='2') { val='M'; }
|
||||
var sel=document.createElement('select');
|
||||
sel.setAttribute('name',nam);
|
||||
for(stype of stypes) {
|
||||
var opt=document.createElement('option');
|
||||
opt.value=stype[0];
|
||||
opt.innerHTML=stype[1];
|
||||
if(stype[0]==val) { opt.setAttribute('selected','selected'); }
|
||||
sel.appendChild(opt);
|
||||
}
|
||||
txt.replaceWith(sel);
|
||||
}
|
||||
}
|
||||
|
||||
function qrgTable() {
|
||||
var tab=document.getElementById("divTable");
|
||||
|
||||
var table = "<table><tr><th>Ch</th><th>Active</th><th>Frequency</th><th>Decoder</th><th>Launchsite</th></tr>";
|
||||
for(i=0; i<qrgs.length; i++) {
|
||||
var ck = "";
|
||||
if(qrgs[i][0]) ck="checked";
|
||||
table += "<tr><td class=\"ch\">" + (i+1) + "</td><td class=\"act\"><input name=\"A" + (i+1) + "\" type=\"checkbox\" " + ck + "/></td>";
|
||||
table += "<td><input name=\"F" + (i+1) + "\" type=\"text\" size=7 value=\"" + qrgs[i][1] + "\"></td>";
|
||||
table += "<td><input class=\"stype\" name=\"T" + (i+1) + "\" value=\"" + qrgs[i][3] + "\"></td>";
|
||||
table += "<td><input name=\"S" + (i+1) + "\" type=\"text\" value=\"" + qrgs[i][2] +"\"></td></tr>";
|
||||
}
|
||||
table += "</table>";
|
||||
tab.innerHTML = table;
|
||||
prep();
|
||||
footer();
|
||||
}
|
||||
|
||||
upd.html 1353
|
||||
<html><head>
|
||||
<link rel="stylesheet" type="text/css" href="style.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<form action="update.html" method="post"><p>Currently installed: %FULLNAMEID%</p>
|
||||
<p>
|
||||
Available master: <span id="masterDiv">(...checking...)</span>
|
||||
|
||||
<br>
|
||||
Available devel: <span id="develDiv">(...checking...)</span>
|
||||
|
||||
</p>
|
||||
<input type="submit" name="master" value="Master-Update"></input><br>
|
||||
<input type="submit" name="devel" value="Devel-Update"><br>
|
||||
<p>Note: If suffix is the same, update should work fully. If the number is different, update contains changes in the file system. A full re-flash is required to get all new features, but the update should not break anything. If the letter is different, a full re-flash is mandatory, update will not work</p></form>
|
||||
|
||||
<script>
|
||||
const masterInfo = document.getElementById('masterDiv');
|
||||
const develInfo = document.getElementById('develDiv');
|
||||
|
||||
let request = new XMLHttpRequest();
|
||||
request.open('GET', 'http://rdzsonde.mooo.com/master/update-info.html');
|
||||
request.onload = function() {
|
||||
masterInfo.innerHTML = request.response.replace(/<[^>]*>/g, '');
|
||||
}
|
||||
request.send();
|
||||
let drequest = new XMLHttpRequest();
|
||||
drequest.open('GET', 'http://rdzsonde.mooo.com/devel/update-info.html');
|
||||
drequest.onload = function() {
|
||||
develInfo.innerHTML= drequest.response.replace(/<[^>]*>/g, '');;
|
||||
}
|
||||
drequest.send();
|
||||
</script>
|
||||
</body></html>
|
||||
livemap.js 19784
|
||||
try {
|
||||
var check = $(document);
|
||||
|
@ -763,7 +442,7 @@ map.addControl(new L.Control.Button([ { position:'topright', text: '⚙️', hre
|
|||
'<b>Open:</b> <a href="https://www.google.de/maps/?q='+lat+', '+lon+'" target="_blank">GMaps</a> | <a href="https://www.openstreetmap.org/?mlat='+lat+'&mlon='+lon+'&zoom=15" target="_blank">OSM</a> | <a href="geo://'+lat+','+lon+'">GeoApp</a>';
|
||||
|
||||
if (t == 'position') { return '<div class="i_position"><b>🎈 '+i.id+'</b>'+add+'</div>'; }
|
||||
if (t == 'burst') { return '<div class="i_burst"><b>💥 Predicted Burst:</b><br />'+fd(i.datetime)+' in '+mr(i.altitude)+'m'+add+'</div>'; }
|
||||
if (t == 'burst') { return '<div class="i_burst"><b>💥 Predicted Burst:</b><br />'+fd(i.datetime)+' at '+mr(i.altitude)+'m'+add+'</div>'; }
|
||||
if (t == 'highest') { return '<div class="i_burst"><b>💥 Burst:</b> '+mr(i.altitude)+'m'+add+'</div>';}
|
||||
if (t == 'landing') { return '<div class="i_landing"><b>🎯 Predicted Landing:</b><br />'+fd(i.datetime)+' at '+mr(i.altitude)+'m'+add+'</div>'; }
|
||||
if (t == 'gps') { return '<div class="i_gps">Position: '+(i.lat)+','+(i.lon)+'<br />Altitude: '+i.alt+'m<br />Speed: '+mr(i.speed * 3.6 * 10)/10+'km/h '+i.dir+'°<br />Sat: '+i.sat+' Hdop:'+(i.hdop/10)+'</div>'; }
|
||||
|
@ -850,6 +529,151 @@ function bearing(latlng1, latlng2) {
|
|||
bearing = bearing < 0 ? bearing-360 : bearing;
|
||||
return Math.round(bearing);
|
||||
}
|
||||
upd.html 1353
|
||||
<html><head>
|
||||
<link rel="stylesheet" type="text/css" href="style.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<form action="update.html" method="post"><p>Currently installed: %FULLNAMEID%</p>
|
||||
<p>
|
||||
Available master: <span id="masterDiv">(...checking...)</span>
|
||||
|
||||
<br>
|
||||
Available devel: <span id="develDiv">(...checking...)</span>
|
||||
|
||||
</p>
|
||||
<input type="submit" name="master" value="Master-Update"></input><br>
|
||||
<input type="submit" name="devel" value="Devel-Update"><br>
|
||||
<p>Note: If suffix is the same, update should work fully. If the number is different, update contains changes in the file system. A full re-flash is required to get all new features, but the update should not break anything. If the letter is different, a full re-flash is mandatory, update will not work</p></form>
|
||||
|
||||
<script>
|
||||
const masterInfo = document.getElementById('masterDiv');
|
||||
const develInfo = document.getElementById('develDiv');
|
||||
|
||||
let request = new XMLHttpRequest();
|
||||
request.open('GET', 'http://rdzsonde.mooo.com/master/update-info.html');
|
||||
request.onload = function() {
|
||||
masterInfo.innerHTML = request.response.replace(/<[^>]*>/g, '');
|
||||
}
|
||||
request.send();
|
||||
let drequest = new XMLHttpRequest();
|
||||
drequest.open('GET', 'http://rdzsonde.mooo.com/devel/update-info.html');
|
||||
drequest.onload = function() {
|
||||
develInfo.innerHTML= drequest.response.replace(/<[^>]*>/g, '');;
|
||||
}
|
||||
drequest.send();
|
||||
</script>
|
||||
</body></html>
|
||||
rdz.js 1843
|
||||
let stypes=new Map();
|
||||
stypes.set('4', 'RS41');
|
||||
stypes.set('R', 'RS92');
|
||||
stypes.set('D', 'DFM');
|
||||
stypes.set('M', 'M10/M20');
|
||||
stypes.set('3', 'MP3H');
|
||||
|
||||
function footer() {
|
||||
document.addEventListener("DOMContentLoaded", function(){
|
||||
var form = document.querySelector(".wrapper");
|
||||
form.addEventListener("input", function() {
|
||||
document.querySelector(".save").disabled = false;
|
||||
});
|
||||
document.querySelector(".save").disabled = true;
|
||||
});
|
||||
}
|
||||
|
||||
/* Used by qrg.html in RX_FSK.ino */
|
||||
function prep() {
|
||||
var stlist=document.querySelectorAll("input.stype");
|
||||
for(txt of stlist){
|
||||
var val=txt.getAttribute('value'); var nam=txt.getAttribute('name');
|
||||
if(val=='2') { val='M'; }
|
||||
var sel=document.createElement('select');
|
||||
sel.setAttribute('name',nam);
|
||||
for(stype of stypes) {
|
||||
var opt=document.createElement('option');
|
||||
opt.value=stype[0];
|
||||
opt.innerHTML=stype[1];
|
||||
if(stype[0]==val) { opt.setAttribute('selected','selected'); }
|
||||
sel.appendChild(opt);
|
||||
}
|
||||
txt.replaceWith(sel);
|
||||
}
|
||||
}
|
||||
|
||||
function qrgTable() {
|
||||
var tab=document.getElementById("divTable");
|
||||
|
||||
var table = "<table><tr><th>Ch</th><th>Active</th><th>Frequency</th><th>Decoder</th><th>Launchsite</th></tr>";
|
||||
for(i=0; i<qrgs.length; i++) {
|
||||
var ck = "";
|
||||
if(qrgs[i][0]) ck="checked";
|
||||
table += "<tr><td class=\"ch\">" + (i+1) + "</td><td class=\"act\"><input name=\"A" + (i+1) + "\" type=\"checkbox\" " + ck + "/></td>";
|
||||
table += "<td><input name=\"F" + (i+1) + "\" type=\"text\" size=7 value=\"" + qrgs[i][1] + "\"></td>";
|
||||
table += "<td><input class=\"stype\" name=\"T" + (i+1) + "\" value=\"" + qrgs[i][3] + "\"></td>";
|
||||
table += "<td><input name=\"S" + (i+1) + "\" type=\"text\" value=\"" + qrgs[i][2] +"\"></td></tr>";
|
||||
}
|
||||
table += "</table>";
|
||||
tab.innerHTML = table;
|
||||
prep();
|
||||
footer();
|
||||
}
|
||||
|
||||
map.html 1206
|
||||
<html>
|
||||
<head>
|
||||
<script>
|
||||
maptype = "SH"; // TODO: Get from config
|
||||
|
||||
const maps = {
|
||||
"WS": ["https://www.wettersonde.net/map.php", (s)=>"?sonde="+s, (lat,lon)=>""],
|
||||
"SH": ["https://sondehub.org/", (s)=>s, (lat,lon)=>'#!mz=8&mc=' + lat + ',' + lon],
|
||||
"RS": ["https://radiosondy.info/", (s)=>"sonde.php?sondenumber="+s, (lat,lon)=>""],
|
||||
"OW": ["https://v2.openwx.de/start.php", (s)=>"?sonde="+s, (lat,lon)=>"?mode=mobile"],
|
||||
};
|
||||
|
||||
data = ["T4420541",63.5,-20.0];
|
||||
document.addEventListener("DOMContentLoaded", function(){
|
||||
fetch('live.json')
|
||||
.then((response) => response.json())
|
||||
.then((data) => {
|
||||
if (data.gps===undefined) { data.gps={} };
|
||||
console.log(data.gps.lat, data.gps.lon, data.sonde.ser);
|
||||
if( (data.sonde.ser||'')=='' && !(data.gps.lat===undefined) ) {
|
||||
urlarg = maps[maptype][2](data.gps.lat, data.gps.lon);
|
||||
} else {
|
||||
urlarg = maps[maptype][1](data.sonde.ser||'');
|
||||
}
|
||||
iftxt='<iframe src="' + maps[maptype][0] + urlarg + '" style="border:1px solid #00A3D3;border-radius:20px;height:98vh;width:100%"></iframe>';
|
||||
document.getElementsByTagName('body')[0].innerHTML = iftxt;
|
||||
})
|
||||
})
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
||||
livemap.html 720
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>rdzTTGOSonde Server LiveMap</title>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
||||
<link rel="stylesheet" type="text/css" href="style.css" />
|
||||
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.8.0/dist/leaflet.css" />
|
||||
<script>var mapcenter=[%MAPCENTER%];</script>
|
||||
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
|
||||
<script src="https://unpkg.com/leaflet@1.8.0/dist/leaflet.js"></script>
|
||||
<script src="https://unpkg.com/leaflet.marker.slideto@0.2.0/Leaflet.Marker.SlideTo.js"></script>
|
||||
<script src="livemap.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="map"></div>
|
||||
</body>
|
||||
</html>
|
||||
index.html 4368
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
@ -1368,3 +1192,179 @@ p{
|
|||
background: grey !important;
|
||||
}
|
||||
}
|
||||
cfg.js 8061
|
||||
var cfgs = [
|
||||
[ "", "General configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/General-configuration" ],
|
||||
[ "wifi", "Wifi mode (0=off, 1=client, 2=AP, 3=client or AP, 4=client-noscan)" ],
|
||||
[ "mdnsname", "Network mDNS name"],
|
||||
[ "ephftp", "FTP server for ephemeris data (RS92 decoder)"],
|
||||
[ "debug", "Debug mode (0/1)" ],
|
||||
[ "maxsonde", "Maximum number of QRG entries (must be ≤ 50)" ],
|
||||
[ "rxlat", "Receiver fixed latitude"],
|
||||
[ "rxlon", "Receiver fixed longitude"],
|
||||
[ "rxalt", "Receiver fixed altitude"],
|
||||
[ "", "OLED/TFT display configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Display-configuration" ],
|
||||
[ "screenfile", "Screen config (0=automatic; 1-5=predefined; other=custom)" ],
|
||||
[ "display", "Display screens (scan, default, ...)" ],
|
||||
[ "dispsaver", "Display saver (0=never/1=always/2=ifnorx [+10*n: after n sec.])" ],
|
||||
[ "dispcontrast", "OLED contrast (-1=use default; 0..255=set contrast)" ],
|
||||
[ "norx_timeout", "No-RX-timeout in seconds (-1=disabled)"],
|
||||
[ "tft_orient", "TFT orientation (0/1/2/3), OLED flip: 3"],
|
||||
[ "", "Spectrum display configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Spectrum-configuration" ],
|
||||
[ "spectrum", "Show spectrum on start (-1=no, 0=forever, >0=time [sec])" ],
|
||||
[ "startfreq", "Start frequency (MHz, default 400)" ],
|
||||
[ "channelbw", "Bandwidth (kHz)" ],
|
||||
[ "marker", "Spectrum MHz marker" ], // maybe remove, assume always ==1?
|
||||
[ "noisefloor", "Spectrum noisefloor" ],
|
||||
[ "", "Receiver configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Receiver-configuration" ],
|
||||
[ "freqofs", "RX frequency offset (Hz)"],
|
||||
[ "rs41.agcbw", "RS41 AGC bandwidth"],
|
||||
[ "rs41.rxbw", "RS41 RX bandwidth"],
|
||||
[ "rs92.rxbw", "RS92 RX (and AGC) bandwidth"],
|
||||
[ "rs92.alt2d", "RS92 2D fix default altitude"],
|
||||
[ "dfm.agcbw", "DFM AGC bandwidth"],
|
||||
[ "dfm.rxbw", "DFM RX bandwidth"],
|
||||
[ "m10m20.agcbw", "M10/M20 AGC bandwidth"],
|
||||
[ "m10m20.rxbw", "M10/M20 RX bandwidth"],
|
||||
[ "mp3h.agcbw", "MP3H AGC bandwidth"],
|
||||
[ "mp3h.rxbw", "MP3H RX bandwidth"],
|
||||
[ "", "KISS TNC/AXUDP/AXTCP data feed configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Data-feed-configuration"],
|
||||
[ "call", "Call"],
|
||||
[ "passcode", "Passcode"],
|
||||
[ "kisstnc.active", "KISS TNC (port 14590) (needs reboot)"],
|
||||
[ "axudp.active", "AXUDP active"],
|
||||
[ "axudp.host", "AXUDP host"],
|
||||
[ "axudp.port", "AXUDP port"],
|
||||
[ "axudp.highrate", "Rate limit"],
|
||||
[ "tcp.active", "APRS TCP active"],
|
||||
[ "tcp.timeout", "APRS TCP timeout [s] (0=off, 25=on)"],
|
||||
[ "tcp.host", "APRS TCP host"],
|
||||
[ "tcp.port", "APRS TCP port"],
|
||||
[ "tcp.highrate", "Rate limit"],
|
||||
[ "tcp.objcall", "APRS object call"],
|
||||
[ "tcp.beaconsym", "APRS tracker symbol"],
|
||||
[ "tcp.chase", "APRS location reporting (0=off, 1=fixed, 2=chase/GPS, 3=auto)"],
|
||||
[ "tcp.comment", "APRS location comment"],
|
||||
[ "", "MQTT data feed configuration", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/MQTT-configuration"],
|
||||
[ "mqtt.active", "MQTT active (needs reboot)"],
|
||||
[ "mqtt.id", "MQTT client ID"],
|
||||
[ "mqtt.host", "MQTT server hostname"],
|
||||
[ "mqtt.port", "MQTT port"],
|
||||
[ "mqtt.username", "MQTT username"],
|
||||
[ "mqtt.password", "MQTT password"],
|
||||
[ "mqtt.prefix", "MQTT prefix"],
|
||||
[ "", "Chasemapper settings", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Chasemapper-configuration"],
|
||||
[ "cm.active", "Chasemapper active (0=disabled, 1=active)"],
|
||||
[ "cm.host", "Chasemapper UDP host"],
|
||||
[ "cm.port", "Chasemapper UDP port"],
|
||||
[ "", "SondeHub settings", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/SondeHub-settings"],
|
||||
[ "sondehub.active", "SondeHub reporting (0=disabled, 1=active)"],
|
||||
[ "sondehub.chase", "SondeHub location reporting (0=off, 1=fixed, 2=chase/GPS, 3=auto)"],
|
||||
[ "sondehub.host", "SondeHub host (DO NOT CHANGE)"],
|
||||
[ "sondehub.callsign", "Callsign"],
|
||||
[ "sondehub.antenna", "Antenna (optional, visisble on SondeHub tracker)"],
|
||||
[ "sondehub.email", "SondeHub email (optional, only used to contact in case of upload errors)"],
|
||||
[ "", "SondeHub frequency import", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/SondeHub-import" ],
|
||||
[ "sondehub.fiactive", "SondeHub frequency import active (0=disabled, 1=active)" ],
|
||||
[ "sondehub.fiinterval", "Import frequency (minutes, ≥ 5)" ],
|
||||
[ "sondehub.fimaxdist", "Import maximum distance (km, ≤ 700)" ],
|
||||
[ "sondehub.fimaxage", "Import maximum age (hours, ≤ 48)" ],
|
||||
[ "", "Hardware configuration (requires reboot)", "https://github.com/dl9rdz/rdz_ttgo_sonde/wiki/Hardware-configuration"],
|
||||
[ "disptype", "Display type (0=OLED/SSD1306, 1=ILI9225, 2=OLED/SH1106, 3=ILI9341, 4=ILI9342, 5=ST7789)"],
|
||||
[ "oled_sda", "OLED SDA/TFT SDA"],
|
||||
[ "oled_scl", "OLED SCL/TFT CLK"],
|
||||
[ "oled_rst", "OLED RST/TFT RST (needs reboot)"],
|
||||
[ "tft_rs", "TFT RS"],
|
||||
[ "tft_cs", "TFT CS"],
|
||||
[ "tft_spifreq", "TFT SPI speed"],
|
||||
[ "button_pin", "Button input port"],
|
||||
[ "button2_pin", "Button 2 input port"],
|
||||
[ "button2_axp", "Use AXP192 PWR as Button 2"],
|
||||
[ "touch_thresh", "Touch button threshold<br>(0 for calib mode)"],
|
||||
[ "power_pout", "Power control port"],
|
||||
[ "led_pout", "LED output port"],
|
||||
[ "gps_rxd", "GPS RXD pin (-1 to disable)"],
|
||||
[ "gps_txd", "GPS TXD pin (not really needed)"],
|
||||
[ "batt_adc", "Battery measurement pin"],
|
||||
[ "sx1278_ss", "SX1278 SS"],
|
||||
[ "sx1278_miso", "SX1278 MISO"],
|
||||
[ "sx1278_mosi", "SX1278 MOSI"],
|
||||
[ "sx1278_sck", "SX1278 SCK"],
|
||||
];
|
||||
|
||||
function mkcfg(id, key, label, value) {
|
||||
var s = "<tr style=\"visibility: collapse;\" class=\"cfgpanel\"><td>" + label + "</td><td><input name=\"" + key + "\" type=\"text\" value=\"" + value + "\"/></td></tr>\n";
|
||||
return s;
|
||||
}
|
||||
function mkcfgbtn(id, key, label, value) {
|
||||
var touch = "";
|
||||
var v = value;
|
||||
if(v != -1 && (v&128)) {
|
||||
touch = " checked";
|
||||
v = v & 127;
|
||||
}
|
||||
var s = "<tr style=\"visibility:collapse\" class=\"cfgpanel\"><td>" + label + "</td><td><input name=\"" + key + "\" type=\"text\" size=\"3\" value=\"" + v + "\"/>";
|
||||
s += "<input type=\"checkbox\" name=\"" + key + "#\" "+touch+"> Touch</td></tr>\n";
|
||||
return s;
|
||||
}
|
||||
|
||||
function mksep(id,label,url) {
|
||||
return "<tr class=\"cfgheader\"><th class=\"cfg\" align=\"left\" colspan=\"2\">"+label+" <a href=\""+url+"\" target=\”_blank\">[wiki]</a></th></tr>\n";
|
||||
}
|
||||
function rowdisp(id,disp) {
|
||||
var matches = document.querySelectorAll("tr."+id);
|
||||
matches.forEach(function(e) { if(disp) e.hidden=true; else e.removeAttribute('hidden');});
|
||||
hid=id; nid="N"+id;
|
||||
if(!disp) { hid=nid; nid=id; }
|
||||
document.querySelector("span."+hid).hidden=true;
|
||||
document.querySelector("span."+nid).removeAttribute('hidden');
|
||||
}
|
||||
function configTable() {
|
||||
// iterate over cfgs
|
||||
var tab = "<table width=\"100%\"><tr><th>Option</th><th>Value</th></tr>\n";
|
||||
var id=0;
|
||||
for(i=0; i<cfgs.length; i++) {
|
||||
var key = cfgs[i][0];
|
||||
var lbl = cfgs[i][1];
|
||||
if(key) {
|
||||
if(key=="button_pin" || key=="button2_pin") {
|
||||
tab += mkcfgbtn("s"+id, key, lbl, cf.get(key));
|
||||
} else if (key=="display") {
|
||||
tab += mkcfg("s"+id, key, lbl, cf.get(key));
|
||||
tab += "<tr style=\"visibility:collapse\" class=\"cfgpanel\"><td>"+scr+"</td><td></td></tr>"
|
||||
} else {
|
||||
tab += mkcfg("s"+id, key, lbl, cf.get(key));
|
||||
}
|
||||
} else {
|
||||
id++;
|
||||
tab += mksep("s"+id, lbl, cfgs[i][2]);
|
||||
}
|
||||
}
|
||||
tab += "</table>";
|
||||
var cfgdiv = document.getElementById("cfgtab");
|
||||
cfgdiv.innerHTML = tab;
|
||||
// enable collapse / expand of items below a header
|
||||
var acc = document.getElementsByClassName("cfgheader");
|
||||
for(i=0; i<acc.length; i++) {
|
||||
acc[i].firstChild.innerHTML = "[+] " + acc[i].firstChild.innerHTML;
|
||||
acc[i].addEventListener("click", function(e) {
|
||||
if(e.target.nodeName=="A") return;
|
||||
achar = "[+]";
|
||||
if(this.classList.toggle("active")) achar = "[\u2212]";
|
||||
this.firstChild.innerHTML = achar + this.firstChild.innerHTML.substring(3);
|
||||
var panel = this;
|
||||
console.log(panel);
|
||||
while( panel = panel.nextElementSibling) {
|
||||
console.log(panel);
|
||||
if ( panel.className!="cfgpanel") { break; }
|
||||
if(panel.style.visibility==="collapse") {
|
||||
panel.style.visibility="visible";
|
||||
} else {
|
||||
console.log("none");
|
||||
panel.style.visibility="collapse";
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
acc[0].click();
|
||||
}
|
||||
|
|
Plik binarny nie jest wyświetlany.
|
@ -9,10 +9,10 @@
|
|||
<h2>Master repository</h2><ul>
|
||||
<li><a href="master/update.ino.bin">update.ino.bin</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
||||
<li><a href="master/update-info.html">update-info.html</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
||||
<li><a href="master/update.fs.bin">update.fs.bin</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
||||
<li><a href="master/update-info.html">update-info.html</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
||||
<li><a href="master/master_v0.9.4-B17-full.bin">master_v0.9.4-B17-full.bin</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
||||
<li><a href="master/master_v0.9.4-B17-changelog.txt">master_v0.9.4-B17-changelog.txt</a> (Jan 7 12:50:49 2024)</li>
|
||||
|
@ -46,15 +46,20 @@
|
|||
<li><a href="master/master_v0.6a-full.bin">master_v0.6a-full.bin</a> (Apr 29 21:03:35 2019)</li>
|
||||
|
||||
</ul><h2>Development repository</h2><ul>
|
||||
<li><a href="devel/update.ino.bin">update.ino.bin</a> (Apr 7 09:39:49 2024)
|
||||
<li><a href="devel/update.ino.bin">update.ino.bin</a> (May 16 21:33:52 2024)
|
||||
</li>
|
||||
|
||||
<li><a href="devel/update.fs.bin">update.fs.bin</a> (Feb 18 11:49:23 2024)
|
||||
<li><a href="devel/update.fs.bin">update.fs.bin</a> (May 16 21:33:52 2024)
|
||||
</li>
|
||||
|
||||
<li><a href="devel/test-st7789-0x10000.bin">test-st7789-0x10000.bin</a> (May 28 22:13:03 2022)
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20240514-B17-full.bin">devel20240514-B17-full.bin</a> (May 16 21:33:52 2024)
|
||||
<br>fix AXP2101 battery voltage
|
||||
fix AXP2101 battery voltage
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20240316-B17-full.bin">devel20240316-B17-full.bin</a> (Apr 7 09:39:49 2024)
|
||||
<br>include for mqtt corrected
|
||||
M20 vframe based on GPS time, consistent with autorx, fix #322
|
||||
|
@ -588,6 +593,10 @@ minor polishing of pull request for sondehub chase mode
|
|||
Update readme with installation instructions
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20210524a-B11-full.bin">devel20210524a-B11-full.bin</a> (May 24 19:24:40 2021)
|
||||
<br>Compatible with newer version of APX library (consistent with platformio, make sure to upgrade your ArduinoIDE), and font enhancements for new ILI9225 libraray
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20210524-B11-full.bin">devel20210524-B11-full.bin</a> (May 24 14:18:29 2021)
|
||||
<br>some font enhancements for new display driver (working better with some displays)
|
||||
README update and other minor things
|
||||
|
@ -595,10 +604,6 @@ README update and other minor things
|
|||
...and minor screen enhancements
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20210524a-B11-full.bin">devel20210524a-B11-full.bin</a> (May 24 19:24:40 2021)
|
||||
<br>Compatible with newer version of APX library (consistent with platformio, make sure to upgrade your ArduinoIDE), and font enhancements for new ILI9225 libraray
|
||||
</li>
|
||||
|
||||
<li><a href="devel/devel20210509-B11-full.bin">devel20210509-B11-full.bin</a> (May 23 09:00:30 2021)
|
||||
<br>Merge branch 'LukePrior-devel' into devel
|
||||
</li>
|
||||
|
|
Ładowanie…
Reference in New Issue