Tuesday, January 13, 2026

Python script energizes my contesting setup.


 

I have been working on some Python scripts to automate tasks that I would rather not do manually. The video above shows my contest station powering up from start to finish.

Why do this, you ask? The part of the amateur radio hobby that really interests me is CW contesting. Now that I am retired, I take part in four weekly one-hour “mini” contests and, in an average month, I spend two or three weekends CW contesting as well.

The programs I use need to be started in a specific order. For example, I must start my virtual port program (VSPE) first, and then start the radio and contest programs in a certain sequence. If this order is not followed, I get flooded with error messages.

Some say I over complicate things, but I am somewhat of a perfectionist and like everything set up just so. Python lets me achieve that with a single mouse click. There has been some fine-tuning of the Python code along the way. For example, my radio control program Win4Icom is delivered as a complete new program with each update, rather than as an add-on to the original, as the N1MM+ contesting program does. Because of this, I wrote the script for Win4Icom so that it always checks for and runs the highest revision number of the program; otherwise, it would just continue to load the same old version.

I also had to introduce delays between the startup of some programs. After VSPE starts, I delay Win4Icom by five seconds, because VSPE is still initializing in the background and Win4Icom would otherwise throw errors. I also added a step to minimize VSPE to the taskbar once it starts, so it does not sit on the screen. As Win4Icom starts, I added a 10-second delay while it powers up my Icom 7610 and sets up the COM port configurations for N1MM+. I found N1MM+ needs to wait for those steps to complete before it begins its own startup. Finally Reverse Beacon Network web page is setup to open with my call sign showing spots where it is heard. 

 Here's the sequence shown in the YouTube video:

  • WiFi smart plug powers on.

  • Astron power supply powers on seen in the lower left corner .

  • Raspberry Pi 4B boots (red power LED visible on desk), launching HamClock.

  • VSPE starts and minimizes to taskbar.

  • Win4Icom launches, powering on the Icom 7610.

  • Reverse Beacon Network loads/refreshes as HamClock continues to load.

  • N1MM+ Logger starts.

Next up: Python shutdown scripting (with its own challenges). I'm also 3/4 through a script to generate ADIF file of contest contacts that exports and auto-upload to N3FJP, Club Log, LoTW, CWops, and QRZ.com. Stay tuned!


No comments: