Avatar
ARDUINO RADIO CHAT
Sep 23rd, 2019 | by: ELECTRONOOBS | Views 802
Views 802
Remember the keyboard PCB we've made in this past tutorial? Well now I'll give a use to this PCB. We will make a radio based chat that will work just as a walkie talkie but with text instead of voice. So, for text, we need a keyboard and this PCB is perfect for this project. I'll make two modules so we could test the radio chat and simulate a conversation. Each module will have a 3D printed case with rechargable battrery and BMS, buzzer, radio module and the keyboard.
PART 1 - What we need

Have in mind that for each part below, we need it two times in order to make two radio chat modules and test the connection. See full part list for all the components. But we need the 3D printed case to place everything inside it so download the STL files and print it. Then go to the past tutorial and get the GERBERs for the keyboard PCB and make it. We need an Arduino NANO, an OLED display, the battery with a small USB charger and the radio module. I'm using the CC1101 radio module. Extra, we need a buzzer and a sliding switch.

 

We need:

Parts we need
PART 2 - Schematic

See the schematic below. Once you have the keyboard made, the rest is very easy. Just make the connections as below. Just be careful, upload the code from below before you connect the Tx and Rx wires from the keyboard. Otherwise the code won't upload. Connect the battery to the charger and the charger output to the sliding swith and that to 5V that will power everyting. The Radio module will be connected at 3.3V.

Schemaic
PART 3.1 - Mount it all

First we make the power part. We solder the battery to the small charging module with USB input. Then, we soler wires to the output of the module and the negative wire goes to Arduino ground and the positive to one pin of the sliding switch. Then from the switch, we connect a red wire to the 5V pin of the Arduino. Now the circuit has power.

Connect the charger
PART 3.2

Ok, now we connect all the wires from all modules except the keyboard. Before we connect that, go below, and downlaod the code and uplad it to the Arduino and then you could connect the keyboard Rx and Tx pins. Now, slide the switch and test if it works. If yes, we could now place all the parts inside the 3D printed case.

Test the circuit
PART 3.3

Get the 3D printed case and some brass threads inserts. Heat the soldering ion and push the thread inside the holes. Now we could use screws. First thing I do is to glue in place the OLED dsiplay on the fron part of the case and also screw in place the keyboard with some 3mm plastic screws.

The case
PART 3.4

Glue everything inside the case. Pass the antenna through the hole and glue that in place as well. make sure the charging module is in front of the charging hole and that the USB can fit ok. Glue the sliding switch to the side and now we could close the case. Use some 3mm screws for that.

Final case



PART 4 - Code

Below you have the code for the radio chat module. The code is the same for both transmitter and receiver. So, just download it from below and upload it to both Arduinos and then we could make a test and see if it works and we could caht between the modules. But you will need some libraries as well. On th link below you will find those as well for the CC1101 radio module and the OLED display. So download those and install them to the Arduino IDE. Then, uplaod the code.


#include <ELECHOUSE_CC1101.h>     //Download it here: http://electronoobs.com/eng_arduino_ELECHOUSE_CC1101.php
#include <SPI.h>
#include <Adafruit_GFX.h>         //download here: https://www.electronoobs.com/eng_arduino_Adafruit_GFX.php
#include <Adafruit_SSD1306.h>     //downlaod here: https://www.electronoobs.com/eng_arduino_Adafruit_SSD1306.php
#define OLED_RESET 5
Adafruit_SSD1306 display(OLED_RESET);
int buzz = 3;
.
.
.


PART 5 - Test

In the video below we have the test and as you can see we could send 60 characters and receive the same amount. The top part of the screen is for the sneder and the bottom half of the display is for the received text. You could also set the name first so all other users could know who you are so you could use this with multiple users.

PART 6 - Tutorial video

See the tutorial video below for more information. I hope you like this tutorial and maybe support my work on PATREON. Thank you!

3 Comments

  • Chris

    about 2 years ago

    Such a great project! So much so that I'm going to build it as well :-) Question - you mentioned you had a mistake on the keyboard gerber files - missing symbols ?,%, etc., do you have a corrected gerber file that can be downloaded ? Chris

    ELECTRONOOBS

    about 2 years ago

    Just downlaod the GERBER from this tutorial That is the correct one

  • Chris

    about 2 years ago

    Got it, thank you

Login or Sign Up to post comments on this tutorial.