Dmr Programming Software For Mac
In this article I share how you can upgrade the firmware and also upload a codeplug to the Tytera MD380/MD390 on Mac OS (or Linux) with VirtualBox.
This guide should work with the following radios with or without GPS:
- Tytera/TYT MD380
- Tytera/TYT MD390
- Retevis RT3
- Retevis RT8
Although the focus is on Mac OS, thanks to VirtualBox it should also work on Linux. Please note that this guide is based on my personal tests with the TYT MD390 GPS and comes with absolutely no warranty.
Spot Spot is a DXCluster client program for Mac OS X that automated spot and announcement filtering, automatic call sign lookup, and more.
The challenge: Tytera data cable and USB driver problems
I recently received my Tytera MD390 in the mail straight from Shenzhen, China. I am using a Macbook with Mac OS and that makes it challenging to get Tyteras programming software CPS to run, which is a Windows application.
At first I thought I could simply install Windows 10 on a virtual machine on my Macbook and just upgrade the firmware and upload the codeplug from there. However, I never got it to work.
Therefore had to find a workaround solution:
- We will be using Tytera’s original CPS software to program the codeplug and setup the channels, contacts and all settings for the radio.
- Then we will upload this codeplug via a Linux virtual machine.
- In addition, we will upgrade the firmware of the MD380 or MD390 GPS.
Do you have the right USB cable?
When I first wrote in several web forums telling about my problems with the data cable and USB drivers, I got a reply that my Tytera MD 390 probably came with the wrong cable. Reportedly, a batch of the radios had been shipped with the wrong cable a month earlier.
To find out whether you got the right cable do the following: Ncr 7197 printer drivers for mac.
- Unplug the cable from the radio (i.e. the radio is NOT connected to the cable) and plug the USB cable into your Macbook.
- Go to Applications -> Utilities -> System Information. Under “Hardware” find the “USB” menu. If you now see any USB device related to your radio, you have the wrong cable.
Why is that so? The right cable is a purely passive cable, the logic is in the radio. That means when the radio is not connected, it should not show up in the hardware list (or device manager on Windows). You have the right cable when a USB device shows up and the radio is switched on.
In my case, I had the right cable. When I turned the radio on, it showed up as “AnyRoad Technology Digital Radio in USB mode” in the hardware list.
I installed Windows 10 on a virtual machine, installed the driver from Tytera and the device showed up as “STM device in DFU mode” in the Windows device manager. I also installed Tyteras CPS application.
Still, I could not get it to work. The Tytera CPS application would not “read” or “write” from the radio. I tried many different things, uninstalled and reinstalled the driver, but could not get it to work. If you have any idea, please comment on this post.
Therefore I needed to find a workaround: I created my codeplug on the Windows virtual machine with the original Tytera software. Then I would upload the codeplug via Linux (also on a virtual machine) to my Tytera MD390 GPS.
Here’s the step-by-step guide:
Part 1: Upgrading the TYT MD380 / MD390 firmware
In this part, we will upgrade the firmware with a customized version specially made for amateur radio use. This firmware is called md380tools and has, compared to the original TYT firmware, some additional features that are handy for ham radio use.
The md380 tools run natively on Linux, which can be a bit tricky and time consuming to set up. That’s why Warren Merkel, KD4Z, created a ready-made VirtualBox image called md380tools-vm.
To upgrade the firmware, follow these steps:
- Follow the instructions for md380tools-vm that is given in the PDF up to and including “Step 5: Import the virtual appliance image file“. Do not start with step 6 just yet.
The PDF with installation instructions can be found on the projects website. Scroll down to after the file list, the PDF is the second link: https://github.com/KD4Z/md380tools-vm - Connect your radio to the Macbook and switch it on.
- After you installed Oracle VirtualBox and imported the appliance with the md380tools-vm, right click on the “tyt” image and select “Settings”. In the settings dialogue, go to “Ports” and the “USB”. In the lower part, click on the USB stick icon with the “+”-sign. Your radio should now show up as “Digital Radio in USB mode” (after you upgraded the firmware it will show up as “Patched MD380” like on the screenshot below).Select it, it will be added to the USB filter list. This filter list makes sure your USB device gets passed on to the virtual machine. Click “ok” to exit the dialogue.
- Now you have to put your radio into a special mode so that the firmware upgrade can be written. To do this, switch it off first. Wait 5 seconds. When you switch it on, hold the PTT-button and the upper button pressed. The radio will boot up, but you will only see the LED light flashing red and green. Your radio is now ready to get the new firmware.
- Start the “tyt” virtual machine.
- Follow now the instructions from “Step 6 – Start the VM” and “Step 7: Verify networking is working” from the PDF.
- Once all looks good, we can start the flashing of the firmware. Depending on your type of radio (it comes either with or without GPS) you have to use different commands.
For the TYT MD390 GPS (with GPS) do the following (for other models see the PDF): - Enter “glv” and press enter. That will download and compile the latest version of the firmware. Check whether everything runs smoothly.
- Once it is finished, run “flashgps“. This command will actually write the firmware onto your radio. Ensure that you don’t touch you radio during this process. After about a minute or two, it should be finished. Wait until it is completed, and the turn your radio off.
- Wait 5 seconds. Turn your radio on again. This time, it should boot with the new firmware and should start into normal mode. Now run “flashdb” which will write an updated user database onto your radio. This process takes about 3 minutes. After it is completed, switch off your radio and you can follow the instructions under “Fun Times” in the PDF if you like (not necessary though).
Now part 1 is finished, your data cable is working and you have upgraded the firmware on your Tytera radio! The tool should also be able to write the original firmware back if needed, however this I haven’t tried yet)
Part 2: Setting up a Windows image on VirtualBox
In the second part, we will set up a Windows installation in VirtualBox and install Tytera’s CPS software. With this software, we will be able configure the MD380 / MD390 and set up channels and contacts.
Prerequisite: You need a Windows installation image in ISO format that you can get from Microsoft and a valid product key.
I will only describe the most important steps, let me know if something is unclear.
- Start VirtualBox, click “New“. Enter a name, like “Windows 10“, select the right type and version of Windows and click “continue“.
- Adjust the RAM memory, 4 GB would be good if you have it. Click “continue“.
- Select “Create a virtual hard disk now“. Click “continue“.
- Select “VDI“, click “continue“. Then select “Dynamically allocated“. Select a file location. Then click “create“.
- Now, the new virtual machine shows up in the list. Right click on it, and select “Settings“. Go to “Storage” and click on the CD-ROM icon that says “empty” on the left side. Then, on the right side, click on the CD icon and select “Choose virtual optical disk file“. Now select a Windows installation ISO file that you can get from Microsoft. Then click “ok“.
- In the main window, select your Windows image and click “start“. Follow the regular Windows installation process.
- Once Windows is installed, and running in the VirtualBox window, click in the top menu (on Mac OS) on “Devices” and select “Insert Guest Additions CD image“. Then install the guest additions on Windows. They will improve the graphics and overall functioning of your system. Windows should be working normally now.
- Download and install the Tytera CPS software from the download section of the Tytera website. Make sure you download the right version for your model (with or without GPS). There are also other websites that offer the Tytera software to download.
You should now have a working Windows image running on VirtualBox with the Tytera software installed.
Type or paste one of the following commands in Terminal. Open Terminal, which is in the Utilities folder of your Applications folder. Mac install location for spore. Connect the USB flash drive or other volume that you're using for the bootable installer. Make sure that it has at least 12GB of available storage and is. These assume that the installer is still in your Applications folder, and MyVolume is the name of the USB flash drive or other volume you're using.
Part 3: Creating and uploading a codeplug to your Tytera TYT MD380 / MD 390
Now you can open Tytera’s CPS software on the Windows image and create your own codeplug or use an existing one as a basis. Here is a good guide for this. Skip down to “Program in DMR ID” on the page.
Once your codeplug is ready, we can start to upload it to the radio. In my case, it did not work via Windows. (Though, you can try to connect your radio to the Windows virtual machine. If it works for you, please let me know.)
As a workaround, we can upload the codeplug via the Linux image used in Part 1. Here are the steps:
- Save the codeplug on a USB stick that is formatted with FAT32 and call it codeplug1.rdt Once done, remove the USB stick.
- Shutdown the Windows virtual machine.
- Start the tyt virtual machine with the md380 tools on it and wait until it booted up.
- Plug in the USB stick. You should now get an “error message” on Linux, which is actually good because it tells you the name of the USB stick in Linux.
It says something like “[sdb] No caching mode page found.” (see screenshot below)
sdb is the location of the USB stick, memorize it for a later step.
(If your USB stick does not show up, click on the USB icon beneath the window and select the USB stick. Alternatively, set up a filter for the USB stick similar to the filter for the radio in part 1). - Switch to root. Root is the administrator under Linux. Do this by entering “su“. Enter the password which is “tyt“.
- Now mount the USB stick, which will make it accessible on Linux. First create a directory for the USB stick. Run “mkdir /media/usb“. Then run the following command: “mount -t vfat /dev/sdb /media/usb“. Use the sdb from step 4. It could also be sdc or sdd and so on.
- Now the contents of the USB stick are located under /media/usb and you can copy the codeplug to the home folder. Do this by running “cp /media/usb/codeplug1.rdt /home/tyt“.
- Switch to the md380tools directory by running “cd /home/tyt/md380tools“.
- Run “umount /media/usb” to unmount the USB stick. Remove it afterwards.
- Now, connect the radio to the virtual machine and switch it on in normal mode. Check by clicking on the USB icon whether the radio has the “checkmark”. That means it can be seen by the virtual machine.
- Now we write the codeplug on to the radio. That is done by the command “./md380-dfu write /home/tyt/codeplug1.rdt“. After a few seconds, the codeplug is on your radio. Switch off the radio. Done!
Wrapping up
You should now have a working radio with the latest custom firmware and the codeplug of your choice. If you make changes to your codeplug, just rerun the steps from part 3.
If you need help, comment on the post below or check the following resources:
- Facebook group TYT MD-380 Tools: A great group where I was helped a lot!
- Facebook group DMR Digital Mobile Radio: A group for general questions about DMR.
- Yahoo mailing list TYT-Tytera MD380 Users Group
- Google group MD380 tools.
Good luck and 73!