AB3AP's K2 Rig Control Software


The rig on 40m, VFO A, preamp on, reverse CW. Looks familiar, eh? :-)

The program uses the K2's KIO2 serial port to control the rig. The rig image is from the front of the K2 pdf manual so using the program is as familiar as using your real K2. Note that the image above isn't a mock up; it's a snapshot of the working interface.

If you use a K2 you know how to use this program:

Comparison Between K2 and Program

Here are short lists of where each has advantages over the other. I strongly recommend using the real K2, not my software, when making any changes to the K2 through MENU or monitoring any measurements related to power.

Where the Real K2 Wins

The K2 has advantages the program does not.

Where the K2 Rig Control Software Wins

But the software has some advantages, too.

Starting the Software

Using the program is easy. But don't forget - you must right-click anywhere in the picture and then choose the name of the serial port that your K2 is hooked up to. Now you should be and running and controlling your K2 with the mouse!

Click briefly on a button to simulate a button tap, and click and hold to simulate a push and hold on the K2. To spin knobs, click and hold the mouse button down anywhere within a knob and then move the mouse. While moving, the mouse doesn't have to remain within the knob area. It's actually helpful for fine adjustments to pull the mouse farther from the knob.

Phantom Buttons

This is my favorite feature, as it lets me finally learn all the dual button combos. Here are pictures of the NF (notch filter on/off) and NR (noise reduction on/off) phantom buttons when your mouse moves along the right edge of the rig. They pop up and give you the choice of clicking on the "real" (original) buttons or on the phantom button to get the multi-button combo function. Hopefully, this helps remember the button combos when not running the program.

Notch filter on/off. Noise reduction on/off.

Similarly, phantom buttons appear when the mouse moves over them in the same area of the front panel for FIL (check filter status), AGC (AGC on/off), and RIT (Fine RIT on/off), as shown in the following pictures.

Filter status. AGC on/off. Fine RIT on/off.

Finally there is the phantom button representing the dual DISPLAY/TUNE combination. It displays the forward and reflected power.

When a phantom button appears - and same goes for the "F" that appears by the BAND buttons - simply click on it like any other button for that function.

As mentioned earlier, I find it handy to have the K2 program running while I'm reading the pdf version of manuals. For the KDSP2 this has especially been the case when trying to become familiar with its many submenus. Reaching between rig and manual gets a little frustrating after a while and using the rig control software saves you that.

How It Works

The program sends commands to the K2 based on the buttons you click or the knobs you spin. In addition a timer is continually running that wakes up every 100 milliseconds. If another command is not being acted upon, the program will ask the K2 (with a DS command) to send the state of its screen which the program will then mimic. Before a display update request is sent to the K2 the program first checks that the rig is in receive mode. Simple, right? That's really all there is to it: map a click or key press to a rig function, send it to the K2, update the display, and then take a short nap.

Continual polling is used so that the screen display is correct even if the op uses the real buttons rather than the on-screen ones. If we're willing to do away with that consideration, state could be kept internally and polling eliminated. Food for thought.

What Doesn't Work

I don't like how the keyer knob works. It would be nicer if regardless of where you click on the knob that spinning would be relative to the current setting. Instead it sets speed immediately based on where you click. Why? I got tired doing all the coding and instead wrote up this page...

Other considerations are compensating for times when the K2 DS command doesn't give annunciator info, e.g., underlining during MENU, EDIT, DISPLAY, and the 3 second blink cycle during FINE RIT. At the moment I don't try to compensate for any firmware short comings but just report data as received.

create counter