Arduino Walkie Talkie

1,010

12

The long wait is over, Tri-band Ham Radio Handheld Transceiver is here!

  • Arduino Pro Mini based 430/220/144 MHz 2 Watts, fully customizable, programmable with these features:
  • 2 watts output in high, midden and low;
  • 70 cm band, 1.25 m band and 2 m band transmitting;
  • 130MHz to 520MHz receiving;
  • CTCSS and DCS Squelch control for both simplex and repeater operation;
  • 40 fully programmable scannable channels with EEPROM protection;
  • fully Bluetooth and USB controlled;
  • short message SMS mode included and can be extended to data communication;
  • OLED 1.25-inch display screen, an additional 6 colorful LED for status displaying;
  • 4 push buttons and one rotary encoder as channel selection and function control
  • Other transceiver features in detail:
  • sensitivity -122dBm, vox 8 level, SQL 9 level, 8 secure sound scramble mode ...

The most important is, all functions are controlled by an Arduino Sketch which included with this instructable!

Supplies:

Step 1: First Things First

  • You need a ham radio license for in Amateur Radio Bands TRANSMITTING.
  • Please contact your local radio club for the direction on special data transmitting and scrambled sound transmitting as in most country and areas, they are all prohibited.
  • You need special business licenses for all transmission outside Amateur Radio Bands.
  • You can NOT transmit without harmonic low pass filters on ANY frequency.
  • Please conduct your local FCC office for any related questions.
  • The author, me as KM6WZM is not responsible for any consequences related to your illegal transmitting.
  • The Arduino sketch (software) attached is under MIT License.

Step 2: The Parts Which You Will Need for This Instructable:

The parts which you need for this instructable are all shown here. I am to explain each of them on every single step when we are dealing with them. ALL information e.g. PDF documents, schematics are included in this Instructable and where will be NO external links.

Please just login to your account and download the instructable, everything is there. You may leave your email address in the comment section and I am to update the sketch (the latest software version is v2.12 when I am to click the big Publish button) by group email sending frequently.

Please like and vote this instructable if you are interested in this project, thank you!

Step 3: All Tools for This Project.

Believe me, you need NOT any expensive RF equipment on finishing this project although it is a U/V band one. It would be helpful if you have SWR meter, frequency counter, CTCSS analyzer or spectrum analyzer on hand. I am to discuss with few of them in the "further thoughts steps".

Step 4: Download the Sketch and Experiencing the Walkie Talkie

Although this instructable is looked long, it is very simple. you may experience the functions and user interface in just a few minutes with your current Arduino system, e.g. Arduino Uno and Arduino Nano.

Please download the attached sketch, add OLED, rotary sensor module and a few buttons according to the schematic.

Attention, the push button SW7 is for simulating that RF module received a signal.

Step 5: Additional Readings, You Can Skip It

The Rotary Sensor is actually a kind of pulse signal generator, when you turn the knob, the rotating conductive tooth will make A and B switches connected then opened repeatedly. With the help of pull up resistors, pulse signal (active LOW) will be sent to digital pin 2 (D2) and pin 3 (D3) of your Arduino board. The C is just a simple push button, besides of rotation push down the knob will switching between scanning mode or make a selection on setting mode.

There are many kinds of rotary sensors there. We are to use RE111M for our PCB on version v2.12.

To make our Arduino Walkie Talkie as slim as possible, we will change to tiny SMD package on version v2.16 in the future with Mitsumi's SIQ02FVS3.

Step 6: After the Experience, You Can Make the Decision.

The ATMEGA328P equipped with 1K (1024 bytes) EEPROM, you can save up to 40 channels with transmit frequency, receive frequency, name, CTCSS and other settings. You have to modify the sketch if your MCU is ATMEGA168.

Before compiling and running the sketch for the first time. please be sure to turn on these two lines from the setup section for your fresh ATMEGA328P or better MCU, that will push in all demo channels and settings.

//only run ONCE at the very first time when you are programming your fresh Arduino board!

testWriteSettings(); //push in default settings into EEPROM

testWriteChannels(); //push in 40 demo channels into EEPROM + control channel 0

Ok, here comes the full schematic, will you continue?

Step 7: Please Double Confirm With Your OLED Screen.

There are many 128x64 OLED screens in this 1.25-inch to 1.3-inch size on the market, please confirm the model before purchase. In order to limit the resource that OLED screen library using, we have to choose the "lighter one", the one with cheap SH1106 driver chip onboard.

Normally they have the display color in white, blue and blue with top few lines in yellow, you can choose any color as you prefer as long as they are using the SH1106 chip inside, this is a MUST!

