Star Trek Communicator Badge

In the true spirit of Star Trek, this communicator badge is completely autonomous, while fitting in the form factor of an original badge

Similar projects worth following
Star Trek was known for dreaming up technology that was deemed nearly impossible given the limitations of the technology for the day. Having a small badge that could send audio across vast distances seemed out of the realm of possibility during the late 1980's. This project's aim is to use modern technology to provide nearly all the features of visionary tech, namely:

- Tap to connect and communicate instantly
- Long range (from orbit to planet surface)
- Small form factor (of an original TNG badge)
- Fully autonomous (no cell phone or base station needed)
- No external power source (i.e. battery powered)

Wireless Transceiver Design Decision Details

A similar project to this could easily be done with a bluetooth audio chipset much like the ones we see in wireless handsfree modules. The problem with those modules is that they don't meet any of the requirements of THIS project. First, they rely on a connection to a cell phone for communication, this would not make the system autonomous. Second, the range of bluetooth audio is very limited, making it impractical to use without being paired to a cell phone.

Therefore, I was tasked with finding a wireless communications system that had:

  1. Small form factor
  2. Low power
  3. Fast enough data-rate to send audio
  4. Long range
  5. Multi-node communications protocol

From this point, I believe I have found this in the RFM69HCW ISM band transceiver. This module meets all the requirements:

  1. Smaller than a US quarter
  2. Low power: Rx = 16 mA, 100nA register retention
  3. FSK Bit rates up to 300 kb/s (fast enough for 8-bit audio with 16kHz bandwidth)
  4. It has been used to communicate from space to ground (
  5. It supports up to unique 255 node IDs

There may be better modules that come available in the future so it is desirable to design a system that can easily scale to use any TX module with minor software and board changes. Therefore, I have decided to base this design on a Teensy micro-controller.

Beta version of communicator code with two unique nodes. streaming library now inherits original lowPowerLab library.

Zip Archive - 53.08 kB - 03/28/2017 at 00:53



Power switch now controls enable pin of regulator so switch is not in power path.

sch - 292.67 kB - 03/26/2017 at 22:54

See BOM Download


Power switch now controls enable pin of regulator so switch is not in power path.

brd - 150.95 kB - 03/26/2017 at 22:54


Code used in demo video. Tested and working with 915MHz Radio

Zip Archive - 12.07 kB - 03/13/2017 at 02:01


RFM69 Library from Low Power Lab, modified to allow audio streaming.

x-zip-compressed - 199.73 kB - 03/06/2017 at 16:49



New board with power switch and tap detector interrupt on deep-sleep enabled pin

sch - 291.75 kB - 03/01/2017 at 05:57

See BOM Download


New board with power switch and tap detector interrupt on deep-sleep enabled pin

brd - 141.56 kB - 03/01/2017 at 05:56



Arduino test code for each sub-system , mic, speaker, accelerometer.

Zip Archive - 19.58 kB - 02/27/2017 at 04:25



Chirp sound that is played when communication is initiated

Waveform Audio File Format (WAV) - 9.81 kB - 02/27/2017 at 04:00


Arduino demo code that puts one Teensy LC in Audio Transmit mode and another in Audio Receive mode.

Zip Archive - 224.88 kB - 02/21/2017 at 02:53


View all 16 files

  • 1 × 0915AT43A0026E (915 MHZ antenna) Electronic Components / Misc. Electronic Components
  • 1 × TSX-3225 16.0000MF09Z-AC0 Frequency Control / Crystals
  • 1 × KXT 131 LHS Electronic Components / Tactile Switch
  • 1 × SPU0414HR5H-SB Electronic Components / Misc. Electronic Components
  • 1 × TPA2006D1DRBR Audio ICs / Audio Amplifiers
  • 1 × PSR1511N08S3K Electronic Components / Micro Speaker
  • 1 × 10118192-0001LF Connectors and Accessories / Telecom and Datacom (Modular) Connectors
  • 1 × LIS3DHTR Semiconductors and Integrated Circuits / Misc. Semiconductors and Integrated Circuits
  • 1 × LM3671MF-3.3/NOPB Power Management ICs / Switching Regulators and Controllers
  • 1 × MCP73831T-2ACI/OT Power Management ICs / Power Supply Support

View all 16 components

  • Beta Code

    Joe3 days ago 2 comments

    I have an example beta code that runs on two nodes. Each node can start/stop a transmission with all peripherals fully functioning.

    I have changes the RFM69_stream library to inherit the original RFM69 library from LowPowerLab. This way you can download the original library and my library and they can exist in harmony together.

    The files are here. Let me konw what you think so far.

  • Streaming now reliable

    Joe03/22/2017 at 04:21 3 comments

    I managed to get reliable streaming by optimizing the RFM69's settings.I am enabled the Gaussian filter in OOK mode, increased the power level, an improved the end-transmission algorithm. I can reliable start and stop transmissions now. Hooray!

  • Bit Error Rate !!!.!

    Joe03/16/2017 at 04:36 8 comments

    I have started writing the main code for the system. There is a simple state machine (I will probably post the diagram for it later) that manages switching between modes and determining which node is transmitting and when to receive. In short it works like this:

    1. All nodes in standby
    2. When a node wants to transmit audio, it sends a packet (with ECC) to the other node(s).
    3. The other node(s) reply with an ACK
    4. Once an ACK is received the master goes into streaming mode and the slave(s) going into streamingRX mode.

    Everything works great up to this point. Here's where things get funky.

    How do you end a transmission when the entire data pipe is dedicated to transmit audio?

    What I am doing now: when the master wants to end the transmission it sends 1000+ audio bytes of 0xAA. This is a repeating 1010 pattern that allows for good signal integrity. The slave then looks for say, 500 of these packets in a row, to end the transmission.

    Problem: I don't know if this is a "real" issue or not (it could be a bread-board signal integrity issue), but I am often seeing bits be skipped by the receiver (maybe 1 in 100,000 samples or so). For example, if a byte sequence is this:

    10101010 10101010 10101010

    I sometimes get this:

    10101010 10101101 01010101

    Where a bit is dropped causing the byte sequence to permanently be off by 1 bit. This is not only bad for the end-transmission sequence, but also the audio date can get wacky. 1 in 100,000 samples is sometihng like 1 in a couple seconds or so, so it is pretty frequent.

    I fear that the solution may be to double the data rate, or increase it by a couple bits maybe. This would allow for ECC (error correcting codes) or some way to detect a missing bit. Also, maybe Manchester encoding might help.

    My initial thoughts:

    • Make each audio packet 12 bits long
    • first 3 bits are always '111'
    • 8 bits of audio sample
    • 1 bit checksum

    Does anyone have any experience with correcting for missing bits in a bit-stream for this type of application?

  • RF Working, System Working!

    Joe03/06/2017 at 01:09 7 comments

    I am able to talk to the RF module and can send audio data to another device!! See the video below.

  • Battery Sourced

    Joe02/27/2017 at 05:28 0 comments

    I found a battery that just barely fits in the cavity space I have available, maximizing battery capacity. It is a 150mAh battery from Adafruit:

    Just one minor detail though... I forgot to add a power switch on the board. For the first prototype I will have to manually add one in-line with the battery cable. Oops!

  • Unit Tests Complete

    Joe02/27/2017 at 04:30 0 comments

    Every sub-system is working now that the Teensy is up and running. I developed some simple unit tests to help debug the board and soldering.

    The test code can be found here and used to get your own communicator debugged:

    The final step: Get the RF module up and running. First, I will verify the connections with some existing breadboard code. After that, the more major task will be to merge both transmitter and receiver code into the same file.

  • Speaker and Click Sound

    Joe02/27/2017 at 03:29 0 comments

      The Speaker and audio amp is working! I managed to get the TNG click sound to take up only 10kB of memory so I can play it every time a communication is started. Here's the procedure:

      1. I found a TNG click sound at
      2. I brought it into Audacity ( and trimmed the extra dead space at the beginning and end of the file to save memory.
      3. I then optimized the data-rate as low as I could. The click sound is pretty high frequency so I could only get it down to 32ksampels/second before it started sounding poor.
      4. I them exported it as an unsigned 8-bit WAV file
      5. I used Sox to trim extra data from the file:
      6. Finally, I used wav2C to create a program memory constant of the wav file:
      7. I my main code, I dump the audio, sample by sample with a 32kHz timer.

      I'll post the wav file so you can hear what I came up with with only 10kB or program memory space.

  • Microphone and Accelerometer Working!

    Joe02/24/2017 at 02:55 0 comments

    Horray! Now that the Teensy issues are solved I have been making super progress!

    • The Accelerometer is working. I have it configured as a tap detector. I had to modify some libraries :( which will make code reuse a little pain, but it works!
    • The microphone is working better than I expected. Actually, it is so sensitive, it is easy to overdrive it just by yelling while the badge is on your chest. Here's a screenshot of me humming a tone, while looking forward with the badge on my chest.

  • It's Alive!!!!!!!!!!

    Joe02/24/2017 at 01:46 0 comments


    Thanks to some helpful guidance from Paul on the PRJC forum and I found a missing trace on one of the USB lines. I repaired it and am now talking with the Teensy. A huge step forward!

    NOTE: the new version of the board does NOT have this mistake.

    Next step, start talking with the accelerometer and microphone!

  • Do you have a good attention to detail?

    Joe02/23/2017 at 02:29 0 comments

    Hi Project followers! Do you have a good eye for soldering mistakes? I have posted detailed photos of the current board that is not working.

    If you spot a smoking gun I will forever be in gratitude!

View all 13 project logs

  • 1

    Order Parts and PCB: Version 2.1 of the board can be found on (Osh Park). Make sure you check the box for "2 oz copper, 0.8mm thickness." This will get the right impedance for the 50-ohm trace to the antenna. This is a complex build requiring many SMD components. Many components are standard ICs and passives that can be found on this list, but there are a couple components that must be special ordered:

    1. The MKL02Z32 must be purchased with the teensy bootloader pre-burned in it from here
    2. The RFM69HCW must be the 915 MHz version to match the antenna
  • 2

    SMD Solder: This is NOT EASY. The density of this board is very high. The components have very small pin pitches and some CAN ONLY BE REFLOW SOLDERED. For example, the microphone pins are underneath the part have cannot be accessed with a soldering iron and there is a ground plane under the Teensy.

    I recommend building this in steps. Populate the Teensy LC chip, it's bootloader chip, the crystal oscillator, and the reset switch. This will allow you to get the teensy up and running before waisting time with other components. If the teensy doesn't work, nothing will work. You can bypass the 3.3V regulator and use a bench power supply to connect to the 3.3V power pin (and ground of course).

    Test the teensy by connecting to it on your PC and making sure you can program it with some example code or simple blink code. If you can take to it you are good!

  • 3

    Next, or if you don't have a bench power supply, populate the 3.3V regulator and it's associated components. Test it with a multi-meter.

View all 5 instructions

Enjoy this project?



josephchrzempiec wrote 03/23/2017 at 17:38 point

Hello Joe congrats on the Smooth Transmitting part. I mange to get my Arduino transmitting and receiving.  Working on  adding the Tap detection part. Then I'm going to work on the Sound part. My self right now i wanted to test see if i want mange to do some tapping and lighting up some Led's, Then move onto the Sound.  

  Are you sure? yes | no


[this comment has been deleted]

TheotherMike wrote 03/10/2017 at 07:57 point

Intervaltimer is a Teensy specific function. Did you compile it using the "Teensy LC" board in the IDE? "Intervaltimer" does not work with common Arduino boards.

Did you check the RFM lib using an Editor? There must be  the Streaming class inside. As already mentioned below, it compiles well with Arduino 1.8.1 and Teensyduinoinstaller 1.35.

  Are you sure? yes | no

Neo wrote 03/10/2017 at 20:02 point

Hey joseph, the only thing that would not work on a SAMD21 board, which is what I understand you have, is the timer part. You can try the following sketch to see how a timer can be set on a SAMD21 processor in Arduino. I found it in an instructable on DACs or something, don't remember exactly. The code in the link should just blink pin13 on and off, but you can set it to 15kHz or whatever the communicator sketch uses and call the respective functions. I don't have a proper working example because my Feather M0 code doesn't seem to work yet  with the RFM69 (haven't had time to figure out why). Maybe you'll have better luck


PS: make sure you use the library '' in this project's file section. the one in the examples joe posted is an old version that doesn't have the receiveStreamByte functions etc.

  Are you sure? yes | no

Jonathan Beri wrote 03/09/2017 at 02:50 point

Have you looked at any of the 802.15.4g-based devices? I think they might meet all your requirements. TI is known to have have one of the lowest-powered parts, plus they have the MCU embedded on the device, so no need for extra micro . I'd take a look at the cc120xx and cc13xx, though all the other folks doing RFICs have 802.15.4g options.

(Disclaimer I don't work for any silicon vendor nor do I have an axe to grind. Just familiar with the low power wireless space.)

  Are you sure? yes | no

Joe wrote 03/11/2017 at 17:39 point

Yes, I remember looking at the CC series from TI several years ago. From what I remember, the ADC/DAC were either missing or couldn't support the requirements  of the system (data rate, precision, etc.). Actually I don't think it has a DAC at all. More importantly, I wanted a micro that had a lot of community support. I didn't want to waste time writing timer libraries etc. 

But I agree, with more effort, I think it would be possible

  Are you sure? yes | no

Jonathan Beri wrote 03/15/2017 at 18:14 point

cc actually covers their entire Wireless MCU line - bluetooth, Wi-Fi, 802.15.4, etc. What are you using the DAC for? Audio? Is I2S sufficient?

  Are you sure? yes | no

Joe wrote 03/15/2017 at 19:08 point

Yes, the DAC would be for audio. I2S would still ultimately require an I2S audio dac/driver/amplifier. plus it is probably a bit overkill for low bandwidth, 8-bit audio. I think the simple solution would be to use one of the timers in PWM mode with a low pass filter. Again, I just don't want to have to write the library for it. Teensy has a PWM-DAC library ready to use.

  Are you sure? yes | no

Jonathan Beri wrote 03/15/2017 at 19:37 point

heh, you're probably right. So no nyan cat egg easter egg @ lossless audio?

  Are you sure? yes | no

Neo wrote 03/07/2017 at 18:15 point

Joe, are you sure the uploaded example sketches for the transmitter and receiver are correct? The ones in I mean.

Far as I can tell the idea for the transmitter is that you have an interrupt that runs at 15.626kHz that gets one sample (8 bits) from the ADC and sends it to the RFM69 via sendStreamByte() and that should get stored in the FIFO on the RF module. Then every 200ms you tell the radio to send the data out.

But in the example in Files I don't get why you need the 'sendbuffer' variable at all, since you're just pushing stuff straight over SPI to FIFO. Shouldn't the interrupt add bytes to the 'sendbuffer' instead? Could you please check if the code works, or maybe upload the code you used in the video (guessing it's evolved a bit since the first upload :D).


PS: this is what I'm getting on the scope for the transmitter (red is the DAC pin, yellow is the IRQ line), seems like there's large pauses (that 200ms delay in the sketch) where nothing happens, just doesn't seem right (I may be wrong, still learning all this).

  Are you sure? yes | no

Joe wrote 03/07/2017 at 21:03 point

Hi Neo, This is a primitive version of the code I used in the video... Because there is no handshaking happening, you need to turn on the receiver before the transmitter to make sure it is ready. There is an important reason for the buffer. The buffer is used to fill the FIFO at the beginning of the transmission. The streaming happens at a constant bit rate. Because of this constant bit rate, the FIFO is constantly being emptied at a rate approximately equal to 15.626kHz. Therefore, we need to fill it at the same rate to make sure it doesn't empty. Once it empties, the transmission is ended. So we fill it at the begining to lessen the chances of it running out.

What I would try: unplug both chips. Plug in the RX, wait 2 seconds, plug in the TX. Hopefully that will work.

  Are you sure? yes | no

Neo wrote 03/07/2017 at 23:23 point

So.. basically sendStreamByte() loads a byte into the FIFO, receiveStreamByte() gets one byte from FIFO and the in the loop of Tx restarts the transmission if it's stopped for some reason. Right?

So the stuff I'm seeing on my scope is the transmission starting then stopping after a while and then getting restarted 200ms later when the loop kicks in. So that means I'm not filling the FIFO fast enough?

  Are you sure? yes | no

Joe wrote 03/11/2017 at 17:46 point

If the transmit timer and receive timer are running at the same rate it is unlikely that the FIFO would empty. I have found it much easier to debug with serial.print statements. I start by printing the each byte I send to the radio. Them on the receiving end I print the data received. In the past I sent an incrementing variable to make sure the data was not getting corrupted. It was getting corrupted because I was using the teensys regulator which was not strong enough to power the radio. So DVD is another thing to check

  Are you sure? yes | no

Joe wrote 03/13/2017 at 02:06 point

Hi Neo, I just uploaded the demo code again after testing it with my setup. I also added the code used in the actual demo video. Here's one important thing to check. The default radio frequency was 433MHz, you are probably using the 915MHz version. Therefore, make sure you have the right radio version selected, i.e.

//#define FREQUENCY   RF69_433MHZ
#define FREQUENCY     RF69_915MHZ

  Are you sure? yes | no

TheotherMike wrote 03/06/2017 at 18:20 point

Neo, how did you make it work? I´m still having trouble :

(Transmitter:75: error: 'class RFM69' has no member named 'streamingMode'


I downloaded the lib and copied it several times now into the library folder....I also searched for "radio.streamingMode()" within the lib files, but there´s nothing?!

  Are you sure? yes | no

Joe wrote 03/06/2017 at 19:12 point

Hi Mike, here's my experience... Fist, make sure you see radio.streamingMode() in the files you downloaded before copying them over. Maybe there is a weird browser caching issue. Next, I have found older versions of the Arduino IDE store libraries in different places. Therefore, on my machine, I have found several copies in different places. I would check the compile log to see which folder it is getting the library from.

  Are you sure? yes | no

TheotherMike wrote 03/06/2017 at 20:05 point

Oh my God... I never thought that could be possible...!! I used my girlfriends machine, downloaded the file again, et voila a different content. After copying it using a usb drive it compiles now without a problem !! Awesome, thank you for your good advice! Btw, today my OSH-boards came in and so I´m only missing the LIS3DHTR and the MKL02...

  Are you sure? yes | no

josephchrzempiec wrote 03/07/2017 at 07:26 point

Joe what version of arduino IDE did you use and Which library did you use? Reason I'm asking is because I'm also having a hard time with the library you provided.

  Are you sure? yes | no

Neo wrote 03/07/2017 at 10:20 point

josephchrzempiec, make sure you download the library again from the files section, it's been changed (file name is the same). if you have the right version you should be able to find 'streamingMode' in the RFM69.cpp file.

  Are you sure? yes | no

Joe wrote 03/07/2017 at 14:45 point

I used the newest Arduino, 1.8.1 I believe. And most importantly the newest teensyduino

  Are you sure? yes | no

TheotherMike wrote 03/07/2017 at 07:48 point

josephchrzempiec, you can get it compiled using the latest Arduino IDE (1.8.1) and the latest Teensyduino installer 1.35. First, install Arduino, second Teensyduino. You have to Switch the board type to Teensy LC afterwards in the Arduino IDE.

Using a "Standard" Arduino board you might get an error concerning the Intervaltimer. I think Neo has modified it for use with the ATSAMD21 (Arduino zero), but I do not know how he did it in detail. The libraries above are indeed working, just make sure (with an Editor you can search within the "RFM69.h etc) you find "stream" somewhere in it.

  Are you sure? yes | no

Neo wrote 03/07/2017 at 10:23 point

I'm still working on my samd21 version, not sure if it's working yet. On anything that isn't a Teensy, you have to change the timer code to something that works (different implementations for each platform sadly, no unified library). I'll make a project when I do get it working (full credit to joe of course).

  Are you sure? yes | no

Neo wrote 03/04/2017 at 09:53 point

Hello, I'm trying to replicate your project (with a SAMD21) but I think the RFM69 library you provided in the send/receive example isn't the right one. I'm getting compile errors for radio.streamingMode() and radio.sendStreamByte(data). I can't seem to find that code for those anywhere.

  Are you sure? yes | no

josephchrzempiec wrote 03/04/2017 at 17:00 point

hello I myself tried it on a uno and mega board and worked. But not on the teensy or arduino m0 board.

  Are you sure? yes | no

TheotherMike wrote 03/05/2017 at 11:26 point

Indeed, I have the same difficulties with the radio.streamingMode()...!!  Might be that´s what Joe means with the "custom library trunk" because the original lib does not support continuous mode?!? Im using Arduino 1.8.1 and the latest teensyduinoinstaller for now. How did you managed to solve the "Intervaltimer" for the samd21? Isn´t this timer a teensy function?

Would be great to get it running on several systems!

  Are you sure? yes | no

Joe wrote 03/05/2017 at 17:42 point

yes that is a custom function that I wrote. I must have forgot to post the new lib. I'll do that later today.

  Are you sure? yes | no

Neo wrote 03/05/2017 at 19:13 point

Thanks man, great project so far :)

  Are you sure? yes | no

Neo wrote 03/06/2017 at 08:12 point

The library you added yesterday (RFM69_Stream) is still missing those extra functions :(

  Are you sure? yes | no

Joe wrote 03/06/2017 at 16:49 point

Really! I wonder where I copied that from. I didn't think I still had the original version... Anyway, I have now replaced it with the correct version.

  Are you sure? yes | no

Neo wrote 03/06/2017 at 16:59 point

It's good now THANK YOU :D

  Are you sure? yes | no

josephchrzempiec wrote 03/04/2017 at 03:11 point

I have got my wireless modules in, as well as the microphone and speaker 3 days ago but haven't got around to tested it into today. So today I have tested a hello word test and it did work at 1/4mile with no problem. This is awesome sense I do not have the speaker amp yet.u couldn't get the speaker or microphone hooked up. But as I was getting home nail came in and it was the audio amp and 3 axes gyro with it. So tomorrow going to test the microphone on my meter and see what I get from it as well I will test the speaker and audio amp as well. I will post a update layer on.

So far everything is awesome.

  Are you sure? yes | no

TheotherMike wrote 03/04/2017 at 16:06 point

Hey that´s wonderful! I´m also interested what parts (breakout boards?) you use and how you have tested it / setted it up and running? 

  Are you sure? yes | no

josephchrzempiec wrote 03/04/2017 at 18:32 point

Right now at this point i solders male header pins onto the rf modules to make it breadboard friendly. I had to bend some header pins over a little to make it fit. But it was better then soldering one wire at a time and making it fit and look crazy. LOL then i used the library. Then i went to to try it out. I didn't get no where with it. So i searched online for a library and example. I can't find it now because I'm on the road when i get back home in 2 days or close to home then i will update this post with that link in it.

  Are you sure? yes | no

Neo wrote 03/01/2017 at 09:20 point

Glad you got it working, looking forward to the RF part of the project, what library did you think of using for the RFM69 ?

  Are you sure? yes | no

Joe wrote 03/01/2017 at 16:47 point

I am using a custom trunk of the library. I decided that I needed more flexibility to switch between low power packet mode and high-power streaming. Right now, the protocol is designed to send a lower power encrypted packet to tell the slaves to start receiving audio, then I kick the master and slaves into streaming mode.

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 21:52 point

Hello Joe so i have a question. So if one of the nodes if clicked that becomes the master and all of the other ones are slaves and listen, And once done it releasing being a master then any other node can click and become a master then the rest will be slaves into that second use releases it and hen someone else can be master so forth?

  Are you sure? yes | no

Joe wrote 03/01/2017 at 23:14 point

josephchrzempiec, that handshake methodology is correct. The chalenge is knowing when the master is done... I am hoping to use the audio level with a timer but it might prove to be dificult. I might have to have the master tap to end the transmission.

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 23:27 point

Hello Joe i would also do that. Because if you remember in Star trek no matter what version of the TV show they did was tap to connect the call and tap again to disconnect the call.

Or tap once to talk for a few seconds and say Joseph to Joe then it will disconnect and the other side they can say tap once will active a timer and say Go for Joe. Then back to Joseph taps twice to connect the call and he can tell his thing and talk when he is done talking tap twice and Joe then can tap twice and talk into he is done then tap twice to disconnect the call.

  Are you sure? yes | no

TheotherMike wrote 03/02/2017 at 18:44 point

When thinking about usability, it´s absolutely necessary to have a timeout after a tap (lets say 2 minutes or so). I know several cases where a walkie-talkie (pmr) was permanently ransmitting because of a jammed transmit button. The sender did not know that and all others had no chance to tell him, leading to hours of random noise on the receiving sides. Tap to speak and tap again to stop is good, but not enough. Perhaps, depending on noise floor level, one could use a time averaged audio volume level as a threshold. For this, it might be useful to continuously sample the noise floor even when not in transmission mode. Perhaps, this might also be a way to automatically scale the output speaker volume...?? So, shortly before a tap, the background noise would be known and the timeout threshold could be calculated. And on the receiving side, the output volume could be calculated based on the local noisefloor around the receiver.......Of course, this only works in cases where the backround noise does not increase massively while speaking.  In addition, the end of a transmission should ideally be terminated with a very short beep to give feedback the transmission is definitely over. Then, in case the background has increased and no stop-Beep was audible, tap again.

In summary:

-Limit transmission time to an absolute maximum (2 min, 3 min,...) to eliminate the risk of jammed channels.

- Continuous audio sampling to sense background noise for calculating threshold for transmission end detection as well as scaling the volume out.

- Beep when transmission ends.

- Override everything and stop transmission with a second tap.

...well, just my 2 cents.... would be nice to have, but the above sounds easier than it is. Myself, I´m just a beginner in terms of programming and electronics. So I highly appreciate the work already shared here and salute to joe and his fast progress.

  Are you sure? yes | no

josephchrzempiec wrote 03/03/2017 at 15:38 point

Hello TheOtherMike. You are right it's just  few things i saw while watching Tv that's all. But this project can be many things. Jow has made a awesome project thank you for that Joe.

  Are you sure? yes | no

josephchrzempiec wrote 03/03/2017 at 03:05 point

Hello TheotherMike Thank you for that information. Yes a max of a 2 minute talk will be the max. But  i think a 2 stage of talk would be great. First if tap once timer will start that will be 10 to 15 seconds timer. That way you can make a contact between you are that person. It is what i saw while watching Star trek over the years then after that time out is finished it disconnects that call.  And that person responds back. a timer is set to 10 or 15 seconds. When that timer is finished then that person can tap again and that 10 to 15 seconds starts again and have a short talk. Or tape twice and a 2 minute max timer starts and have a longer talk. But what happens if need a longer then two minute talk. Well then at that time maybe can add a third stage. While can be up to say 10 to 20 minutes. I think that would be a useful thing to have. With this project It is limitless. Whatever a person mind can come up with for this project.
But i fell in love with this project. Because one it is from start trek and two is the communication badge.

  Are you sure? yes | no

TheotherMike wrote 03/03/2017 at 10:40 point

I don´t know if that´s practical...within your case, there´s a deadtime of 20-30s no one can speak. A fixed timer only leads to massive delays...and every user is impatient! ;-) In some cases even 2 seconds are too Long.   Additionally, it does not need to be fully comparable to the original one in the movies because there are sometimes some Logical Errors in the series ! ;-) . Just using it as a "simple walkie-talkie" (with a continuous-transmission-prevention-override) would be very comfortable, fast, usable, safe, fun&easy....and would be much better than anything already made.

But he has shared everything up to now, so you can adapt it to your demands... That´s cool, and I love it too!

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 05:56 point

I'm still trying to figure out how to program it on a arduino board. Sense I do not have a Teensy board, And i do not know how to program one. The board i have is a Arduino m0 pro which uses the same chip set as the Teensy chip you have here.

Any chances who might be able to help out on the code side with this? Sense my background is hardware. And i know a little programming But not by much.

  Are you sure? yes | no

Joe wrote 03/01/2017 at 06:21 point

If it is the exact same chip then you can just program it with no changes. You will need the teensy libraries to compile it though. That's a matter of downloading the LATEST Arduino IDE. Then downloading the Teensy software that installs on top of it. In the IDE I think you can just set the board to be 'Arduino m0 pro' and click upload program.

  Are you sure? yes | no

Neo wrote 03/01/2017 at 09:17 point

The Arduino M0 Pro uses a ATSAMD21G18 processor, it's a different chip with different peripherals, so it won't work with some Teensy libraries. Teensy is based on a MK20DX processor. They are both ARM Cortex, but the peripherals and stuff aren't the same. You may have to rewrite some stuff to get it to work the same.

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 15:03 point

Hello Neo you are correct i looked at it more carefully.   

  Are you sure? yes | no

Joe wrote 03/01/2017 at 16:49 point

Most of the code is chip-independent for the most part. I am using internal pulllups on the I2C bus which requires the Teensy I2C library. That will likely have to be modified. Only the tap detector uses I2C

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 04:23 point

A Few of these parts was out of stock from mouser and digikey. But i found them on eBay a little more for just making prototype on breadboard isn't so bad. Like the LIS3DHTR not available on mouser or digikey but found it on eBay in the us between $9 and $11 US dollars.

  Are you sure? yes | no

Joe wrote 03/01/2017 at 05:00 point

I just looked, it looks like mouser has 100k on order now. I wonder if someone came by and wiped them out, it is a super popular part.

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 05:36 point

I have just a few second ago looked it up again and this is what it told me.

Stock: 0

On Order: 105235 

Factory Lead-Time:
9 Weeks

Manufacturing delays have been reported on this product.

What that means is that there is none :(

i did find this one which has everything on it. For testing this is perfect. What do you think?

And to think about it for building someone this awesome in the long run wouldn't be that bad for paying a little more for a breadboard type of testing board.

  Are you sure? yes | no

Joe wrote 03/01/2017 at 06:17 point

Yes, I was agreeing with you, 100k are on order. This usually hapens when someone buys out the entire stock very fast. It's jsut a bit surprizing.

  Are you sure? yes | no

TheotherMike wrote 02/24/2017 at 09:43 point

Awesome !! Congratulations for getting it running !!

  Are you sure? yes | no

josephchrzempiec wrote 03/01/2017 at 04:28 point

Yes big time congrats for him to getting it to work. I been following this from day one and it blow my mind. Now I see where this is going and I'm to excited to see when t is completed.

  Are you sure? yes | no

josephchrzempiec wrote 02/24/2017 at 09:30 point

Hello as i understand more and more about this project and how it coming along I'm also happy you got the Teensy up and running that one thing came to my mind. I understand what the microphone role plays in all this as well as the speaker and other parts. But what i do not understand as of yet What does the Accelerometer Rule plays in all of this?

  Are you sure? yes | no

TheotherMike wrote 02/24/2017 at 09:39 point

Tap recognition....just tap it, and speak. You should read through the whole texts here ! ;-)

  Are you sure? yes | no

josephchrzempiec wrote 02/24/2017 at 09:44 point

heLloyd I inderstand the tap function. But I was wondering if there was another function to it? I mean does it also survey another purpose besides the tap function? Sorry I should I rephrase  this question a little better.

  Are you sure? yes | no

josephchrzempiec wrote 02/24/2017 at 09:44 point

heLloyd I inderstand the tap function. But I was wondering if there was another function to it? I mean does it also survey another purpose besides the tap function? Sorry I should I rephrase  this question a little better.

  Are you sure? yes | no

Joe wrote 02/24/2017 at 18:39 point

yup, just tap detection

  Are you sure? yes | no

josephchrzempiec wrote 02/27/2017 at 06:59 point

Hello using the Accelerometer  won't it be doing something if  you are walking? what i mean it uses movement to activate it correct? So if you are moving won't it activate the comm badge? 

  Are you sure? yes | no

Joe wrote 02/27/2017 at 16:39 point

this particular accelerometer has a tap detector algorithm/mode. so you can walk around all you want and it will only trigger on a sharp event like a tap. the threshold is programmable so you can filter out false positives.

  Are you sure? yes | no

josephchrzempiec wrote 02/27/2017 at 18:58 point

oh that is awesome. Thank you. Mouse was backstock on it. Looking at digikey for it or a breakout board maybe through eBay. Because I'm only my self in the testing phrase. I got my rf modules in, as well as the microphone, transducer/speaker and audio amp in. So going to build then this weekend to see how they workout. Thrn take it from there.

  Are you sure? yes | no

TheotherMike wrote 02/27/2017 at 19:19 point

Mmh, I´m still waiting for all the mouser shipment is lost (!), pcb still in the US (and not yet in Europe), RFM69hcw in Poland, LIS3DHTR in China..... not easy getting everything "fast", but endurance will pay out. Joe´s communicator is going from awesome to even more awesome. The audio chirp sounds great. I hope I do not mess it all up in the near future while soldering ...

  Are you sure? yes | no

josephchrzempiec wrote 02/22/2017 at 05:18 point

So I'm getting the hang of all your information here  and 2 things in your parts list i didn't understand. there was it looked like two processors  chips. But in fact there is just one chip is the processor and one is a programmer chip. Basically you are just making a all in one board using  a teensy layout and programming correct? Sorry still kinda new to all this.

  Are you sure? yes | no

TheotherMike wrote 02/22/2017 at 07:58 point

Joe is basically building a Teensy LC, with a layout especially designed for use with the RFM69. The basic schematic should be comparable to this one (at least I think so):

That´s also the reason why you Need a Special pre-programmed chip from pjrc. It includes the bootloader program which is needed so you can use the Arduino IDE with the Teensy LC...

  Are you sure? yes | no

josephchrzempiec wrote 02/22/2017 at 08:01 point

Thank you TheotherMike for that.  I had a feeling it was for a teensy board. I my self never had a teensy board. I only learned a lot using arduino and arduino IDE not even sure what is the difference between the Arduino M0 pro board and the Teensy other then it uses the same Processor chip.

  Are you sure? yes | no

josephchrzempiec wrote 02/21/2017 at 21:44 point

Hello i have a question maybe I'm missing this. But which battery are you plan on using with the communicator? Also i was why two processors chips. Is one focus on processing the sound and the other focusing on transmitting and receiving?

  Are you sure? yes | no

Joe wrote 02/21/2017 at 23:46 point

Thats a good question... I don't have one on the list. It must be a LIPO battery as the charger chip is designed for one. Then it's just a matter of size that will fit in the form factor. I haven't sourced one yet but the final design will probably fit about 50-100mAh or so.

  Are you sure? yes | no

josephchrzempiec wrote 02/22/2017 at 01:00 point

Thank you. Being at 50 to 100ma current. How long do you think you might get out of it? What i mean is Do you expect it to last a longer time say over 2 or 3 hours, Or will it last longer? I know these micro processors take low power only a few milliamps But the RF transceiver not sure of.

  Are you sure? yes | no

Joe wrote 02/22/2017 at 01:17 point

the rfm69 has a low power receive mode that only takes 16mA, duty cycled with a standby mode of 1.25mA (and maybe even 0.1uA sleep with clear coding). So the battery life will be dominated by talk time (up to 100mA for max range). If you don't talk hardly at all, I think we can get a full day of standby out of it.

  Are you sure? yes | no

josephchrzempiec wrote 02/23/2017 at 06:55 point

Sense I don't have a Teensy i will look into  Using my arduino i know that the RFM69HCW does work on the Arduino But getting the audio to work will take some Doing. 

  Are you sure? yes | no

Joe wrote 02/23/2017 at 16:11 point

it should work, make sure you choose one with a fast frequency. I think the Uno is too slow.

  Are you sure? yes | no

josephchrzempiec wrote 02/20/2017 at 00:51 point

Hello i have a question in your documentation you are using the M0 chip is that for the arduino m0 pro board chip? The second question i have is what about code for sketch or libraries and what not? I wanted to make one But I'm not a coder my self.

  Are you sure? yes | no

Joe wrote 02/20/2017 at 04:55 point

I am using a Teensy LC chip. This is essentially made up of two arm chips: the main micro (MKL26Z64VFT4) and a bootloader micro (MKL02Z32). The MKL02Z32 chip needs to be bought from with their custom firmware loaded on it. This allows you to them program the main micro via USB with the Arduino IDE. I am far from finishing the software. But I have a demo that puts one module in TX and another in RX. Once I get the new board up and running I will post a better demo SW release.

  Are you sure? yes | no

Neo wrote 02/17/2017 at 18:34 point

Keep up the good work, very exciting project!

  Are you sure? yes | no

TheotherMike wrote 02/16/2017 at 17:55 point

Dear Joe, could you please also update the eagle files?

  Are you sure? yes | no

TheotherMike wrote 02/16/2017 at 17:57 point

...brd ordered... :-)

  Are you sure? yes | no

Joe wrote 02/17/2017 at 07:26 point

Done. When you are ordering parts, make sure you get the MKL02Z32 from PRJC because it needs a pre-loaded teensy bootloader. I'll attach my Mouser invoice so you konw exactly what parts to get...

  Are you sure? yes | no

TheotherMike wrote 02/20/2017 at 19:14 point

Parts now also ordered....your part list was a great help, thank you! The preprogrammed bootloader chips are a bigger problem in Europe and will take some weeks from now on... :-|  Well, it´s getting more and more exciting with your project !! :-)))

  Are you sure? yes | no

