Laser Audio Transmitter

Jehhal Liu (jl589), Daniel Zuo (dyz2)

Introduction
Project Details
Design Details
Results
Conclusions
Appendices

Introduction

This project is a proof-of-concept device that transmits an audio signal using a laser beam, while removing the need for the user to align the beam themselves.

For our project, we created a mono-axial transmitter/receiver setup that converts an analog audio signal, via a standard 3.5mm jack, and transmits it via a laser to a receiver, which converts the signal back into audio. The receiver can be rotated within its horizontal plane, and uses a servo motor controlled by a microcontroller to automatically align it with the receiver. The end result is a wireless audio signal that cannot be “overheard” by other devices.

Project Details

Rationale      

Light is already becoming a popular means of communication, thanks to fiber optics, which can guide optical data much like a wire transmits current. It might seem impractical, then, to use lasers without a guiding medium to transmit information. However, in contexts where a physical connection is impossible or unfeasible, and the need for a focused beam arises, it would seem logical to use laser light. In particular, “free space” laser communication has useful applications to military logistics, where information on the front must be kept limited to friendly ears, and ground-to-air links are important. We decided to create a simple and inexpensive proof-of-concept to demonstrate the advantages of this seemingly impractical scheme.

Inspiration for this project came from a design in the book “Gonzo Gizmos: Projects & Devices to Channel Your Inner Geek,” a book written by Simon Quellen Field, in which a laser/solar cell combination allowed for the transmission of an audio signal using light. A topic of research at MIT Lincoln Laboratory (http://www.ll.mit.edu/news/freespace-lasercom.html) inspired us to incorporate tracking capability while keeping the project budget affordable at a hobbyist level.

Logical Structure

Our project is divided into two distinct sections: audio transmission via hardware, and alignment control via software. The former can be accomplished once the latter has succeeded, making the two tasks mutually dependent for overall functionality. The alignment is accomplished using a servo motor to rotate the transmitter until it aligns with the receiver. This is done by detecting the light emitted from the receiver’s laser using a phototransistor. The transmitter scans over its free range until it finds the receiver, at which point the transmitting laser is turned on and the audio signal is picked up by an array of photodiodes. The details of this process are explored below.

Safety and Standards

Since we are using lasers, the effects of exposure need to be considered. The lasers we used were purchased commercially, and comply with class IIIA power and safety specifications, as designated by the ANSI Z136.1 consensus. In the US, ANSI and OHSA standards specify the parameters under which lasers can be safely operated. For a class IIIA laser, the beams are generally not hazardous without the use of focusing equipment, though direct exposure to the eye should be avoided. With this in mind, we operated the device in a plane that lacked reflective objects and was well below eye level. Additionally, the transmitting laser is turned off when the exact direction of the laser is not known (i.e. when the transmitter is scanning the area). The receiver’s laser is limited to be just bright enough to be detected by the transmitter, but not at the peak amplitude.

Hardware/Software Tradeoffs

The audio signal sent by the transmitter is provided externally rather than via the microcontroller, since external devices represent more flexibility and mobility in the information that can be sent. Having the audio synthesized by the Mega644 would require some form of external memory and a method of flashing from an external source anyways, so we decided to cut out the middleman.

The audio signal is sent via an analog transmission instead of decoding it into a digital signal. Optical transmission is usually done using with digital signals, requiring hardware for decoding at the receiver end. By transmitting the analog audio signal through laser amplitude modulation, we cut down on the transmitter and receiver hardware by eliminating the need for encoding and decoding processors.

Design Details

Hardware

Transmitter

IMG_0498.jpg

Figure 1: Transmitter circuit, ready for operation.

The transmitter is broken down into three circuits. The first circuit, which is similar to the receiver end, is the laser audio transmission circuit. This transmitter works by modulating the amplitude of the laser based on the amplitude of the audio signal that we are trying to transmit.

The audio, which is fed to the circuit through a standard 3.5mm audio jack, is sent to an adder circuit. The adder, shown below, consists of two inputs and a negative feedback resistor that will be summed together. The two connections to the non-inverting input of the op-amp are the audio signal and a DC bias signal that is generally kept at around 3V. This voltage can be modified by adjusting a potentiometer.  

The signal to the inverting input of the op-amp is half that of the output, which is obtained by using a voltage divider of two equal resistors. This feedback allows the op-amp to follow the amplitude of the non-inverting input as it attempts to equate the voltages at the two inputs.

The output of the op-amp is sent directly to the laser. The amplitude of the laser is proportional to the voltage that is applied to it. The amplitude linearly follows the voltage up to roughly 4V, at which point the response is more exponential. We are taking advantage of the linear region of the response to send a mostly unmodified audio signal to the receiver for playback.

The laser needs to be turned off while the transmitter is scanning for the receiver, mainly for safety and power reasons. To achieve this, the 9V supply to the op-amp is controlled by an NPN transistor, which can act as a switch controlled by the microcontroller.

Macintosh HD:Users:Shared:Picture 6.png

Figure 2: Main transmitter circuit. Modulates laser amplitude based on audio input.

The second circuit in the transmitter is based on a phototransistor that responds to red light. When VCE of the transistor is set to 5 volts, the current flowing through the transistor is proportional to the amount of red light that is incident upon the detector. The current flows through the 10K resistor, resulting in a measurable voltage that is proportional to the incident light. This voltage is fed to the analog-to-digital converter of the microcontroller, and determines whether the receiver and transmitter are properly aligned and ready for transmission.

Macintosh HD:Users:Shared:Picture 5.png

Figure 3: Transmitter photo detector used for alignment purposes.

The last piece of the transmitter is the motor controlling circuit. We are using a servo motor to control the direction of the transmission. The motor is opto-isolated from the rest of circuit, and particularly, the microcontroller. This means that the motor is powered by a different power supply, and has no direct connections with any terminal of the microcontroller.

The servo motor is controlled by a pulse, whose length corresponds with the desired position of the motor. Servos can achieve absolute positioning, while other types of motors can only be positioned relative to the current state. The precisely timed pulse is sent through a 330W resistor to the input of the isolator. The output of the isolator is simply the same pulse with a 5 volt amplitude, which is then sent to the motor for positioning.

Macintosh HD:Users:Shared:Picture 3.png

Figure 4: Motor opto-isolator circuit. Pulse output goes to motor for angle control.

Receiver

The receiver circuit somewhat resembles the transmitter circuit. Rather than a single phototransistor, however, it instead uses three photodiodes, which have much larger sensitive areas compared to the transistor. Since the response of the diodes directly affects the audio quality, a more complex circuit is called for. The diodes themselves are placed between the two terminals of an op-amp, whose output voltage is determined by the current that flows through the diodes. Using an op-amp instead of biasing the diodes allows us to utilize a near-ideal short-circuit current. With three diodes in parallel, we effectively triple the area upon which we can receive a signal. After amplifying the signal with a second op-amp, the result is then fed directly to an audio jack, where the signal can be heard using any compatible device.

rx_main.png

Figure 5: Receiver main circuit. Reads detector voltage and amplifies before sending to audio jack.

Macintosh HD:Users:Shared:Picture 4.pngIMG_0489.jpg

Figure 6 (left): Receiver laser circuit. Used for alignment purposes.
Figure 7 (right): Receiver circuit, ready to operate.

Software

The software is designed to be completely interrupt-driven. Timing is based around the ability to control an output pin with a precise PWM output, allowing us to accurately control the motor for scanning purposes. The interrupt service routine is called once every five microseconds. Upon each interrupt, the program updates its timing counters, reads the output of the analog-to-digital converter when necessary, and performs state updates for receiver tracking purposes.

 


The State Machine


Figure 8: Software state machine, used for transmitter scanning.

We use a simple Moore machine to control the actions of the transmitter. The diagram above outlines its behavior.

 

Hardware Control

Through our timing control our hardware is relatively simple to manipulate. The servo motor we used uses the duration of a pulse to determine its angular position. To control this position, we set a pin high, and turn it off when a variable amount of time has elapsed. Since the execution of other instructions can have a noticeable effect on the true pulse width, this toggling is handled purely by the timer compare interrupt.

Enabling or disabling the laser is as simple as toggling a separate pin.

Attempted Designs

We attempted to implement a handful of designs that didn’t work out in the end. Hardware in particular went through a lot.

Initially we thought (naively) that a servo motor did not need to be opto-isolated. Our motor disagreed, and vibrated erratically.

The receiver went through multiple photoreceptive devices. We were going to use a solar cell, but saw that the response of a photodiode was good enough, so we used one of those instead. When we saw that the sensitive area of the phototransistor made alignment using two of them next to impossible, we switched to an array of larger photodiodes.

The power supply for the motor was originally another 9V battery, but we quickly found that the current it supplied was insufficient.

Lastly, to pour salt on our wounds, our custom Mega644 proto-board mysteriously died once everything else had been completed, taking our microcontroller with it (or vice versa?). We decided to switch to an STK 500 as our control source, lacking the time or resources to make another proto-board.

The transmitter’s laser control also went through several iterations before we landed on the final design. Specifically, the circuit designed to the laser on or off during the scan stage was modified. Originally, the DC bias input to the adder would be controlled by a potentiometer, which could be adjusted to zero when during scanning. However this method was not automatic. We then tried to control the op-amp supply voltage with an output pin of the microcontroller, but found that supplying 5 volts caused circuit to be unable to output greater than 3 volts at the output, whereas we needed an audio signal centered at roughly 3.5 volts. We also originally had a BJT that controlled a battery’s 9 volt connection to the op-amp supply, but found that if the transistor’s base voltage was kept at 5 volts, then the supply could not exceed 5 volts. We finally implemented the design described above and kept it as our final design.

Results

Hardware Performance

Audio

When dealing with audio transmission, an important consideration is how well a range of frequencies is preserved in the output. Generally, the audible frequencies range from 20 to 20,000 Hz. To that end, we ran tests comparing input waveforms with the signals generated by the receiver for various frequencies within this range. An example oscilloscope trace is shown (barely) below.


042509_14491.jpg

Figure 9: Oscilloscope trace of input vs. output (smaller signal). At audible frequency the correlation is high.

Through our tests we found that the output frequency remains the same as the input, and that the shape of the signal (a sinusoid in our tests) was preserved within the audible range. At around 50kHz the response time of the photodiode is no longer negligible and some distortion can be seen, as shown below.

042509_14521.jpg

Figure 10: As the frequency climbs beyond the audible range, the circuit has trouble responding.

The relative attenuation of different frequencies was also measured. The graph below shows how the relative amplitude depends on frequency.

freq.bmp

Figure 11: Receiver’s frequency response.

While high frequency signals are transmitted uniformly, the response drops off at the low end. The system acts on a whole as a high-pass filter with a critical frequency near 100Hz. Therefore, audio with heavy bass components will suffer the most while other components will be largely unaffected.


Motor and Alignment

The small servo motor performs admirably under the load of the transmitter circuit, operating smoothly and consistently. However, the physical connections to the power supply for the motor and the stk 500 causes the base to slide on all but the roughest of surfaces without adhesives. Once anchored, this is a non-issue.

The transmitter and receiver align moderately well. Care must be taken in placing the receiver, as its laser must point towards the center of rotation of the transmitter. Even with this satisfied, there remains a degree (no pun intended) of flexibility in the angle of the transmitter while in the “LOCK” state, which means that the transmitter beam can miss the photodiodes of the receiver as the distance between the two increases. When we switched to the array of three photodiodes, the frequency of this misalignment occurring decreased noticeably. Partial misses can also occur when the beam is between two diodes or slightly off one of them. The result is that different volumes are required in the source to prevent distortion. The impact on safety is negligible, however, given that the normal precautions associated with lasers are kept in mind.

Interference

We found that the only interference came from audio contamination due to nearby electronics. The levels of noise did not seem greater than what you might hear in cheap audio products, however.

Software Performance

On its own, the software controlling the tracking logic works without any flaws. The timing of the motor signal executes consistently, as evidenced by the operation of the motor itself. The device is capable of tracking a moving beam fairly well, though it can easily lose a beam that displaces consistently faster than approximately 5 degrees per second. If it guesses incorrectly which direction the beam went, the beam can be lost more easily. Acquiring a lock works consistently however, and we did not witness any occurrences of false positives in our testing.

Usability

In general, the device can be successfully operated by anyone with two hands, functioning eyesight, and a surplus of patience. The amount of constant voltage supplied to both lasers can be manually adjusted via trimpots to compensate for various visibility conditions, and the audio signals can be supplied and received with anything using a standard 3.5mm stereo jack (though the output is mono).

Conclusions

Expectations, Retrospect, and Possible Improvements

Our final product nearly met our initial expectations. We didn’t expect the audio quality to be as good as it was given the relative ease of designing the circuits, but the unreliable nature of the alignment was something we hadn’t anticipated, and didn’t have a solution readily available for. The software took less grief and misery than we thought, and generally worked without much cajoling.

With these points in mind, there are a few things we would have done differently. The software could be expanded to allow for the transmission of a digital I/O stream, using the RS232 capabilities of the Mega644 and more symmetry in the transmitter/receiver modules. This would allow us to tap more of the potential of the microcontrollers and broaden the usefulness of the device.

As for hardware, we found that considering every device as if the operating conditions were ideal cost us time and money that could have otherwise been more productive. Not considering the area of the phototransistors, for example, was an avoidable oversight. Additionally, with more time and an expanded budget we could deal with the alignment issue and build on it: with more investment in optical hardware the lasers could be secured with more precision, and their beams could be broadened and re-collimated. Additionally, with a more costly gimbal setup another dimension could be added to the range of the device, and with infrared imaging we could make the alignment process more accurate.

The last-minute failure of the proto-board came as a heavy blow to us late in the game. Being more prepared for the worst might have saved us some grief if we’d sampled more than one Mega644 and made more than one proto-board.

Standards

Our lasers are always operated at power levels equal to or less than that of their original design. To reduce the chances of stray beams, the transmitter is disabled until it acquires a lock. Additionally, the lasers themselves scatter a fair amount of red light from their cavities, making their operation obvious. Given these factors, and the low power of the lasers themselves, we believe we have followed the laser safety standards.

Intellectual Property Considerations

All of our code is original, and the designs for our circuits were not taken from an outside source. Since the idea for laser signal transmission is already a large part of many applications, we are confident that our device does not infringe upon the intellectual property rights of other parties. Bearing that in mind, we do not feel our device merits a patent claim. The results of the project, while somewhat novel, are not exactly unheard of and do not merit publication, save as a DIY.

Ethics

Referring to the IEEE Code of Ethics, we believe we have acted responsible as electrical engineers to the extent that our project allows. By following strict precautions in using our lasers, we have avoided safety risks to ourselves and others. Since our work was independent of outside parties and purely in the interest of fun and learning, we avoided conflicts of interest and bribery, as well as slander or intellectual dishonesty. Lastly, we hope that our device is able to demonstrate to others the capabilities and limitations of optical communication.

Legal Considerations

Since our device is a low power setup that produces minimal interfering noise, there are no legal issues at hand.


Appendices

Source Code

Source Code

Schematics

Transmitter: Main Circuit

Transmitter Alignment Unit

Motor Opto-isolator

Receiver: Main Circuit

Receiver Alignment Unit

Project Budgeting

Source

Part No.

Description

Unit Price

Quantity

ECE 4760 Lab

--

STK 500

$15.00

1

ECE 4760 Lab

--

9V Battery

$2.00

2

ECE 4760 Lab

--

Solder Board

$1.00

2

ECE 4760 Lab

--

DIP Socket

$0.50

3

ECE 4760 Lab

--

1-pin Jumper Cable

$0.50

5

ECE 4760 Lab

--

3.5mm Stereo Jack

--

2

Adam Shapiro

--

Adjustable clamp

--

1

dealextreme.com

22334

Red Laser Pointer

$1.91

2

jameco.com

hs-244

Servo Motor

$19.95

1

digikey.com

BPW46

Photodiode

$1.01

3

digikey.com

LM358ANFS-ND

Op-amp

$0.39

2

digikey.com

160-1304-5-ND

Opto-isolator

$0.32

1

digikey.com

2N3904FS-ND

NPN Transistor

$0.11

1

digikey.com

3386F-103-ND

10k Potentiometer

$1.14

2

digikey.com

AE9919-ND

3.5mm Audio Cable

$5.10

1

allelectronics.com

LT9593-91-0125

IR Phototransistor

$0.65

1

Total

$61.04

 

Division of Labor

Task

Team Member

Protoboard Assembly

Dan

Photodiode Testing

Dan & Jehhal

Solar Cell Testing

Jehhal

Transmitter Circuit

Jehhal

Receiver Circuit

Dan

Transmitter Base

Dan

Hardware Debugging

Dan & Jehhal

Software Design

Dan & Jehhal

Software Debugging

Dan & Jehhal

Weekly Updates

Dan & Jehhal

Final Report

Dan & Jehhal

 


References

Mega644 Data Sheet (http://instruct1.cit.cornell.edu/courses/ee476/AtmelStuff/mega644full.pdf)

LM358 Op-amp Data Sheet (http://instruct1.cit.cornell.edu/courses/ee476/labs/s2009/LM358.pdf)

LT9593-91-0125 Phototransistor
(www.ledtechusa.com/data/datasheets/LT7-9X/LT959X-91-0125.pdf)

BPW46 Photodiode
(http://www.vishay.com/docs/81524/bpw46.pdf)

HS-422 Servo Motor
(http://www.imagesco.com/servo/motors/HS-422.html)

Inspiration for this device came in part from the book “Gonzo Gizmos: Projects & Devices to Channel Your Inner Geek,” by Simon Quellen Field. It’s an excellent introduction into various useful scientific phenomena.
(http://www.amazon.com/Gonzo-Gizmos-Projects-Devices-Channel/dp/1556525206)

MIT Lincoln Laboratory is working on a similar, but much more complex, concept for long-range laser communication.
(http://www.ll.mit.edu/news/freespace-lasercom.html)

Thanks go to Adam Shapiro, who provided some honest feedback to our initial idea and provided a useful stand for our receiver.

Additional thanks to the following parts vendors (you can sample most of the components we purchased for free if you are patient):

(http://www.digikey.com/)

(http://www.jameco.com/)

(http://www.dealextreme.com/)