I bought these two modules from Amazon and they are all capable of this project. Please be careful with the different pinout.

Every Arduino player knows that a stable and extendable system is more important. The v2.12 version of Arduino Walkie Talkie only consume 80% of the flash storage and 31% of the memory, thanks to the slimming libraries form these created coders:

  • Matthias Hertel's library "RotaryEncoder"
  • Bill Greiman's library "SSD1306Ascii"
  • James Sleeman's library "MCP41_Simple"

Step 8: Additional Readings, You Can Skip It

Arduino Uno and Arduino Nano are not selected in this project because 1) the RF module and Bluetooth module we are using are all 3.3v powered; 2) We would like to design a PCB and aim to make the walkie talkie in the size of a credit card; 3) Converting the output voltage of a single lithium-ion battery to 5v will increase the power consumption of the whole device.

The cheapest selection should be Arduino Pro Mini 3.3v, although we have to accept the 8MHz MCU clock frequency as a compromise.

According to my test, the ATMEGA328P performance good even on scanning mode nearby the protection cut-off voltage of the lithium-ion battery.

This is the schematic of the Arduino Pro Mini which I am using, the photo of the board and the pinout diagram in detail. Please double confirm that you are purchasing the 8MHz 3.3v board with LOWER power consumption onboard MCU ATMEGA328P instead of ATMEGA328.

Step 9: Let's Deal With the Audio

Please stop thinking of the LM386. Yes, it was a miracle but not in the modem age. We are to get rid of the liner audio amplifier and the potentiometer which our Arduino cannot control. You may notice there are fewer capacitors than in analog design from the schematic. The sound output is tremendous clean and clear.

MCP41010 is a very popular 256 steps digital potentiometer controlled via SPI interface, reliable and inexpensive. We are using a slim SPI library from James Sleeman to control it.

NS8002 is a popular 3W mono class AB audio amplifier chip from Chinese company NSIWAY. It is sold cheaply on eBay as a tiny module and should be considered as a generic copy of Texas Instruments's LM4871. The fast response shutdown/sleep pin is an important consideration for a walkie talkie project especially we are dealing with an RF module which equipped with STE (Squelch Tail Elimination) function.

The PDF document of NS8002 is in Simplified Chinese, you can download the attachment of LM4871 instead.

Attentions:

  • The pull up 10k - 100k resistor on pin one is necessary.
  • Do NOT connect any speaker pin to ground as there are neither output coupling nor bootstrap capacitors there.

Step 10: Additional Readings, You Can Skip It

The step numbers of MCP41010 is 256, but we simply multiples 8 and use it as a 32 step digital potentiometer.

Yes, there are plenty of possibilities in the future for us to get improved sound performances.

1) As your ears are not linearly responding to sound pressure levels, we are to make the potentiometer works in logarithmic mode.

