NOVEMBER 3 VICTOR ECHO MIKE
  • Blog
  • Events and Activations
  • Diversions
  • About
  • Gallery
  • Contact
  • Links
  • Subscribe
  • Search
  • Blog
  • Events and Activations
  • Diversions
  • About
  • Gallery
  • Contact
  • Links
  • Subscribe
  • Search
NOVEMBER 3 VICTOR ECHO MIKE

ham radio Projects and musings from a (Relatively) new operator

DIY Rig Control in Python

8/3/2017

2 Comments

 
Picture
This is something I've been meaning to share for some time, but just haven't gotten around to actually sharing.  As some of you may be aware, I am an "adult-learner."  The company I work for has been graciously paying for my BS in Information Systems (I currently hold an Associates Degree, which they also paid for!)  For one of my classes we had an open-ended assignment to do a fairly significant project.  Obviously, I chose something radio related!  Some of the information here might be a little confusing if you're only a computer appliance operator, but I'd encourage you to skim through it - even if you learn just one small thing it's worth it!  If you're a software developer, this stuff is probably all very elementary, but I'm sure there are lots of folks like me who land somewhere in the middle that might get some benefit from this!

For the class, we had to write a project proposal, a plan, do the work, and then present our project.  I'll share all that so that you can look at the details if you want, but my "secret" mission was to learn a bit more about how software rig control actually works.  With that in mind, I wrote a software Class (huh? Whats that?) which I called yeasuControl, that would handle interfacing my Yeasu 857d with a Raspberry Pi.  To verify that yeasuControl worked as intended, I also wrote a very basic, text-based rig control program, which I named "radioInterface3" (I wrote it in Python 3, and my first 2 versions were a bust, so it just kind of worked out that there were 3's all around.)  For some wow-factor when I did my demonstration in the classroom, rather than run it straight from the Pi, I accessed the Pi via a separate PC over Broadband Hamnet (I wasn't yet aware of AREDN) with everything running off 12v power, to demonstrate the possibility of a field deploy-able, remotely accessible, radio station.
Picture
Technically, the software I wrote doesn't do anything new, but just like some people enjoy building their own radio's (even though you could just buy one), I think it's fun to write my own software (even though I could just download something!)  Pretty much everything that the software Class I wrote will do is already included as part of hamlib, but writing this myself helped me learn exactly what's going on when I connect those magic wires between my rig and computer!  Oh - this was also my first foray into Python, so I also used this project to learn a new language. (although, really, once you know any C based language, the rest of them are usually pretty easy to pick up.)
With the intro out of the way, I figure the easiest way to go about this is to just share the documents, and give a summary of each one.  You can feel free to download them, read them, and use them, if you want to see the nitty-gritty details.  Alternatively, you can just skim the descriptions to see what I did.  I'm sharing all of this under the "Karma License." (I just made this up - it means do whatever you want with it, but know that Karma will come for you if you deserve it based on what you do...)  
document_1_-_yaesucontrolpresentation.pdf
File Size: 407 kb
File Type: pdf
Download File

Presentation - This first document is an overview PowerPoint that I used when presenting my final project.  The presentation itself doesn't have a lot of information, because most of the demonstration was hands-on with the hardware and software.  (just a tip - If someone can understand your whole message just by looking at the PowerPoint, you probably included too much in the PowerPoint.)
document_2_-_project_proposal.pdf
File Size: 183 kb
File Type: pdf
Download File

Project Proposal - Before we actually started the project, we had to write a proposal, and get approval from our professor to begin.  In this proposal I explained the software I was proposing to write (the yeasuControl Class), and gave an example of it's potential use, by explaining what ARES, RACES, etc. are, and how those organization could use something like this.  This is where I detailed that the core of the project was the yeasuControl software, and that the scope of the project would revolve around this software - any actual interface software (radioInterface3) and hardware was just to support demonstrating yeasuControl's functionality.
document_3_-_project_plan.pdf
File Size: 149 kb
File Type: pdf
Download File

Project Plan - ​This is the fully fleshed out project and scope.  This included details on the management of the project, it's schedule (5 weeks from start to finish), and the scope.  For highlights, the main purpose was to write the Class, and to include in that class all of the functionality that Yeasu CAT control can support.  Secondary to the scope was writing a minimally viable user interface (radioInterface3), to demonstrate the functionality of the class.  Since it's text base, you could technically use this rig control software on a computer that doesn't have a GUI installed - for single board computers this is sometimes a benefit, because you don't lose processing power running a pretty window manager.  The scope also includes details on the types of hardware that the software should be able to run on, etc.  Because this was something that needed to be done rapidly, I had to keep the scope pretty tight.
document_4_-_yaesucontrol_class_documentation.pdf
File Size: 176 kb
File Type: pdf
Download File

Class Documentation - ​This is the documentation that explains each class object attribute, what it does, and how to use it.  For the non-IT minded, this document doesn't explain how an end-user uses a piece of software - it explains how a software developer would use this within the software they are making.  You can think of it like the manual that an engine manufacture would prepare for the auto-maker.  It's documenting a specific part, not a whole program.
document_5_-_radiointerface3_documentation.pdf
File Size: 164 kb
File Type: pdf
Download File

radioInterface3 Documentation - This is the document that reads like a user manual for the the program that could be considered the user-interface.  This program was written to be the most basic possible program (minimally viable) that would demonstrate the functions of the yeasuControl Class.  It is text based, but if you have a very low-power computer, that might be just the ticket you need.
python_files.zip
File Size: 7 kb
File Type: zip
Download File

Python Files - Here they are, the actual .py files containing the code I wrote. If you like to tinker around with Python programming, I hope these help.  If you're a pro, be nice when you critique my work (I am an amateur after all!) I don't have room for an entire Python lesson here, but if you do a Google search for "Python Basics" you'll find all sorts of information, including information on how to compile these and use them if you want to just take what I wrote and use it as-is.
So, there you have it!  I hope at least some of you can glean some useful information out of my work.  In the interest of the betterment of the ham radio hobby, and doing whatever I can towards our collective Elmering in the hobby, I'm offering all of this info, and the work I put into it, with no strings attached.  If you play around with it and have questions (like what serial interface I used with the Pi, etc.) feel free to check out my contacts page and reach out to me.

​  Enjoy!
2 Comments
Forward>>

    Categories

    All
    Antenna
    Cw
    Digital-modes
    Flying-with-gear
    Home QTH
    Miscellaneous
    Mobile
    Operating Events
    Portable
    POTA
    Shack Build
    Technical


    - N3VEM -

         Welcome to my Ham Radio Blog!  This blog was started primarily to share my two concurrent shack builds - my mobile station and my home station.  Over time, this has grown to include sharing about my operations, and general radio-related thoughts that I have as a newer operator.  
         
    ​Enjoy!

    RSS Feed


    Picture
    POTA!

    Picture
    Proving that hams do indeed still build stuff!

    Picture
    100 Watts and Wire is an awesome community, based around an excellent podcast. 

    Archives

    September 2020
    July 2020
    January 2020
    September 2019
    August 2019
    July 2019
    June 2019
    May 2019
    March 2019
    January 2019
    December 2018
    November 2018
    October 2018
    September 2018
    August 2018
    July 2018
    June 2018
    May 2018
    April 2018
    March 2018
    February 2018
    January 2018
    December 2017
    November 2017
    October 2017
    September 2017
    August 2017
    July 2017
    June 2017
    May 2017
    April 2017
    March 2017
    February 2017
    January 2017
    December 2016
    November 2016
    October 2016
    September 2016
    August 2016
    July 2016
    June 2016
    May 2016
    April 2016
    March 2016
    February 2016
    January 2016
    December 2015
    November 2015


Picture
Copyright © 2015
 Vance Martin is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to amazon.com.