[Xastir] Oregon Scientific wmr200

Tom Russo russo at bogodyn.org
Sun Oct 29 17:37:55 PDT 2017


Give this a shot:

http://pages.swcp.com/~russo/APRS/wxnowsrv.txt

Rename the script to "wxnowssrv.pl" and set its execute bit 
(chmod a+x wxnowsrv.pl).

Then edit the "pathname" variable to point to where your Wxnow.txt file lives
on the pi that creates the data.

Edit the "SERVER_PORT" variable as you like.  It currently is set to port 5500.

Set the "POLLTIME" variable to something smaller than the frequency at which
Wxnow.txt is updated.

Run it.

Then run Xastir (anywhere on your home LAN) and create a "Networked WX" 
interface whose IP address is the machine on which you're running this script,
and whose port number is the same port number you used in SERVER_PORT.

Xastir should then think it is receiving weather data, which should show up
in your "Own Weather Data" dialog (under View).  Every time Wxnow.txt changes,
the script should emit new data for Xastir on the socket.

Change Xastir's station type to "Station position, zulu date-time, weather"
and you should be transmitting complete APRS weather data with your station
posits.

This script is multithreaded, so will handle as many Xastir instances on your
lan as you like.  Unfortunately, I don't think it correctly handles 
client disconnections  --- I had that working at some point, but it doesn't
seem to be in this version, and the threads for disconnected clients stick
around.

It's a kludge, but it appears to work.  I tested it out only by running
it with a copy of Wxnow from the web site that Joe provided, and by connecting
to the server using "telnet localhost 5500".  If I edited Wxnow.txt, every 
connected client got updated data.

On Sun, Oct 29, 2017 at 03:18:57PM -0600, we recorded a bogon-computron collision of the <russo at bogodyn.org> flavor, containing:
> That's not quite what I had suggested, as it inserts data into Xastir's 
> server port (2023).  That is, the script should be a server and Xastir should
> be a client --- the script you have is the other way around.  Xastir is not
> set up to process weather data on that port, though you *could* create 
> a full weather *object* this way and dump it into the Xastir server port.  That
> is less ideal, because the weather data wouldn't be available to Xastir in 
> its "Own Weather Data" display.
> 
> What I actually meant was something Xastir could connect to as a client.  What
> you'd do then would be to tell Xastir it had a networked WX interface, and
> Xastir would connect to that program's port.  Every time wxnow.txt changed,
> the program would spit data out to all connected clients in the format
> that Xastir expects for weather data.  
> 
> Xastir would then parse out the data and store it as its own weather data,
> and when it was time to transmit, would create a complete weather packet
> for your station (I misspoke when I said positionless).
> 
> I have written a cheesy perl script to work as a tcp server once, and still
> have it lying around -- it wasn't the same sort of thing, but did have the
> right loops and TCP calls to get the job done.  I think a small modification 
> could be made to turn it into the kind of thing I'm talking about here.  I 
> have a ton of things to do today, but might be able to find a few cycles 
> tonight to cobble it together.
> 
> On Sun, Oct 29, 2017 at 12:19:45PM -0500, we recorded a bogon-computron collision of the <kg4wsv at gmail.com> flavor, containing:
> > On Sun, Oct 29, 2017 at 11:47 AM, Tom Russo <russo at bogodyn.org> wrote:
> > >
> > > Oh, yeah, and looking over Joe's use case, where the wxnow.txt file is
> > > generated on one Pi and consumed by a different pi in a different part of the
> > > house, the network daemon approach is ideal --- the daemon would run on
> > > the machine where wxnow.txt is created, and Xastir on any machine anywhere
> > > in the house, connecting to that daemon on the other machine for its weather
> > > data.  No need for samba (ugh) or other file sharing techniques.
> > >
> > > So again, my first option described below should be low-hanging fruit for
> > > anyone who already knows how to write quickie Python network server scripts.
> > > Or an interesting project for someone who *wants* to know how to do that and
> > > who has the spare cycles to do the learning.
> > 
> > perl not python, but feel free to hack at
> > 
> > http://www.ece.uah.edu/~jdw/rockets/gps2aprs.txt
> > 
> > This script takes an NMEA sentence and sticks a prefix onto it,
> > thereby making an (inefficient) APRS position report out of it.  This
> > is pretty close to what Tom is suggesting, if I'm understanding
> > correctly. it assumes it is running on the xastir system, but change
> > "localhost" to the name of the remote pi and you're in business for
> > remote connectivity.
> > 
> > about the first 20 and the last 20 lines relate to getting data to
> > xastir via its server port. The stuff in between is extracting data
> > from a serial port, which isn't relevant.  Reading from a txt file is
> > a couple of lines easily derived by googling.
> > 
> > In order to get xastir to put it on the air, you'll have to do the
> > configuration steps to make xastir gateway the weather packets, but I
> > think that is already documented elsewhere.
> > 
> > and _please_ put coordinates on it, so it's not a position less
> > weather packet...
> > 
> > -Jason
> > kg4wsv
> > _______________________________________________
> > Xastir mailing list
> > Xastir at lists.xastir.org
> > http://xastir.org/mailman/listinfo/xastir
> 
> -- 
> Tom Russo    KM5VY   SAR502   DM64ux          http://www.swcp.com/~russo/
> Tijeras, NM  QRPL#1592 K2#398  SOC#236        http://kevan.org/brain.cgi?DDTNM
>  echo "prpv_a'rfg_cnf_har_cvcr" | sed -e 's/_/ /g' | tr [a-m][n-z] [n-z][a-m]
> 
>  
> 
> 
> _______________________________________________
> Xastir mailing list
> Xastir at lists.xastir.org
> http://xastir.org/mailman/listinfo/xastir

-- 
Tom Russo    KM5VY   SAR502   DM64ux          http://www.swcp.com/~russo/
Tijeras, NM  QRPL#1592 K2#398  SOC#236        http://kevan.org/brain.cgi?DDTNM
 echo "prpv_a'rfg_cnf_har_cvcr" | sed -e 's/_/ /g' | tr [a-m][n-z] [n-z][a-m]

 




More information about the Xastir mailing list