2) As the tiny speaker is not that carefully designed as an iPhone sound transducer, we have to lower the driven power while potentiometer is around the louder position. (I really hope someone can find a solution on using tiny phone speaker for this project, let's discuss this topic on the comment section.)

We really need experts to balance this situation, two research papers are attached if you want to dig into it.

My current compromise is a 20k resistor in parallel to the output pin of the potentiometer.

My selection of tiny speakers was lead to these results:

  • The boxed is better because they are from laptop computers and they are somewhat designed as a unit.
  • The bigger in size and the lower impedance the better as the amplifier chip can accept as low as 2 to 3 ohms.

update 05/14 - I grabbed this speaker from my old Samsung today, it is 8 ohms and not loud enough... If you know which one is better, please let me know.

Step 11: The Battery and Battery Charger Module.

A single cell Li or Li-ion battery is capable of this project. You can choose anyone on hands. From the schematic, you can find the charging module is using the basic design of the chip. TP4056 is a 1A Standalone Linear Li-ion Battery Charger with Thermal and the TC4056 is a generic copy of it.

The maxim charging current is set by the 1.2k resistor on pin 2. The 1A current is not harmful to the 3000mAh Li-ion battery which I selected and benefits from the SOIC-8_EP_150MIL package, the chip has never run in hot. You can change it accordingly to meet your situation.

Personally I never play with Li or Li-ion battery which does NOT have protection board integrated because I consider them as monsters. An outside DIY protection board which NOT integrated inside the battery would trouble you sooner or later. Those module board with four pins are an alternative solution for 18650 batteries, as the chip cannot sense the temperature of the battery, the protection function is very limited. Please don't use this kind of charging module and a naked Li cell in this project.

Step 12: RF Module, the Heart of the Walkie Talkie.

There are many parts named as RF module in the market but most of them are not capable of building a walkie talkie! There is a quicky on finding one, please search CTCSS or DCS as keywords. These analog and digital squelch system would make those RF modules build for wireless voice communications stand out.

If an RF module is with CTCSS and DCS build in, changing it into a walkie talkie would be a piece of cake. The second consideration is the working band if that module can be forced working on ham radio amateur band, twin band or even tri-band, congratulations!

I found two Chinese company are selling these kinds of RF modules:

  • NiceRF(www.nicerf.com) with 7 modules SA818, SA828, SA858, SA868 and DMR818, DMR828, DMR858
  • Sunrise(www.sunrisedigit.com)with 4 modules: SR_FRS_1WU, SR_FRS_1WV, SR_FRS_2WU and SR_FRS_2WUS

What I am using on this project is the SR_FRS_2WUS, here comes the simple pinout picture and PDF document including supported AT commands. Unfortunately, all documentation is in simplified Chinese. I have translated the pinout diagram and done my best on making comments in the sketch, please ask me if you need more translations.

The SR_FRS_2WUS is recommended to work on 400MHz to 470MHz but benefit from the central chip it using, the AT1846S (RDA1846), we can force it to cover the 2m, and the 1.25m band also. (according to the datasheet of AT1846S, the frequency range are as follow, see attached PDF files in step 14 for detail.)

  • 134MHz-174MHz
  • 200MHz-260MHz
  • 400MHz-520MHz

All pinout is very simple to understand except pin 6 and pin 11. The pin 6 is for hardware output power control but I have never made it work. I was told by the technician when I was asking for support, the function is suspended in the current firmware version and we can only control the output power by AT group command now. The pin 11 should be an output while VOX is activating, but I didn't make it work also. Actually, I'd really prefer a LED light up while VOX is on and I am in transmitting. The VOX can be active by at command and works very well.

The pin17 out is powering my microphone and the MCP41010 now, it makes audio away of digital noise generated from MCU, compares with connecting them to the VCC of our Arduino Pro Mini.

Step 13: Mounting and Soldering, Heatsink?

The RF module is a surface mount one with standard 2.54mm pin size. Self-adhesive copper tape, header pins, and double-sided prototype board is the best way to evaluate.

The heatsink is necessary for daily use. I test it at the 70cm band with 1-minute transmit 1-minute receive cycle and the center of the RF module is still touchable. But an accidental automatic VOX transmitting at approximate 5 minutes (that's the bad side of no transmitting indicator) bring the whole module very hot! I assuming it would be burned out if those header pins and copy tape are not there...

According to the soldering sheet from competitor company's SA818 (I attached the PDF here also), we should use reflow soldering to solder these modules at a peak temperature of 245-250 degrees centigrade. It would be a challenge to solder a copper heatsink directly to the center golden pad. As I have designed PCB and it is already on the way coming, I will not take the risk soldering heatsink the in this evaluation mode.

Step 14: Additional Readings, You Can Skip It

Is it possible overriding the inside MCU? Maybe yes, the SPI interface was pined out from both testing pad and pin 1, pin 2. You can monitor the SPI traffic by another Arduino because as what I described before, the SPI was occupied by a slim digital potentiometer control. The PDF document of TA1846S (RDA1846) and programming manual is attached, hope it helps. BTW, "phishman" had done some related research 4 years ago, you can read it from GitHub, that was attached as a zip file too.

Let's take some time discussing the onboard CTCSS and CDS coding. This module uses a special AT command group on transmitting the squelch settings.

Say your repeater's PL is ZA, which is 94.8Hz, ( that's my nearby WA6DVG located on Mt. Wilson receiving 224.940MHz / transmitting 223.340MHz ) you should multiply the CTCSS by 10 into a maxim 4 digits integer, 94.8Hz * 10 = 948, if the integer is less than 1000, add zero in front of it then cut it to two single bytes, the "09" and "48". After that, send that two bytes reversed in HEX mode to the RF module, the 0x30 0x09. I don't know why the coder prefers this way, there must be a reason. (see my sketch for detail)

Personally, I didn't test the CDS function in my sketch because I cannot find a local repeater to test and use it although I have my Baofeng on hand and can test it with simplex. If you are to use the CDS squelch, the coder explained the conversion process in the PDF like this: set MSB to 8 for position D1, e.g D023N, D0 D1=23 80; set MSB to C for negative D1. A blog explained the difference between analog squelch and digital one in simple words, I attached it as PDF for your reference also.

Step 15: Do NOT Transmit Until You Have LPF Installed.

Please transmit responsively. The best choice is a bandpass filter and you should at least use a lowpass filter to reduce the harmonic interferences.

The 50 ohms dummy load is a friend of both you and your RF module. Please keep a dummy load connected to the antenna port at any time.

On considering a lowpass filter, the first stuff jumped in my mind are those 433MHz LPF modules sold on eBay, be sure to select one which is capable of handling over 2 watts. A lot of them are designed for measure instrument, receivers and marked with dBm, 2 w equals 33dBm.

This kind of 7 sections LPF works very well with this project, according to my test, there is no further performance improvement while integrated on board and shielded with copper type. If you are query the value of the LC, here is a diagram of similar design.

I assume the RF module is designed without specific LC resonant components, you'd better use good antennas. The dual-band Diamond SRH77CA and the tri-band Comet HT-224 both work very well upon my test.

Step 16: The Final Choice of LPF, a Tiny 8.5w, 7 Sections

In order to reduce the PCB size of LPF, I've done some research on surface mount inductors. I've to say they are actually expensive, expensive and performance not guaranteed unless you choose suppliers who preset your request with kits.

Finally, the LTCC filter pops up, LTCC is an abbreviation of Low-Temperature Co-fired Ceramics... Simply to say, single layer coil and capacitors are silver printed on thin layers of ceramic and then be carefully stacked, layer connected into inductors capacitor network... And the truth is they are only 3.2mm x 1.8mm,7 sections LPF but can accept 8.5 watts of RF power!

Evaluating this kind of parts is really a challenge of hand soldering. Luckily there are only 3 pins: in, out and ground, you would better circle around a wire on its waist in order to connect the ground pin on BOTH sides. According to the PDF file, the head pins are declared as input and output. I emailed my concern to a technician and was told they are actually identical. But I'd prefer to leave the input to antenna expecting better receiving sensitivity.

BTW, the LFCG-530+ should work fine as it is 4 w declared but it is in a smaller size of 0805, maybe later test with my coming PCB.

You can request FREE samples of these LPF directly from www.minicircuits.com. You are probably can request 4 of each of them no matter which country you are in.

Step 17: The Bluetooth Module, the Transparent Serial Bluetooth.

There are many choices of Bluetooth module on the market, the most popular is called HC series. Please consider them by these two rules, 1) they are called BLE - the Bluetooth Low Energy, it is Bluetooth 3.0 or 4.0 and works by simulating a UART device beneath the surface, that's why we call it transparent Bluetooth serial; 2) they can work on the 3.3v system.

