Adding Bluetooth Support to the Xiegu G90 HF Transceiver
-- from Blog of Amateur Radio enthusiast Ed Durrant
A “proof of concept” action.
First, it is important to define what we are doing here. Some modern radios have Bluetooth built-in so that they can be operated remotely. The G-90 does not.
I want to add such control to the XIEGU G90 (this may also work with the X5105 model as well, but this has not been tested). I do not intend to open the radio case, rather I will add standard external modules that are available over eBay and other online retailer sites. There are two parts to this action.
Audio via Bluetooth.
The first stage is to get audio to and from the radio from some Bluetooth enabled headset or earpiece, as used with many Smartphones these days. I expected this should be the easy part of the solution while there are many standard solutions available for this that can be purchased for a few dollars/Euros/pounds. Unfortunately, this part of the solution caused me the greatest problems as the issue with the common units is that they operate as a transmitter or a receiver needing to be manually switched between the modes or even they only operate one mode at a time by a cable being inserted into one or other socket. This is not going to work with a Bluetooth Headset (note we need to use a Headset, not Headphones – a Headset is Headphones with a microphone). The Bluetooth electronics in Smartphones have this “duplex” capability but to find an external adapter with the same capabilities is not easy. Investigation showed that “aptX” support can supply what is required to handle audio going to and coming from the headset at the same time but even an adapter that says it has aptX (often one that also has NFC) isn’t always one that will handle two-way audio! The alternative using two BT adapters, one running as TX and the other as Rx path, will not work as the headset is designed for use with a smartphone and hence a single (duplex) channel.
The audio connections (ought) to be the simpler part of this project – it seems not to be the case!
I gave up looking at the direct adapter solution when I saw that an audio plus PTT solution is already available for HTs. These kits include adapter, earphone/headset and PTT button are not cheap, so shop around but make sure you are buying the complete kit and not just the earphone at the advertised price, which is not always clear!
The ideal would be just to buy the “HB-6A” adapter in the middle of the picture above and I did eventually find one company selling just that at $25 plus P&P after I had ordered a complete kit. Prices for the same kit can vary from €29 to €90! The headset alone costs €13.95. Shop around and the “kit price” from several AliExpress and eBay sellers is around €40 including tax and shipping. Of course, if you don’t already have a Bluetooth headset that you wish to use, then the one in the kit might be fine as it’s supplied to use with the adapter in a communications mode. I already had an over the ears BT headset, so now I have both Headset and earpiece/microphone.
After wiring this set via 2.5mm and 3.5mm stereo jacks to the ACC socket mini-DIN plug, pairing the headset to the unit and testing, I found two problems.
I had no audio coming out to by Bluetooth headset or earphone. This was simply solved by switching the output from the Internal speaker in the G90 to the ACC socket in the system menu. This is reached by pressing the <FUNC> button once so that the orange light comes on and then the <POW> button on the right-hand side of the radio, twice and then using the main tuning knob to change the setting from SPKR to LINE. You can also access the levels of the line input and output in these menus and I suggest you set both of these to their top value of 15.
Then the microphone level was far too low. As I have wired to the ACC socket – it expects computer level (1v peak-to-peak) audio, whereas the HT, where this BT adapter would normally connect to, would be expecting electret microphone level audio. Now I could wire up an inline RJ45 connector and feed the audio into the microphone socket of the G90 but I decided rather than doing that I would add a small €3 LM386 amplifier module that is normally used with Arduino projects.
This has the advantage of having a volume control, so I can set the audio input level correctly.
The first test of this modified set-up was fine up to about 3 watts but after then there was constant output indicated even when I wasn’t talking – RF Ingress! So I added a parallel pair of a 0.1 (104) and 0.01 (103) µF ceramic capacitors across the input and output of this pre-amp module and a 0.1 (104) µF capacitor directly on the mic connector on the 3.5mm jack socket, to the ground (earth) connection on the 2.5mm jack socket and with my next test… No RF Ingress – all levels were quiet until I spoke then the output meter indicated full scale on 20 watts. I suspect I will need to back the gain off a little now H.I.
A total surprise was that after pairing the little PTT button that also came with the audio adapter set, it worked straight away with no issues at all, meaning I can use this rather than the PTT option in the remote-control app (more about that app below).
To avoid always having to unplug the module to charge its internal battery via a micro-USB cable, I added a regulator board designed for the Raspberry Pi to take the 8 or 9v coming from the G90 ACC socket down to 5v for the mini-USB socket so that the Bluetooth audio module is constantly being trickle charged while in use. This supply also has a spare micro-USB plug to charge the PTT button unit when needed.
CAT Control via BT.
The second part of the solution is to get CAT (Computer Aided Transceiver) remote control commands over a Bluetooth serial connection to the radio from the remote device.
Only by having a separate “remote control console” with the Bluetooth headset can the G90 radio be operated fully “cordless”.
The remote device and software to do the control work is not discussed in this article. You may have your own choices but my choice is to use an Android Smart Phone and the PocketRxTx software ($5/5 Euro/5 pound for the full version – https://play.google.com/store/apps/details?id=ro.yo3ggx.rxtxpro ). The software handles the CAT side of this project. In addition, the phone itself could also handle the BT Audio but I prefer to use a BT headset.
Background – ICOM has used a 3.5mm jack for their CiV CAT connections on their rigs for some time. Xiegu on models other than the X108G (which uses a micro-USB port) has also adopted the 3.5mm stereo jack along with a subset of the ICOM CiV command set for remote control of the radio. There is one important difference, however – the ICOM radios although fitted with a stereo jack, have Tx and Rx on the tip of the plug shorted together and don’t need a connection to the ring. The case is earth. Xiegu keeps Tx and Rx signals separate and uses therefore all three connections.
There are already BT comms adapters that plug into the ICOM rigs on the market and cost around 15 Euros from China.
Figure 1 Here is one example of the BT adapter for ICOM radios available over eBay.
These dongles however are wired for the ICOM configuration of running TxD and RxD on a common line and are pre-set to 9600 Baud (whereas the G90 needs separate TxD and RxD lines at 19200 Baud) The DIN plug (which supplies 8v DC will not fit the G90). So, we will need to make some changes. As this CAT command BT module will need to take its external power supply from the 9v DC supply from the G90 ACC Mini-DIN port.
IC-718 / 7000 accessory socket – standard 8 Pin DIN – this is what the dongle comes wired for.
The XIEGU G-90 accessory socket is an 8 pin MINI-DIN
This ACC socket has DC supply, PTT switching, audio in and out all of which we need to use.
Here’s a picture of the eBay dongle opened up: It’s a PC board module (known as an HC-05) soldered onto another board that has a voltage regulator on it. If you look on the left-hand side you will see that two connections are bridged together with solder;
Figure 2 The dongle opened up | Figure 3 HC05 BT module diagram
Using the graphic for the HC-05 module and tracing the lines back, it is clear these are the Rx and Tx data input lines which both go to the 3.5mm plug, so this bridge needs to be removed so that we have TxD and RxD separate as supplied and needed by the G90.
As the voltage is regulated down to 3.3v by the carrier board, a supply of 5-9v DC is fine to power the dongle. Of course, I had to remove the full-sized DIN plug from the lead and fit a suitable mini-DIN plug and wire to the available supply pin from the G90s accessory socket. Later for the combined BT CAT and BT audio solution, the audio in and out wires was also connected through to the mini-DIN plug.
All good so far – now comes the tricky part. The G90’s serial port ONLY works at 19200 bps, so the module needs to be re-programmed from 9600 to 19200 bps before it will work. For this, you will need another small par-dollar interface board and some free software to do the speed programming change. Full details can be found on pages 4 & 5 of this document:
https://www.yo3ggx.ro/btcat/FT8x7_DIY_Bluetootth_CAT_interface_v1.pdf Credit: Dan Toma YO3GGX.
After updating the serial speed of the dongle, I was able to control several useful functions of the G90 radio from the PocketRxTx App running on my Android phone.
The final combined design using modules for adding Bluetooth Audio and CAT connectivity to the XIEGU G90 and possibly other radios.
In line with using modules, as the Handy Talkie, BT audio unit runs from an internal battery that has to be regularly charged up and the BT-Cat module needs to be powered, we need to supply their required DC voltages. While the BT-CAT module is happy with the 8/9v that the G90 can supply over its ACC socket – the Audio interface only expects 5v onto its micro-USB charging port.
In theory, a very simple solution might be to insert a resistor from the G90’s 9v DC supply however as the load will change depending upon how charged or uncharged the internal battery is, it’s best to use a proper regulator.
Looking around I found the small board below, that is used to power a Raspberry Pi with 5v to its USB connector, so this should suit our needs quite well. The charging cable supplied with the HT-BT audio unit has one USB-A connector and two micro-USB connectors so one will be connected permanently to the HT-BT unit and the other I will leave available and accessible to charge whichever Bluetooth headset is in use or the PTT button.
This board or a similar one should be available from stores that supply parts for the Raspberry Pi and microcontroller kits. I got mine from Reichelt.de -
Here is the connection overview.
Picture of the box during construction.
Picture of the completed interface unit in “all its glory”!
The cable with the mini-DIN plug from this box plugs into the ACC socket on the rear of the G90 and the stereo 3.5mm jack into the data socket on the side of the head unit.
Note: do not plug the data connection in until the radio is operating as otherwise, the presence of a cable in this socket can cause the radio to think it is in the middle of a firmware upgrade and to set it back into normal operation can be difficult should this occur.
When starting the use of the Bluetooth adapters, the HT module needs to be turned on by a long press on its button – this is inconvenient as it means the clear plastic box has to be opened. Once devices have been paired to the HT-BT unit once however they automatically pair again when they are turned on. (for the first time pairing procedure, refer to the HT BT-adapter documentation that it is supplied with (a magnifying glass may be needed).
The intention of building everything into the clear plastic box was always going to be a temporary solution. The use of the 2.5 & 3.5mm sockets on the HT-BT unit and its need to be turned on manually every time it is needed are two non-ideal situations. In a hope to resolve this into a better final solution, I have ordered an inline cable connector that has the stereo sockets in the correct spacing for the HT-BT unit and I have decided not to trickle change the BT-HT unit but rather have it accessible in an elongated cable harness with plus one end into the ACC socket and the other into the G90s data-port so that adding Bluetooth to the G-90 will then be the addition of just one cable with a small box in its middle housing the audio pre-amp and the BT serial board.
The main thing is that the solution has been proven here – it is possible to add Bluetooth support externally to a Xiegu G90 using easily available modules and without any changes to the radio being needed.
73 Ed DD5LP.
Hi radioddity.com administrator, Your posts are always well written and informative.