[aprssig] findu / lookup

Andrew Rich vk4tec at people.net.au
Sat May 17 18:11:26 EDT 2008


i had this 


  ----- Original Message ----- my $host = "www.findu.com";
  my (@data, $line);
  my $t = new Net::Telnet(Timeout=> '50', port => '80');
  $t->errmode('return');
  $t->Net::Telnet::open($host);
  #sleep 5;
  print $t "GET /cgi-bin/posit.cgi?call=".$FORM{Call}."&comma=1\n";
  #print $FORM{Call};
  #print $t "GET /cgi-bin/posit.cgi?call=VK4TEC-9&comma=1\n";
  while (<$t>)
  {
  print;
  if (m/,/)
  {
  @data = split/,/;
  $long = $data[1];
  $lat = $data[0];                                             



  From: Michael 
  To: TAPR APRS Mailing List 
  Sent: Sunday, May 18, 2008 8:03 AM
  Subject: Re: [aprssig] findu / lookup


  Andrew,

  I just wrote a thing that uses findu.com.
  It works pretty well.

  73 Michael N7MR



------------------------------------------------------------------------------


  #!/usr/bin/perl

  use LWP::Simple;

  read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'});
  ($name, $value) = split(/=/, $buffer);

  $rawData = get("http://www.findu.com/cgi-bin/posit.cgi?call=$value&start=24&comma=1");

  @rawDataLines = split($/,$rawData);
  @rawDataLines = reverse @rawDataLines;
  shift @rawDataLines;
  shift @rawDataLines;

  # Capture the most recently reported location
  $mostRecentReportedLocation = shift @rawDataLines;

  # Separate that line into lat,long,course,speed,altitude
  @llcsa = split(",",$mostRecentReportedLocation);

  # Format the google call string
  $googleCallString = $llcsa[0].",+".$llcsa[1];

  print "Content-type: text/html\n";
  print "Location: http://maps.google.com/maps?q=$googleCallString \n\n";



------------------------------------------------------------------------------


  _______________________________________________
  aprssig mailing list
  aprssig at lists.tapr.org
  https://lists.tapr.org/cgi-bin/mailman/listinfo/aprssig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.tapr.org/pipermail/aprssig_lists.tapr.org/attachments/20080518/8dd90a65/attachment.html>


More information about the aprssig mailing list