What I am using is JDY-31 and it is claimed more compatible and to be survived on the market for more years.

The PDF document is in simplified Chinese, but very simple to understand with diagrams and AT command only.

Let's describe the functions in one sentence when the module is not connected to other master devices, you can set it up from any terminal app, the name, the baud rate, the password, etc. When it is already connected, just consider it as a transparent serial cable, use your master device keep talking to your slave device.

I collected all setting AT commands from my MacBook Pro and made a screenshot of the AT command list for you.

The serial monitor of your Arduino IDE is a perfect terminal app too, you can monitor all communications between all devices there.

Step 18: The USB to TTL Serial Adapter Board

We've chosen the Arduino Pro Mini, that means there is no onboard USB and we have to find a breakout board to make programming and debugging easy although we can set up our walkie talkie var Bluetooth.

There are tons of adapter boards which claimed Arduino compatible, but for the programming of Arduino Pro Mini, you have to choose the one equipped with DTR(Data Terminal Ready) pin. Believe me, this is a must, although it is said that the RTS is the original reset triggering pin and reset pulse will be sent to both RTS and DTR pins, etc. Please select a USB to TTL serial (UART) adapter board with DTR pin soldered already.

FTDI Basic is what I selected because it not only equip with DTR pin but also follows those 6 pinout positions of Arduino Pro Mini.

The document for FT232R chip and breakout board diagram also attached for you.

Step 19: Can USB Serial and Bluetooth Work Together?

Yes, as long as we do like this: 1) unplug the USB cable from your computer when not in use; 2) do not share 3.3v VCC from breakout board to Arduino Pro Mini (4 wire mode instead of 6); 3) only switch on 3.3v power when in Bluetooth mode (including both Bluetooth Setting Mode and Short Message mode)

Under this condition, you can connect RXI from breakout board and Bluetooth board together to Arduino's TXO pin, and so do the TXO pins from those board to Arduino's RXI pin.

Step 20: How to Change Settings of the Walkie Talkie?