josephchrzempiec wrote 02/16/2017 at 07:12 point

Hello 255 nodes is the max what happens if you have more then what is there a way to add more? Also what about code to make the audio to transmit and receive? 

  Are you sure? yes | no

Joe wrote 02/17/2017 at 07:17 point

Actually there is a maximum of 255 node IDs. If two nodes have the same ID it is probably fine. The only reason we would care about the IDs is if we wanted to restrict communications or maybe have multiple channels.

  Are you sure? yes | no

TheotherMike wrote 02/10/2017 at 09:07 point

Perhaps I don´t see it in the Image (no Viewer at Hand...), but don´t you Need pin 2 on GND ?

  Are you sure? yes | no

Joe wrote 02/10/2017 at 17:01 point

Thanks for looking, pin 2 is grounded via a connection to the center pad.

  Are you sure? yes | no

TheotherMike wrote 02/10/2017 at 18:33 point

Alright,, I´m sorry to ask again..... is the center pad really connected to GND. On this computer I have an old eagle version and neither in the .sch nor in .brd I can see a real connection. Might just be an issue with my program or my lacking skills...

  Are you sure? yes | no

Joe wrote 02/10/2017 at 19:03 point

Gosh, I hope I didn't mess that up...The via in the center of the pad should connect the pad to the ground plane below. Where in the sch do you not see the GND connection? I have 3 VSS pins on the left side that are all connected together. Does the image of the schematic I posted look the same as what your eagle is showing?

  Are you sure? yes | no

TheotherMike wrote 02/10/2017 at 19:13 point

Yes, Sir, it looks identical. But I miss pin 2 in the schematic, like shown here:

I´m still not able to verify the gnd-plane...

Edit: I the brd it seems to be all connected...mmhhhh.....

  Are you sure? yes | no

Joe wrote 02/06/2017 at 06:52 point

I am using a custom trunk of the library. I decided that I needed more flexibility to switch between low power packet mode and high-power streaming. Right now, the protocol is designed to send a lower power encrypted packet to tell the slaves to start receiving audio, then I kick the master and slaves into streaming mode. Yes, the LIS3DH is for tap detection. I'll be posting some example fixed master, fixed slave code soon.

  Are you sure? yes | no

Does this project spark your interest?

Become a member to follow this project and never miss any updates