Wednesday, November 16, 2011

Maxtroller and Maxduino







After learning about the Arduino microcontroller and hearing how it had been used to turn an old Motorola Maxtrac radio into a trunking scanner, I wanted to try it out for myself.  It's a project that combines both hardware and software aspects.  I would have an opportunity to practice my soldering skills as well as some programming skills.  It had been years since I took a C programming class in college, so I was looking forward to dusting off some of the things I learned.

Instructions for the project written by GroundLoop can be found here:

Instructions Update
Original Unmodified Code
Code Modified to Use Maxtroller Squelch
Code for Maxtroller Discrimator Audio Parking

I won't repeat these instructions here since they are well-written. There were a few differences between my 5-pin Maxtrac radios and the 16-pin Maxtrac radios used in the instructions, but the differences were resolved by comparing my radio's board and the pictures of the16-pin's board.  The biggest software change I made was to wire the CSQ "squelch" circuit to the Arduino and use it to mute and unmute the Maxtrac.  Without this change I was getting very long squelch tails (up to 2 seconds) that were fairly intolerable.  Now the squelch tail is fairly tight and a lot less noticeable.






For my first attempt at building the Maxdunio, I crudely cut a slot in the back of the radio and ran the wires out to the Arduino.  The second time I placed an RJ-45 jack in the side of the front cover next to the speaker.  This allowed for an easy, clean connection to the Arduino or my homebuilt Maxtroller with an ethernet cable.








The original intent of the Arduino code is to interface the Arduino with Unitrunker software to receive tuning commands, process them, and forward them to the Maxtrac.  I also wanted to be able to manually tune an second Maxtrac with an Arduino and use it to feed discriminator audio to my PC and Unitrunker software.  In order to do this I built a small box using a Radio Shack project box.  It allows me to press a button and toggle through various control channel frequencies and output the audio from the Maxtrac to my computer.  I modified the Arduino code to not look for external tuning commands from Unitrunker, but cycle through a set of predefined frequencies when a button is pushed.








Here is the base of my Maxtroller box with a Radio Shack "Dual General-Purpose IC PC Board."  I used this for both the button circuit and the discriminator audio circuit to add a resistor and capacitor inline with the audio.  





For the connection between the Maxtrac and the Arduino I used an ethernet cable.  It was readily available, contained just the right number of wires, and was a neat solution which allowed for easily connecting and disconnecting the box and radio.  Since this box is a stand-alone box without need to interface with the computer, I mounted the Arduino with the USB connection away from the edge of the box for ease of fitting.  A 9v battery fits underneath the Arduino for power.  Since this photo was taken, I have added an external power jack through the side of the box.








Here is my completed "Maxtroller"with the controller box connected to the Maxtrac via ethernet cable. The discriminator audio passes through an onboard resistor and capacitor and out of the box via a mini audio jack.







This was a fun project to put together.  I had frustrations and success in making both the hardware and software work.  I love having the capabilities of an expensive scanner wrapped in a couple of very inexpensive business radios and a couple of microcontrollers.  The audio of the Maxtracs is superior to my other scanners.  And the ability to prioritize talkgroups in Unitrunker provides a lot of functionality in monitoring.

Radio Shack Parts List:

Project enclosure 5x2.5x2 - #270-1803
Dual general-purpose IC PC board - #276-159
1/4-watt 10K ohm resistors - #271-1335
10 μF tantalum capacitor -#272-1436
Size M panel-mount power jack - #274-1582
1/8" Mono panel-mount audio jack - #274-251
Metal standoffs - #276-195
Push button - #275-1566
9v snap connectors - #270-324