Modified Baofeng UV-17 Pro CPS software 1.2.4e

I’ve owned a number of Baofeng UV-17 Pro GPS radios for some time and I’ve previously posted a teardown here on this blog. John Miklor has posted a detailed review on his site.

I had been hoping CHIRP would add support for this radio as I’ve had an issue open to add support for it for some time. Unfortunately, there are a huge number of requests competing for the CHIRP team’s time and this is not a simple thing to add – this radio uses a completely different programming interface and properly supporting it would require re-architecting parts of CHIRP’s basic structure – as an example, this radio model has 10 zones of 100 channels each. This would either mean a 1000-row list in CHIRP or adding a new way to select zones.

The factory CPS (Customer Programming Software, presumably) is very basic. In addition to an overall lack of features there are a number of annoyances ranging from the minor (some error messages only display in Chinese) to the major (the software won’t let you enter frequencies in the 108-136MHz aircraft band, even though the radio can receive them).

I initially thought “How hard could this be to fix?” and released a patched version of the factory software which I called 1.2.4a to distinguish it from the factory software. This got an excellent reception from the user community and soon requests for additional features started coming in, as well as a report that a certain series of steps would disable entry of aircraft band frequencies again. The sequence was odd enough (program frequencies in CPS, write to radio, read from radio and try to edit) that only one user ran into it. I released my 1.2.4b and 1.2.4c versions in rapid succession, but was unable to entirely eliminate the reported error. It also became clear that a number of feature requests from users could not be accomplished by simply patching the factory CPS with a hex editor.

Fortunately, the factory CPS was built with Visual Studio and Microsoft .NET and the program included a full “symbol table” which meant that it was possible to “decompile” the program into source code that had meaningful labels – typically decompilation produces code with names like “L1874” instead of “ChannelNumber”. At first I looked at this source code solely as an aid to discovering where I needed to patch things, but then I decided to attempt “recompiling” it from scratch. Much to my surprise, Visual Studio produced a program that seemed to work just like the factory CPS (after I made a number of corrections to the decompiled code). I worked on a number of “1.2.4d Experimental” releases which fixed many more bugs (including finally fixing the “aircraft band disabled after reading from radio”) and added new features. This version was extensively tested by John Miklor and a few selected users. I refer to 1.2.4d and later as “modified” software instead of “patched” software as things have moved far beyond simple patching at this point.

Confident that I was heading in the right direction, I continued with development of 1.2.4e. In addition to changes I was making to the program, I also built an installer package so that all users needed to do was run a “setup.exe” program. John Miklor contributed a new icon (orange UV-17 radio) which is now the default icon. The original generic radio icon is still available for those that prefer it. John did additional extensive testing to make sure I didn’t break anything and verify that all of the newly-added features and bug fixes worked as expected.

1.2.4e was released on the web site today and I wrote this blog entry to provide a little history on how and why it came about.

This is the list of changes and what version they first appeared in:

Revision history:

Changes in 1.2.4a:
1) "Freqence is invalid" -> "Invalid Frequency!" error message
2) "ZONEE 5" -> "ZONE 5" in default settings
3) "v1.2.4" -> "1.2.4a" in About
4) "?????" (Chinese text 'Read Failed!') -> "ERR1!" when opening a file
5)  Changed lower VHF frequency limit from 136MHz to 108MHz

Changes in 1.2.4b:
6)  "1.2.4a" -> "1.2.4b" in About
7)  Fixed additional locations where the aircraft frequency is checked
8)  Added additional information to this file

Changes in 1.2.4c:
9)  "1.2.4b" -> "1.2.4c" in About
10) Changed header to show 108-174 instead of 136-174
11) Documented restriction after reading from radio

Changes in 1.2.4d Experimental-1:
12) Switch to full recompilation in Visual Studio instead of patching binary
13) Changed Properties / Details to provide information about executable
14) Changed various Chinese-only error messages to English
15) Fixed "ZONE 5" to not have trailing NUL
16) Changed "ERR1!" from item #4 to "File open/read error!"
17) Corrected various spelling / grammar issues in English messages
18) Increased normal window size to not need scroll bars
19) Changed main window title to "UV-17/18/19/20/21/22 Pro CPS - Unofficial Experimental by 
    Terri Kennedy"
20) REALLY fixed air band in channel list
21) Removed documented restriction from #11 as it no longer applies
22) Changed Help / About... to "Version 1.2.4d\nExperimental-1\nby Terri Kennedy"
23) Changed the default radio model to UV17PRO

Changes in 1.2.4d Experimental-2:
24) Changed VFO lower limit to 108
25) App icon is missing from source-built executable - reinstate
26) Change “Bank” labels to “Zone” to be consistent with radio’s usage

Changes in 1.2.4e Experimental-3:
27) "1.2.4d" -> "1.2.4e" in About 
28) Temporarily disable “Import Picture to Radio” in Tools menu as it is not working
29) Make sure all instances of minVHF refer to 108 (hard-code in assignments)
30) Change default icon to orange (from John Miklor), retain original as alternate icon
31) Change internal app icons to orange and add where missing
32) Auto-close the COM port dialog after port is selected
33) Start app in window mode instead of fullscreen
34) Fix .cs files not loading properly in Visual Studio 2019 Designer
35) Change ordering of Zone selection buttons on channel window, rename “Last” to “Previous” 
    to correctly reflect function.
36) Fix SK2 setting reverting to FM when downloading from radio
37) Use orange icon in Control Panel / Programs and features

Changes in 1.2.4e Unofficial Build:
38) Change “Experimental-x" to “Unofficial Build” in #19
39) Change “Experimental-x” to “Unofficial Build” in #22
40) Change “Experimental-x” to “Unofficial Build” in #13

I have a number of things planned for a future 1.2.4f release, but you’ll need to wait for that release. I think you’ll be amazed at what I’ve come up with! In the meanwhile, 1.2.4e is so much better than the factory CPS that you should definitely try if you have one of these radios.

Hopefully these improvements will encourage Baofeng to “up their game” in their own CPS software releases. Simply releasing a bare-minimum CPS is no longer sufficient if they want to be taken more seriously as a radio supplier. Since there is currently no CHIRP support for their newer radios, Baofeng can’t simply say “use CHIRP if you want something better”.

A few closing thoughts:

1) If Baofeng is interested in obtaining the improved CPS, they should definitely reach out to me.
2) It would probably be possible to make similar improvements to the CPS for other radio models. My interest is exclusively the UV-17 Pro GPS as those are the radios I have. I’d be glad to discuss technical details with anyone who wants to try the same sort of thing on a different CPS. I’d also consider doing the work myself on a “time and materials” basis. I’d need at least one radio of the desired model to verify proper operation, as well as funding for the project.

Leave a Reply

You must be logged in to post a comment.