diff --git a/clubs/hsc.pl b/clubs/hsc.pl new file mode 100755 index 0000000..186fa0b --- /dev/null +++ b/clubs/hsc.pl @@ -0,0 +1,30 @@ +#!/usr/bin/perl -w + +# yfktest script to import HSC member data +# see http://fkurz.net/ham/yfklog/doc/#clubs + +system("wget http://hsc.dj1yfk.de/db/hsc_list_n1mm.txt -O hsc.txt"); + +$sql = "delete from clubs where `club`='HSC';\n"; + +$sql .= "insert into clubs (`club`, `call`, `nr`) VALUES \n"; + +my @out; +open HSC, "hsc.txt"; +while ($line = ) { + $line =~ s/(\r\n)//g; + if ($line =~ /^[A-Z0-9]/) { + my @a = split(/,/, $line); + push @out, "('HSC', '$a[0]', '$a[1]')"; + } +} +close HSC; + +$sql .= join(",\n", @out); +$sql .= ";"; + +open HSC, ">hsc.sql"; +print HSC $sql; +close HSC; + +print "Saved to hsc.sql ($#out records).\n"; diff --git a/doc/index.html b/doc/index.html index e615538..8b649d8 100644 --- a/doc/index.html +++ b/doc/index.html @@ -4,9 +4,27 @@ YFKlog v0.4.0 Manual - @@ -97,17 +115,25 @@ running:

make libsqlite3-0 libcurses-perl libwww-perl

For LoTW, you will also need the packages trustedqsl and -

xvfb
.

+xvfb.

Download the latest version of -YFKlog and unpack the tarball to a directory of your choice, then run +YFKlog (or clone the latest version from git) and unpack the tarball to a directory of your choice, then run make install.

+ +

Install from distribution archive

 $ wget http://fkurz.net/ham/yfklog/yfklog-0.4.0.tar.gz
 $ tar zxfv yfklog-0.4.0.tar.gz
 $ cd yfklog-0.4.0 
-$ su
-# make install
+$ sudo make install
+
+ +

Install from git

+
+$ git clone https://git.fkurz.net/dj1yfk/yfklog.git
+$ cd yfklog
+$ sudo make install
 

By default, YFKlog will be installed to /usr, but you can specify @@ -128,20 +154,14 @@ You can chose between two databases, MySQL.

SQLite is a lightweight, self-contained, zero-configuration SQL database engine and probably the right -choice for most users of YFKlog. It's very easy to set up (for example in -Debian, just install libdbd-sqlite3-perl and -libclass-dbi-sqlite-perl and you're set!) and surprisingly fast. -

- -

MySQL is pretty much the opposite. Don't use it, unless you know why you'd -want to.

+choice for most users of YFKlog. Only use MySQL if you know why.

1.1 SQLite

There is nothing really to set up, this is the default setting. SQLite will autmatically create a SQLite database file of the name as set in dbname=.... This single file contains the whole database. It's trivial to back up and (if needed) accessible via the -sqlite3 command line utility just like a MySQL database.

+sqlite3 command line utility.

1.2 MySQL

Create a database (in this example it's called YFKlog, the user @@ -303,8 +323,10 @@ they are not important.


- - +
+ +
YFKlog main menu
+

3. Main Menu

All functions of YFKlog are accessible through the main menu, shown on the right. The single menu points will be described in greater detail in the @@ -348,8 +370,10 @@ following sections; some are self explanatory. A quick overview:


- - +
+ +
The main logging screen of YFKlog
+

4. Logging QSOs

In the Logging Mode, as shown in the picture, the screen is split up into 4 main windows. A QSO can be saved with F2, @@ -401,7 +425,7 @@ respectively.

  • This window shows information about the callsign entered, derived from the country file cty.dat. The last line also shows - if available - - known club memberships, if the DXCC was worked before, + - known club memberships, if the DXCC was worked before, and if so on which bands, and if the callsign appears in any other log, as specified by checklogs in the config file. This is an example where all these @@ -421,8 +445,11 @@ respectively.


    +
    + +
    Editing QSOs
    +
    -

    5. Searching and Editing QSOs

    Logged QSOs can be searched and edited under the menu point Search @@ -453,7 +480,10 @@ which can easily be adopted, even without knowledge of SQL.

    Effective handling of QSL cards, both incoming and outgoing, is easily done with YFKlog. This section describes how.

    - +
    + +
    Marking QSL cards as received in the log
    +

    6.1 Incoming QSL cards

    The menu point QSL enter mode allows you to record received QSLs very effectively. After entering 3 or more letters of the callsign, all @@ -525,8 +555,7 @@ from YFKlog. There are two exceptions:

    1. YFKlog has a separate log field for handling LoTW confirmations. This field has no ADIF equivalent and is not used when exporting to ADIF.
    2. -
    3. Exported logs from YFKlog currently don't include any DXCC information. - This will be fixed in foreseable future.
    4. +
    5. Exported logs from YFKlog currently don't include any DXCC information.

    To export the current logbook to an ADIF file, chose "ADIF export" in the @@ -562,7 +591,7 @@ author's PC (1.8GHz, 256MB RAM).

    8. Update Onlinelog

    -to be written... +... function to be rewritten completely ...


    @@ -579,7 +608,10 @@ QSL labels however, or exporting the log, it's changed back to a slash.


    +
    +
    DXCC award tracking with YFKlog
    +

    10. Awards and Statistics

    10.1 Standings for awards

    @@ -635,9 +667,13 @@ Name/QTH DB" from the main menu.


    +
    + +
    YFKlog shows which contacts were recently confirmed on LoTW
    +

    12. LoTW functions

    -

    YFKlog makes it easy to keep track with the LoTW status of your QSOs!

    +

    YFKlog makes it easy to keep track with the LoTW status of your QSOs and supports direct upload and download to/from LoTW.

    For each QSO, YFKlog saves a value (called QSLrL, QSL-received-LoTW), which can be: @@ -739,13 +775,50 @@ message queue and be fetched as soon as YFKlog enters the remote mode.


    -

    Appendix (very much UNDER CONSTRUCTION)

    +

    Appendix

    Using Putty

    When using YFKlog via ssh with Putty, the F-keys may not work in the default configuration. In the putty configuration (Terminal -> Keyboard), set "The Function keys and keypad:" to Xterm R6.

    +

    Club memberships

    + +

    When entering a callsign in logging mode, YFKlog searches for this +callsign in a database table named clubs. This database +table has three columns, club (the name of the club), nr +the membership number, and call (the callsign).

    +

    By default this table is empty. In the clubs subdirectory +you'll find a couple of scripts which download membership data from a +number of different sources and generate SQL statements from them, which +you can then push into the database. Some of these membership databases +are directly pulled from the respective clubs, others come via the +CW Club files +by G4BKI / VP9KF.

    + +

    By adapting the existing scripts, you should be able to add your own clubs if needed.

    + +

    Example: HSC member list

    +

    The script hsc.pl will download the HSC member list and +generate SQL statements for it. Here's an example how to use it:

    + +
    +$ ~/dev/yfklog/clubs/hsc.pl
    + --2019-07-01 21:52:36--  http://hsc.dj1yfk.de/db/hsc_list_n1mm.txt
    +Resolving hsc.dj1yfk.de (hsc.dj1yfk.de)... 88.99.84.60
    +Connecting to hsc.dj1yfk.de (hsc.dj1yfk.de)|88.99.84.60|:80... connected.
    +HTTP request sent, awaiting response... 200 OK
    +Length: unspecified [text/plain]
    +Saving to: 'hsc.txt'
    +
    +2019-07-01 21:52:36 (116 MB/s) - 'hsc.txt' saved [30910]
    +
    +Saved to hsc.sql (1358 records).
    +$ mysql -uUSERNAME -pPASSWORD YFKlog < hsc.sql   # for MySQL
    +$ sqlite3 ~/.yfklog/YFKlog < hsc.sql             # for sqlite
    +
    + +

    Database backup

    Regular backups of your logbook data are highly recommended. With SQLite and @@ -753,13 +826,13 @@ MySQL you can easily produce a so-called SQL dump of the database, from which you'll be able to completely restore your database in case of data loss.

    For SQLite, use the following command-line:

    -
    sqlite3 ~/.yfklog/YFKlog '.dump' | gzip -c > dump.sql.gz
    +
    sqlite3 ~/.yfklog/YFKlog '.dump' | gzip -c > dump.sql.gz

    This will produce a compressed file dump.sql.gz which contains the whole database in human readable SQL format. Replace ~/.yfklog/YFKlog with the location of the SQLite database file, in case you don't use the default location.

    For MySQL, use the command line utility mysqldump: -

    mysqldump -p YFKlog | gzip -c > dump.sql.gz
    +
    mysqldump -p YFKlog | gzip -c > dump.sql.gz
    Where YFKlog is the name of the database. You will be prompted to enter your password; alternatively you may directly include it in the command line (for example when invoked from cron): mysqldump -pMYPASSWORD @@ -796,25 +869,6 @@ Rows matched: 3158 Changed: 3158 Warnings: 0 mysql> -

    Database Backup

    - -

    A backup of the complete database can be easily done by sqldump. In this -example the database name is YFKlog.

    - -

    MySQL

    -
    mysqldump -p YFKlog | gzip - - > dump.sql.gz
    -

    mysqldump will promt you for the password to access the database. If you -invoke mysqldump from a script, you may add the password in the command line -(mysqldump -pPASSWORD) but be advised that this is not very secure. Everyone -doing a ps a during the backup can see your password. You may want -to consider using for example expect if this is an issue.

    - -

    SQLite3

    -
    sqlite3 ~/.yfklog/YFKlog .dump YFKlog | gzip - - > dump.sql.gz
    -

    Alternatively, just back up the database file itself, ~/.yfklog/YFKlog, but -makre sure there is not currently any process writing to it.

    - -

    GNU Free Documentation License

    diff --git a/doc/lotwimport.png b/doc/lotwimport.png new file mode 100644 index 0000000..02a74f2 Binary files /dev/null and b/doc/lotwimport.png differ