[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Tlf-devel] Tlf scoring for Stew Perry?
From: |
Nate Bargmann |
Subject: |
Re: [Tlf-devel] Tlf scoring for Stew Perry? |
Date: |
Fri, 13 Dec 2013 13:57:38 -0600 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
* On 2013 13 Dec 11:58 -0600, Mike Waters wrote:
> > ==%==
> > #include <stdio.h>
> > #include <hamlib/rotator.h>
> >
> > int main(int argc, char ** argv) {
> > double s1long, s1lat, s2long, s2lat;
> > char s1qra[] = "EM37cg";
> > char s2qra[] = "jn97om";
> > double dist = 1000, az = 90;
> >
> > locator2longlat(&s1long, &s1lat, s1qra);
> > locator2longlat(&s2long, &s2lat, s2qra);
> >
> > printf("W0BTU coords: lat: %f lon: %f\n", s1lat, s1long);
> > printf("HA2OS coords: lat: %f lon: %f\n", s2lat, s2long);
> >
> > qrb(s1long, s1lat, s2long, s2lat, &dist, &az);
> >
> > printf("distance between W0BTU and HA2OS: %f km, dir: %f\n", dist, az);
> > return 0;
> > }
> > ==%==
> >
> > You can compile that code with this command:
> >
> > gcc -Wall qrasrc.c -lhamlib
> >
>
> It didn't work. Here is the gcc output:
>
> address@hidden:~/local/share/tlf/tlf-devel$ sudo gcc -Wall gridtest.c
> -lhamlib
> [sudo] password for mike:
Just as info, sudo is not required to run gcc in your home directory.
> gridtest.c:1:1: error: expected identifier or ‘(’ before ‘==’ token
> In file included from /usr/include/stdio.h:75:0,
> from gridtest.c:2:
I'm guessing that you left the lines that have "==%==" in the file.
This should not be there, so delete those lines. Try it without those
lines and try it again.
73, de Nate >>
--
"The optimist proclaims that we live in the best of all
possible worlds. The pessimist fears this is true."
Ham radio, Linux, bikes, and more: http://www.n0nb.us
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, (continued)
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, Ervin Hegedüs, 2013/12/09
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, Nate Bargmann, 2013/12/09
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, Thomas Beierlein, 2013/12/10
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, Nate Bargmann, 2013/12/10
- Re: [Tlf-devel] Tlf scoring for Stew Perry?, Thomas Beierlein, 2013/12/10
Re: [Tlf-devel] Tlf scoring for Stew Perry?, Thomas Beierlein, 2013/12/09
Re: [Tlf-devel] Tlf scoring for Stew Perry?, Ervin Hegedüs, 2013/12/09
Re: [Tlf-devel] Tlf scoring for Stew Perry?, Nate Bargmann, 2013/12/13
Re: [Tlf-devel] Tlf scoring for Stew Perry?, Mike Waters, 2013/12/13
Re: [Tlf-devel] Tlf scoring for Stew Perry?, Ervin Hegedüs, 2013/12/14