feat: Add Node.js script for WSPR data fetching
Co-authored-by: aider (gemini/gemini-2.5-pro) <aider@aider.chat>
This commit is contained in:
24
index.js
24
index.js
@@ -0,0 +1,24 @@
|
||||
import { QuerierWsprLive } from './js/QuerierWsprLive.js';
|
||||
|
||||
// This function reuses your existing code to perform the same search
|
||||
// as the wspr.live URL you provided.
|
||||
async function fetchWsprData() {
|
||||
const querier = new QuerierWsprLive();
|
||||
|
||||
// Parameters from your query URL:
|
||||
const band = '20m';
|
||||
const min = 0;
|
||||
const callsign = 'VE6AZX';
|
||||
const timeStart = '2026-01-06 07:00:00';
|
||||
const timeEnd = ''; // An empty string means no end time
|
||||
|
||||
console.log("Fetching WSPR data...");
|
||||
const results = await querier.SearchRegularType1(band, min, callsign, timeStart, timeEnd);
|
||||
|
||||
console.log(`Found ${results.length} records.`);
|
||||
console.log(results);
|
||||
|
||||
return results;
|
||||
}
|
||||
|
||||
fetchWsprData();
|
||||
|
||||
Reference in New Issue
Block a user