All settings and channels can be set via USB cable or the Bluetooth. An Android phone is the best device to pair and control your walkie talkie at any time.

Please download a serial terminal app from the app store, I recommend this free one, Serial Bluetooth Terminal by Kai Morich. Please config it from settings as what I marked. Open your phone's Bluetooth setting and turn on searching, there will be a device named "ARO_Walkie_Talkie" (assume you changed the name as what I described from step 17) or "JDY-31-V1.2, Bluetooth V3.0" (if you haven't change the broadcasting name), then 1234 as password.

Please read the sketch on understanding those AT commands. I will code a specific app for fast and easy settings when I have time in the future.

Step 21: What Can I Do With the SMS Mode?

Yes, you can send and receive a short text message to and from each other on this Arduino Walkie Talkie!

The only limitation is the SMS should be within 60 characters each time. Actually, I even do NOT know what modulation it is using, but the SMS is really sent out and can be relaied by SOME repeaters.

Here comes the screenshot of the spectrum which I recorded from my SDR receiver (the Software Defined Radio). I don't think it is a simple FSK modulation, but I can identify the different characters (maybe I was sending 12345678 at that time).

I hope some experts can read them out and benefit more from it. The reason why not all my local repeater can relay it is maybe that there is no CTCSS signal attached while the SMS was sent, I guess.

By the way, the document of the RF module declared, please do not press the PTT button while sending a short message, it will involve a mistake in the SMS.

Step 22: Additional Readings, You Can Skip It

Are expensive tool and measure instruments helpful to this project? Just like what said before, not really. Besides basic tools, I added a cheap ($40) VHF/UHF SWR power meter to confirm the status of the RF module.

While with 50-ohm dummy load used, I can confirm different RF output on all three bands, the readout varies from 1.8w to 2.5w, of cause with an SWR of 1.00 on the dummy load. I also got a 0.0w readout while testing the 507.7500MHz with a dummy load, that's why I keep that frequency as demo channel 21 for you to test and confirm. (the receiving of this frequency is quite good, it is one of our local LAPD channels)

Switching between good HT antennas, I have readouts of SWR from 1.05 to over 3.0. Compare with manufactured transceivers, I am very happy with these readings. Yes, the 433MHz short antenna should not be used on the 2m and 1.25m band, the power supply current would jumping from average 1.3A to 2.5A and really scared me. Talking about power supply current, I added a 5A adjustable power supply which equipped with both output voltage and current monitoring. It is very helpful in analyzing efficiency.

And, the SDR receiver is also helpful during the time that I was testing the RF module with outside band frequencies. It helped me realize what I've received is not harmonic.

Step 23: Additional Readings, You Can Skip It

Are you building a tri-band walkie talkie with only one LPF?

Yes, right now. I understand your concern and am designing the switchable LPF network right now. Here comes the full schematic which I did before the decision of moving to LTCC filter. You would find out that I was planned to use the pin diode as RF switch, the disadvantage is, it works on high current mode (compare with other parts) while switched on. I am to move to modern RF switch IC to finish my design later.

Talking about band LPF switching there is another shortage, I am running out input/output pins of Arduino Pro Mini. According to the current version of sketch (v2.12), all pins are used except the A6, but it can be used as analog INPUT only, I am to reserve it for "one wire keypad" although I don't think keypad is necessary for this project.

There will be two ways to save another pin for band LPF control, either the squelch button or the SPI pin D12 will be considered.

Please let me know which approach you prefer, cancel the squelch button, move monitor (squelch zero) function to the long press of back key; or we can move on and modify the system SPI library and make the D12 released from SPI library. (our slim SPI library doesn't rely on D12)

Please leave your feedback in the comment section, thank you!

Step 24: It's Too Long! What's Your Next Step?

Sorry for that, I just want to let you know building a tri-band walkie talkie is not that difficult. Everything you need is here, just download it with one click.

If you have questions, please make sure 1) you have read all steps, including those skippable; 2) you have downloaded and carefully read the sketch

Please be sure to ask your new question from a new line instead of hidden behind those replies.

Please leave your email in the comment section and I will let you know when a newer version of the sketch is releasing.

BTW, I've designed a tiny PCB for version v2.12 and it will be in my mailbox in a few days... I will keep you informed.

Again, thank you for reading this instructable in all.

You are the one who deserved to make an Arduino Walkie Talkie!

Arduino Contest 2019

This is an entry in the
Arduino Contest 2019

Share

    Recommendations

    • Woodworking Contest

      Woodworking Contest
    • Party Challenge

      Party Challenge
    • Fandom Contest

      Fandom Contest

    Discussions