{"id":1674,"date":"2023-08-10T18:20:00","date_gmt":"2023-08-10T22:20:00","guid":{"rendered":"https:\/\/www.glaver.org\/blog\/?p=1674"},"modified":"2023-08-31T02:45:13","modified_gmt":"2023-08-31T06:45:13","slug":"modified-baofeng-uv-17-pro-cps-software-1-2-4e","status":"publish","type":"post","link":"https:\/\/www.glaver.org\/blog\/?p=1674","title":{"rendered":"Modified Baofeng UV-17 Pro CPS software 1.2.4e"},"content":{"rendered":"<p>I&#8217;ve owned a number of Baofeng UV-17 Pro GPS radios for some time and I&#8217;ve previously posted a teardown <a href=\"https:\/\/www.glaver.org\/blog\/?p=1653\">here<\/a> on this blog. John Miklor has posted a detailed review on <a href=\"https:\/\/www.miklor.com\/COM\/Review_UV17proGPS.php\">his site<\/a>.<\/p>\n<p>I had been hoping <a href=\"https:\/\/chirp.danplanet.com\/projects\/chirp\/wiki\/Home\">CHIRP<\/a> would add support for this radio as I&#8217;ve had an issue <a href=\"https:\/\/chirp.danplanet.com\/issues\/10648\">open<\/a> to add support for it for some time. Unfortunately, there are a huge number of requests competing for the CHIRP team&#8217;s time and this is not a simple thing to add &#8211; this radio uses a completely different programming interface and properly supporting it would require re-architecting parts of CHIRP&#8217;s basic structure &#8211; 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.<\/p>\n<p>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&#8217;t let you enter frequencies in the 108-136MHz aircraft band, even though the radio can receive them).<\/p>\n<p>I initially thought &#8220;How hard could this be to fix?&#8221; 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.<\/p>\n<p>Fortunately, the factory CPS was built with Visual Studio and Microsoft .NET and the program included a full &#8220;symbol table&#8221; which meant that it was possible to &#8220;decompile&#8221; the program into source code that had meaningful labels &#8211; typically decompilation produces code with names like &#8220;L1874&#8221; instead of &#8220;ChannelNumber&#8221;. 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 &#8220;recompiling&#8221; 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 &#8220;1.2.4d Experimental&#8221; releases which fixed many more bugs (including finally fixing the &#8220;aircraft band disabled after reading from radio&#8221;) 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 &#8220;modified&#8221; software instead of &#8220;patched&#8221; software as things have moved far beyond simple patching at this point.<\/p>\n<p>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 &#8220;setup.exe&#8221; 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&#8217;t break anything and verify that all of the newly-added features and bug fixes worked as expected.<\/p>\n<p>1.2.4e was released on the <a href=\"https:\/\/www.miklor.com\/UV17pro\/Mod124.php\">Miklor.com<\/a> web site today and I wrote this blog entry to provide a little history on how and why it came about.<\/p>\n<p>This is the list of changes and what version they first appeared in:<\/p>\n<pre>Revision history:\r\n\r\nChanges in 1.2.4a:\r\n1) \"Freqence is invalid\" -> \"Invalid Frequency!\" error message\r\n2) \"ZONEE 5\" -> \"ZONE 5\" in default settings\r\n3) \"v1.2.4\" -> \"1.2.4a\" in About\r\n4) \"?????\" (Chinese text 'Read Failed!') -> \"ERR1!\" when opening a file\r\n5)  Changed lower VHF frequency limit from 136MHz to 108MHz\r\n\r\nChanges in 1.2.4b:\r\n6)  \"1.2.4a\" -> \"1.2.4b\" in About\r\n7)  Fixed additional locations where the aircraft frequency is checked\r\n8)  Added additional information to this file\r\n\r\nChanges in 1.2.4c:\r\n9)  \"1.2.4b\" -> \"1.2.4c\" in About\r\n10) Changed header to show 108-174 instead of 136-174\r\n11) Documented restriction after reading from radio\r\n\r\nChanges in 1.2.4d Experimental-1:\r\n12) Switch to full recompilation in Visual Studio instead of patching binary\r\n13) Changed Properties \/ Details to provide information about executable\r\n14) Changed various Chinese-only error messages to English\r\n15) Fixed \"ZONE 5\" to not have trailing NUL\r\n16) Changed \"ERR1!\" from item #4 to \"File open\/read error!\"\r\n17) Corrected various spelling \/ grammar issues in English messages\r\n18) Increased normal window size to not need scroll bars\r\n19) Changed main window title to \"UV-17\/18\/19\/20\/21\/22 Pro CPS - Unofficial Experimental by \r\n    Terri Kennedy\"\r\n20) REALLY fixed air band in channel list\r\n21) Removed documented restriction from #11 as it no longer applies\r\n22) Changed Help \/ About... to \"Version 1.2.4d\\nExperimental-1\\nby Terri Kennedy\"\r\n23) Changed the default radio model to UV17PRO\r\n\r\nChanges in 1.2.4d Experimental-2:\r\n24) Changed VFO lower limit to 108\r\n25) App icon is missing from source-built executable - reinstate\r\n26) Change \u201cBank\u201d labels to \u201cZone\u201d to be consistent with radio\u2019s usage\r\n\r\nChanges in 1.2.4e Experimental-3:\r\n27) \"1.2.4d\" -> \"1.2.4e\" in About \r\n28) Temporarily disable \u201cImport Picture to Radio\u201d in Tools menu as it is not working\r\n29) Make sure all instances of minVHF refer to 108 (hard-code in assignments)\r\n30) Change default icon to orange (from John Miklor), retain original as alternate icon\r\n31) Change internal app icons to orange and add where missing\r\n32) Auto-close the COM port dialog after port is selected\r\n33) Start app in window mode instead of fullscreen\r\n34) Fix .cs files not loading properly in Visual Studio 2019 Designer\r\n35) Change ordering of Zone selection buttons on channel window, rename \u201cLast\u201d to \u201cPrevious\u201d \r\n    to correctly reflect function.\r\n36) Fix SK2 setting reverting to FM when downloading from radio\r\n37) Use orange icon in Control Panel \/ Programs and features\r\n\r\nChanges in 1.2.4e Unofficial Build:\r\n38) Change \u201cExperimental-x\" to \u201cUnofficial Build\u201d in #19\r\n39) Change \u201cExperimental-x\u201d to \u201cUnofficial Build\u201d in #22\r\n40) Change \u201cExperimental-x\u201d to \u201cUnofficial Build\u201d in #13<\/pre>\n<p>I have a number of things planned for a future 1.2.4f release, but you&#8217;ll need to wait for that release. I think you&#8217;ll be amazed at what I&#8217;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. <\/p>\n<p>Hopefully these improvements will encourage Baofeng to &#8220;up their game&#8221; 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&#8217;t simply say &#8220;use CHIRP if you want something better&#8221;.<\/p>\n<p>A few closing thoughts:<\/p>\n<p>1) If Baofeng is interested in obtaining the improved CPS, they should definitely reach out to me.<br \/>\n2) 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&#8217;d be glad to discuss technical details with anyone who wants to try the same sort of thing on a different CPS. I&#8217;d also consider doing the work myself on a &#8220;time and materials&#8221; basis. I&#8217;d need at least one radio of the desired model to verify proper operation, as well as funding for the project.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve owned a number of Baofeng UV-17 Pro GPS radios for some time and I&#8217;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&#8217;ve had an issue open to add support for it [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[15],"tags":[],"_links":{"self":[{"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1674"}],"collection":[{"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1674"}],"version-history":[{"count":11,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1674\/revisions"}],"predecessor-version":[{"id":1685,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=\/wp\/v2\/posts\/1674\/revisions\/1685"}],"wp:attachment":[{"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1674"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1674"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.glaver.org\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1674"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}