Walkie Talkie hacking
I tried to hack a pair of cheap (5 Euros) walkie-talkie that I bought in Paris. They work with 4 x 1.5V batteries (so 6V, but actually the batteries are kind of cheap so it makes 5V).
There is a speaker that is used also as a microphone (triggered by a push-button). The output is very noisy.
I managed to do something simple and stupid:
- send an audio signal with an Arduino (emitter) through the PWM pin 11 (by plugin it instead of the speaker/mic ... ouch ...)
- receive the signal with an Arduino (receiver) through an analog pin (pin 0) (still by plugin it straight in place of the speaker/mic)
- the receiver then emits the same signal on its PWM pin 11
So this is simply reproducing the same thing the walkie-talkies originally did, using two Arduinos... However, it worked!!! so we can use if for audio communication.
But my plan is not to send noising sound, but to use it for sending a very basic message (on/off) ie. a trigger. I figure we can do that by sending a very loud sound. On the receiver side, I take the minimum and maximum values as well as the average over 1000 samples. However, these stats don't really change when I send the signal (that is because the signal is very noisy as I said earlier).
By playing with them, I killed them, it doesn't work anymore. Sad.
The lessons:
- I stupidly plugged the things with the batteries. I should have used the Arduino's power, so as not to create a short-circuit. This is what probably killed the poor thing.
- It's easy to hijack cheap walkie-talkies but because of the noise, we will need much software filtering to get them to pass a message.
New ideas:
- We should try to detect other things than max/min/average. Perhaps detecting a frequency would be a better bet, but this is rather difficult.
- Another trick would be to filter out noise using a high-pass filter (or low-pass) (see this page for more details).
- The design of the talkies looks rather simple, so maybe there is a way to reproduce it.
Here is the code for the emitter:
<code>
/*
* Simple Walkie talkie emitter
* (emits a square wav)
*
* (c) 2008 Sofian Audry (info _A_ sofianaudry _D_ com)
* Distributed under the Gnu GPL v3 or later,
* see <http://www.gnu.org/licenses/>
*/
- define SPEAKER_PIN 11
- define VOLUME 127
- define PERIOD 500
void setup() {
}
analogWrite(SPEAKER_PIN, VOLUME);
delayMicroseconds(PERIOD / 2);
analogWrite(SPEAKER_PIN, 0);
delayMicroseconds(PERIOD / 2);
}
</code>
And here for the receiver:
<code>
/*
* Simple Walkie talkie receiver
* (dummy, resends what it receives as input)
*
* (c) 2008 Sofian Audry (info _A_ sofianaudry _D_ com)
* Distributed under the Gnu GPL v3 or later,
* see <http://www.gnu.org/licenses/>
*/
- define MICRO_PIN 0
- define SPEAKER_PIN 11
void setup() {
}
analogWrite(SPEAKER_PIN, analogRead(MICRO_PIN) / 4);
}
</code>



