Opengd77-Csv by G4Eml: Description
Opengd77-Csv by G4Eml: Description
Description
Managing large codeplugs for DMR radios can be difficult using the programming software or CPS.
This utility was written to enable major edits and modifications to be made using a spreadsheet
program such as Microsoft Excel or LibreOffice Calc. Using spreadsheet programs allows the use of
their powerful editing facilities such as Copy and paste, sorting, find and replace, automatic number
incrementing, etc.
This utility has been written to work with the OpenGD77 firmware and only handles items that are
used by that firmware. Codeplugs modified using this utility may not work if loaded into radios
running the stock manufacturers firmware.
A codeplug contains several different types of data. Some items such as the users DMR ID are only
entered in one place, other items consist of large tables of entries.
This utility only addresses the four main lists:-
Contacts:- These define the DMR IDs of regularly used Talkgroups and Individual users.
TG Lists:- These arrange regularly used Contacts into convenient groupings.
Channels:- These are the definitions of the RF parameters needed for communication.
Zones:- These arrange channels into convenient groupings.
The initial function of this utility is to take an existing codeplug, extract the data for the 4 lists and save
that data in 4 separate files. Contacts.csv, TG_Lists.csv, Channels.csv and Zones.csv.
The format of these files is CSV or comma separated variables. This type of file can be opened and
modified using any spreadsheet program. The 4 files are expected to be contained in a single folder.
Because the four different lists cross refer to each other it is important to keep all four files together and
synchronized. For example if you rename a channel in the Channels.csv file then you must also rename
it in the Zones.csv file.
Once the files have been modified using a spreadsheet they should be saved back as .csv files.
This utility can then be used to import those modified files into a codeplug which can then be saved for
use in the radio. You can either use and existing codeplug which will result in all of the other setting
being retained or you can use a blank codeplug which will then need you to add your user ID and other
minor settings using the CPS.
Program
The program and this document can be downloaded from
https://www.gb3gf.co.uk/Files/OpenGD77-CSV.zip
The program consists of a single .exe file which can be run on a Windows computer.
All operations are done in a single window.
At the top of the window are 6 buttons. Only the first two of these will be visible if no codeplug has
been loaded.
Below these buttons is a checkbox ‘Use Commas for Decimals’. See later for details.
Below that is a textbox which is used to display progress messages.
Button Functions
Use Blank Codeplug
Loads a blank codeplug with all the settings set to the defaults used by the CPS.
This blank codeplug contains 1 zone, 1 channel, 2 TG Lists and 5 Contacts.
The main use for this is to be able to build a new codeplug from scratch by importing csv files. It is
likely that the example contents of the file will be overwritten by the new data.
It can also be used to create 4 minimal .csv files that can then be used as templates for editing.
The resulting codeplug will not be immediately usable, you will need to open it using the CPS
program, add you DMR ID and make any other settings changes you need.
Shows a dialogue enabling you to navigate to find an existing codeplug. Codeplugs are recognized by
their .g77 suffix.
On opening the codeplug you will see a summary printed in the text area. This will list the number of
Contacts, TG Lists, Channels and Zones found in the codeplug.
These lists are read into internal variables of the utility ready to produce the .csv files.
Displays a dialogue asking for a folder in which to save the .csv files. It is recommended that the four
files are saved into their own folder. This can be an existing one or you can create a new one. The
folder should be named to indicate the contents of the .csv files.
Once you have selected the folder the four .csv files will be created in that folder.
A summary of the file contents will be printed in the text area. This should be the same as seen when
opening the codeplug.
The ‘Use Comma for Decimals’ checkbox controls the format of the created .csv files.
If this is unchecked then numbers will use the full-stop (period) as the decimal separator. e.g. 145.525
If this is checked then numbers will use the comma as the decimal separator. e.g. 145,525
In both cases the deliminator between fields will use the semi-colon.
Displays a dialogue asking for the folder containing the .csv files. Once you have selected the folder
the files will be read and inserted into the currently loaded codeplug.
Important note:- Any existing contacts, TG Lists, Channels and Zones will be deleted and replaced
with the ones from the .csv files. This is the recommended way of sorting and reloading existing
codeplugs.
After loading a summary of the new contents will be displayed.
Append CSVs to Codeplug
Displays a dialogue asking for the folder containing the .csv files. Once you have selected the folder
the files will be read and appended to the currently loaded codeplug.
Important note:- If the name of an entry in any of the .csv files is the same as an existing entry in the
codeplug then the codeplug entry will be overwritten with the new data. If the name of an entry in
the .csv file is unique then it will be appended to the end of the codeplug.
Matching is done using the name of an item and not the data. So it is possible to end up with, for
example, two channels with identical settings but different names.
After the appending process has completed a summary of the new codeplug contents will be displayed.
This should reflect any changes in the number of items.
Save to Codeplug
Displays a dialogue asking for a filename to save the new codeplug to. This can be the same filename
as the original codeplug. However it is recommended that a new name is used just in case any
unexpected errors have occurred. In that way the original codeplug will be untouched.
Codeplugs should be saved with the .g77 suffix to ensure that they can be read by the CPS.
Typical workflows
CSV Files
Each .csv file can be opened with a spreadsheet program. Normally there will be a dialogue before
opening the file. Ensure that the separator or delimiter option is set to use semi-colons. This will ensure
that the entries are correctly assigned to columns in the spreadsheet.
When saving the files after editing make sure that they are saved in .csv format and not the normal
spreadsheet format.
When modifying the file it is important to ensure that the columns remain in the same order. For
example when creating a new channel it is easiest if you copy the entire line of an existing channel and
then paste it as the new channel. Then edit the contents of that new channel. This ensures that all
columns contain valid data.
Each cell of the spreadsheet can contain a number or text depending on their use. It is important that the
text used in some columns is exactly correct including captalisation. For example ‘No’ is not the same
as ‘no’ and ‘12.5KHz’ is not the same as ‘12.5 khz’.
For this reason it is best to copy and paste from another cell with a similar setting. Valid values are
listed below.
You may find that some entries are preceded by a single quote mark ‘ this is used when a name
contains numbers and may be interpreted incorrectly by the spreadsheet program. Adding a leading
single quote forces the field to be treated as a string. The extra character is removed when re-imported
into the utility.
Contacts.csv
The first line is the Header line and should not be changed.
The 4 Columns are as follows:-
TG_Lists.csv
The first line is the Header line and should not be changed.
The 33 Columns are as follows:-
Contact1-Contact32:- Text entries for each member of the TG List. These names must match exactly
the names defined in contacts.csv. A maximum of 32 entries. Can be left blank if not needed.
Zones.csv
The first line is the Header line and should not be changed.
The 81 Columns are as follows:-
Channel 1 – Channel 80 :- Channel name for each member of this zone. These names must match
exactly the names defined in channels.csv.
Channels.csv
The first line is the Header line and should not be changed.
The 19 Columns are as follows:-
Channel Number:- A number that defines the ‘All Channels’ channel number for this entry.
This can be between 1 and 1023. When loaded into a radio that is set to the ‘All channels’ zone the
channel can be directly accessed by keying in this number. Numbers do not have to be sequential and
can have gaps but they do have to be unique. It is recommended that this column is renumbered after
any editing of the spreadsheet. Also note that if you use the ‘Append CSVs to Codeplug’ option this
number is ignored and all existing channels will be compacted and numbered sequentially.
Rx Frequency:- A numeric entry. Can use comma or full-stop as the decimal separator.
Tx Frequency:- A numeric entry. Can use comma or full-stop as the decimal separator.
Timeslot:- 1 or 2
Power:- ‘Master’, ‘50mW’, ‘250mW’, ‘500mW’, ‘750mW’, ‘1W’, ‘2W’, ‘3W’, ‘4W’, ‘5W’ or ‘5W++’