Yesterday I used Datasette to make a map of the QSOs I'd made from the Pantoll Campground area, Then, I remembered that I also wanted to know how the locations of the stations on the receiving end of my POTA QSOs from there compared to W6CSN's. That map turned out to be very easy to make.
I remembered that the Datasette cluster map looks for the column names 'longitude' and 'latitude'. Keeping that in mind, I renamed the columns that I'd use datasette-leaflet-freedraw to search for to 'longitude_t' and 'latitude_t', and then added two more columns containing the latitude and longitude of the receiving station. So,
select rm_rnb_history_pres.tx_lng as longitude , rm_rnb_history_pres.tx_lat as latitude, rm_rnb_history_pres.timestamp, rm_rnb_history_pres.dB, rm_rnb_history_pres.Spotter, rm_rnb_history_pres.QSL_link, photo_path.path, photo_path.uuid, json_object(
'image',
'/-/media/thumbnail/' || uuid,
'title', Spotter || ' de KD0FNR',
'description', 'rx_rst: ' || dB || ' timestamp: ' || rm_rnb_history_pres.timestamp
) as popup from rm_rnb_history_pres LEFT JOIN photo_path ON rm_rnb_history_pres.QSL_link = photo_path.uuid where db > 100 and
Intersects(GeomFromGeoJSON(:freedraw), MakePoint(cast(longitude), cast(latitude))) = 1 order by
rm_rnb_history_pres.timestamp asc
became
select rm_rnb_history_pres.tx_lng as longitude_t , rm_rnb_history_pres.tx_lat as latitude_t, rm_rnb_history_pres.trx_lng as longitude , rm_rnb_history_pres.rx_lat as latitude, rm_rnb_history_pres.timestamp, rm_rnb_history_pres.dB, rm_rnb_history_pres.Spotter, rm_rnb_history_pres.QSL_link, photo_path.path, photo_path.uuid, json_object(
'image',
'/-/media/thumbnail/' || uuid,
'title', Spotter || ' de KD0FNR',
'description', 'rx_rst: ' || dB || ' timestamp: ' || rm_rnb_history_pres.timestamp
) as popup from rm_rnb_history_pres LEFT JOIN photo_path ON rm_rnb_history_pres.QSL_link = photo_path.uuid where db > 100 and
Intersects(GeomFromGeoJSON(:freedraw), MakePoint(cast(longitude_t), cast(latitude_t))) = 1 order by
rm_rnb_history_pres.timestamp asc
And instead of details of where I'd transmitted from, I got a map of the places I'd transmitted to from the area defined on the map:
Here's a video of the entire operation
Comments
Post a Comment
Please leave your comments on this topic: