HamLog - amateur radio contact logger.

Looking for PSION Organiser II Software
User avatar
MartinReid
Posts: 93
Joined: Wed Jan 27, 2021 3:44 pm

HamLog - amateur radio contact logger.

Post by MartinReid »

For the attention of Hawsay (and others watching)
  • I've started a new topic in this Software section to keep it separate.
  • Considering your amateur radio contact logger.. 1st outline the data to stored in each 'contact' record..
  • Program (application) name.. HamLog
  • Initial specification from your other post
    contact logger as well so Callsign / frequency / date time / duration etc
HamLog Filename = "A:HamLog",B,NM$,CS$,Htz,Dte$,ST,ET,Drn,DT$,RM$ ........(note Logical Name A is used in AdDate)

NM$ = Actual NAME of callsign text field
CS$ = CallSign text field
Htz = frequency Floating point variable field
Dte$ = DATIM$ in the Manual = "MON 16 OCT 1989 16:25:30" Display MID$(Dte$,5,6) "16 OCT"
ST = Start Time = in decimal time floating point variable ... ST=HOUR+(MINUTE/60) eg 4:38pm = 16.63333..
ET = End Time = Ditto ... (consider rolling past midnight) IF ET<ST ET=ET+24
Dtn = Duration automatic ET-ST .. Save as decimal time eg 0.33333 = 20Min
DT$ = Appointment Date Reminder of future contact
RM$ = Appointment Remarks Reminder of NAME and/or Callsign

Requirements...
Need example of actual call signs
Need example of actual frequency range
Have we captured all the data to be stored?

If there are details of future contact appointments, we could put these in the LZ Diary with alarms set.
Add Date Diary Filename = "A:AdDate",A,DT$,RM$ :Remark in LZ Diary Format

Martin
User avatar
MartinReid
Posts: 93
Joined: Wed Jan 27, 2021 3:44 pm

HLog and other short programmes

Post by MartinReid »

Again for the attention of Hawsay

Further to an Organiser Application to Log Amateur Radio Contacts..

This reminds me of the 1980's when we didn't have access to a Comms Link to transfer files and procedures and we had to type them in at the keyboard.

This short program will create a file to hold your contacts, dates and times. Later we could add some file utilities to examine and print the file information but for now you can use xFiles examine the data.

There are 3 short routines used throughout the 'Logger'. We'll start with these.

You should navigate to the [Prog] menu and start a [New] program and call it AP then type in the code and then translate it.. [MODE][Tran][Save A]AP[EXE]

AP:
AP:(x%,y%,z$)
AT x%,y% :PRINT z$;

ditto for the User Defined Graphic

HLUDG:
udg 0,17,17,17,31,21,21,4,31
udg 2,0,0,0,0,0,0,0,31

and the final short routine organises the top line display and clock

HLTOP:(x%)
PRINT chr$(15);chr$(22);chr$(23)
AT 1,1
PRINT chr$(0);rept$(chr$(2),14)
CLOCK(1)
AT 1,x%
RETURN

Now we come to the main Logger Program (HamLog) short form [Hlog] can be entered in the top level menu. Page 11 of the republished LZ programming manual explains how to do this. Again type in the program, Then [MODE][Tran]... You will probably make typing errors so it will pause and move the cursor to the 'error' correct it and retry [MODE][Tran] etc.. until [Save A]. operating instructions to follow but for now once running the only way to stop it is to select the menu item [Utils].

HLOG:
Local TM$(9),M%,F$(14),N%
HLUDG:

REM Open files Logical file (B) as (A) will be used elsewhere
IF NOT EXIST ("A:HamLog")
CREATE "A:HamLog",B,No%,TXT$,CS$,Htz$,Dte$,ST$,ET$
B.No%=1
ELSE
OPEN "A:HamLog",B,No%,TXT$,CS$,Htz$,Dte$,ST$,ET$
LAST
ENDIF

SETNUL::
B.TXT$="" :B.CS$="" :B.Htz$="" :B.ST$="" :B.ET$="" :N%=COUNT+1

LOOP::
DO
AP:(1,2,"Text:"+B.TXT$+CHR$(26))
AP:(1,3,"CSgn:"+B.CS$+CHR$(26))
AP:(1,4,"Htz:"+B.Htz$+CHR$(26))
IF B.ST$="" :TM$="Bgn:00:00" :ELSE TM$="Bgn:"+B.ST$ :ENDIF
IF B.ET$<>"" :TM$="End:"+B.ET$ :ENDIF
AP:(12,4,TM$)
AT 1,1 :M%=MENUN(1,"Off,Text,CSign,Htz,Begin,End,Log,Utils")
IF M%=1 :OFF :ENDIF
IF M%=2 :F$=B.TXT$ :GOTO NAME:: :ENDIF
IF M%=3 :F$=B.CS$ :GOTO CSign:: :ENDIF
IF M%=4 :F$=B.Htz$ :GOTO Htz:: :ENDIF
IF M%=5 :B.ST$=MID$(DATIM$,17,5) :B.ET$="" :ENDIF
IF m%=6 :B.ET$=MID$(DATIM$,17,5) :ENDIF
IF M%=7 :GOTO LOG:: :ENDIF
IF M%=8 :STOP : ENDIF REM Save for HLutils: :ENDIF
UNTIL M%>8 :REM careful loop forever only way out is HLutils
STOP

NAME::
HLTOP:(2)
PRINT "Text:";
EDIT F$
B.TXT$=LEFT$(F$,14)
GOTO LOOP::

CSign::
HLTOP:(3)
PRINT "Call Sign:";
EDIT F$
B.CS$=LEFT$(F$,14)
GOTO LOOP::

Htz::
HLTOP:(4)
PRINT "Frequency: "+CHR$(26);
KSTAT 3
EDIT F$
KSTAT 1
B.Htz$=LEFT$(F$,6)
GOTO LOOP::

LOG::
USE B
IF B.ST$="" :B.ST$=MID$(DATIM$,17,5) :ENDIF
IF B.ET$="" :B.ET$=B.ST$ :ENDIF
IF N%<COUNT :N%=Count+1 :ENDIF
B.No%=N%
B.Dte$=LEFT$(DATIM$,15)
HLTOP:(2)
PRINT "Contact Logged "+MID$(DATIM$,17,5);
PRINT B.CS$+" "+LEFT$(B.Htz$,5);
AP:(1,4,"Continue press (EXE)")
APPEND
N%=N%+1
GET
GOTO SETNUL::

When you have it 'working' post here and we'll continue. For now if you use it [Log] appends the data on the screen to a database file 'HamLog' you can look at it in xFiles.

Always sincere
Martin
Last edited by MartinReid on Wed Jul 28, 2021 9:40 am, edited 1 time in total.
hawsey
Posts: 41
Joined: Fri Jul 02, 2021 12:34 am

Re: HamLog - amateur radio contact logger.

Post by hawsey »

This is great Martin , thank you for egging me on with this . Taking me back to my ZX81 roots but hopefully without the Ram pack wobble .
I am just going to be using my P464 to type this in , is that correct ? You don't program on a PC then transfer across do you ?
Thanks for your efforts , I'll give this a go tonight .
I might post this on a ham radio group to see if anyone else wants to join in as well 👍.
User avatar
MartinReid
Posts: 93
Joined: Wed Jan 27, 2021 3:44 pm

HamLog & Coms Link

Post by MartinReid »

I'm affraid you will be typing in the code on your Organiser. You can type in your programs on a PC and then transfer them across to the Orgainser IF you have a Comms Link. I see that both Olivier and ThePowerfulPierre eBay store are out of stock of the NEW USB Comms Link. If you watch the USB Comms Link page of the Hardware Section I'm sure someone will post there when they are back in stock..

Olivier's PSION products (here)

I tested the program on a PC in the original ORG2 emulator in DosBOX. (Republished Developer Manual (here)

If anyone on the ham radio group are interested there is an LZ64 on ebay for the next day or so, it will probably go for £25.00 to £30.00 eBay item number:255061726965

Let me know when you get HLOG working..

Martin
hawsey
Posts: 41
Joined: Fri Jul 02, 2021 12:34 am

Re: HamLog - amateur radio contact logger.

Post by hawsey »

Thanks for the above Martin .
So I typed in the first three little bits of code before the main program and it's stuck on 21,4,31 and says missing Comma , if I insert a comma after 31 I get Syntax error
Any ideas please ?
User avatar
MartinReid
Posts: 93
Joined: Wed Jan 27, 2021 3:44 pm

punctuation

Post by MartinReid »

All I can suggest is you check that the punctuation are all commas not decimal points.. If you can't find it then perhaps retype it.

HLUDG:
udg 0,17,17,17,31,21,21,4,31
udg 2,0,0,0,0,0,0,0,31
hawsey
Posts: 41
Joined: Fri Jul 02, 2021 12:34 am

Re: HamLog - amateur radio contact logger.

Post by hawsey »

That's it now , so I've saved that first little bit , now to work out about the top level thing you mean 👍.I really have no clue 🙂
hawsey
Posts: 41
Joined: Fri Jul 02, 2021 12:34 am

Re: HamLog - amateur radio contact logger.

Post by hawsey »

Ok so I'm stuck , I have completed the first little bit and saved it but for the next stage Hlog , I have looked at page 11of the republished lz programming manual but can't work out what to do next .
Do I just select new as I did before ?
Feeling a bit out of my depth 😂
User avatar
MartinReid
Posts: 93
Joined: Wed Jan 27, 2021 3:44 pm

Running Programs

Post by MartinReid »

You need to type in and [Tran]slate Hlog when it [Save A] successfully you can run it from the [Prog] menu or you can place [Hlog] on the top level menu and run it from there (Page 11).

You will NOT [Run] AP or HLudg or HLtop these are small routines that will be used by HLog The only program you [Run] will be HLog

So for each 'program' you select [New] from the [Prog] menu.. You will need all four (AP, HLudg, HLtop and HLog) before you can [RUN] HLog

Keep going...
hawsey
Posts: 41
Joined: Fri Jul 02, 2021 12:34 am

Re: HamLog - amateur radio contact logger.

Post by hawsey »

Thanks , so after each one should I be doing Mode Trans Save ? , The. First three little routines , I just typed them all in then did Mode Trans Save .
Do I start again 🤔
Post Reply