In the previous post, we created a TTL-compatible transmitter and receiver
circuit for an optical link. However, you might wonder why we can't use the
HFBR-1414 transmitter directly with an Arduino and why we need a driver
circuit.
The Parts of this article is as follows.
Introduction to Optical Fiber Communications and How does Optical
Fiber Communications Works ✔
Light and its Fundamentals ✔
What a Optical Fiber Cable is and its Construction ✔
Optical Fiber Transmission Setup ✔
Interfacing Optical Fiber Transmission with Arduino ✅
Optical
Fiber Communication with Arduino to Arduino and NodeMCU ESP8266
Interfacing Optical Fiber Transmission with Arduino
The previous circuit uses a resistor with a value of 220 ohms, which limits the current to 15mA. At this current, the transmitter can cover 400 meters. So, without the need for a driver circuit, you can directly connect the transmitter to an Arduino within the 15mA current range. the HFBR transmitter's current is dependent on several factors, including forward voltage and the required distance. Temperature also has an impact on it. In the datasheet, the Forward Voltage and Current Characteristics graph indicates that at 1.5 volts, the transmitter draws 15mA. If you provide the typical 1.7V forward voltage, according to the graph, it requires 60mA. So, between 1.5 volts and 1.7 volts, there's a difference of 0.2 volts, and the current goes from 15 to 60mA. This means that a mere difference of 0.2 volts results in a current difference of 45mA. Considering these variations, in my opinion, it's not a safe practice to use the transmitter directly with an Arduino, as the Arduino pins have a current limit of 40mA. However, you can still use the transmitter directly with Arduino pins.
We can create a universal transmitter circuit with slight modifications to the previous design. This circuit is not only compatible with Arduino but can also be used with other embedded devices. The circuit design is compatible with existing copper wire protocols that encode data before transmitting it through the serial communication medium. You can connect data communication interfaces such as UART, I2C, and Ethernet controllers to the transmitter. Here's the circuit diagram.
In this new design, there are only two changes. The circuit now includes capacitors with values of 100pF and 10uF, and the current-limiting resistor is now 56 ohms. The driver IC remains the same. This drive circuit, employs frequency compensation to reduce the typical rise/fall times of the Transmitter LED and a small pre-bias voltage to minimize propagation delay differences that cause pulse-width distortion. This circuit has a range of 1.5 to 2 kilometers because with a 56-ohm resistor, we set the transmitter current to 60mA, and at this current, it can cover up to 2.4 kilometers. If we consider additional losses (the graph provides a rough estimate), it can be used for our desired range. I have successfully tested it over a distance of 342 meters with Arduino UART communication because I have this length of fiber in my workplace.
Now, let's discuss how this driver circuit works. In this circuit, the IC
is a dual-peripheral driver designed for high-current, high-speed switching.
It's used for memory, line, buffer, lamp, and LED drivers. You can better
grasp the logical functioning of this driver through this demonstration.
Imagine you have an LED. To turn on the LED, if you directly connect it to a
battery or power source, the LED can draw an excessive amount of current
from the power source. This can result in the LED overheating and
potentially burning out. In some cases, the LED may fail immediately, while
in others, it may work for a brief period before failing due to the
excessive current.
By using the correct resistor, you can ensure that the LED operates within
its safe operating limits and maintains its expected performance.
Now, if you arrange the circuit like this, what happens when you open and
close the switch? In this configuration, closing the switch actually turns off
the LED by providing a much easier path for electricity to follow through the
closed switch instead of the LED. When you open the switch, the LED turns on
because there's no alternative low-resistance path, and the current flows
through the LED.
The operation of the switching driver IC is similar to this circuit. When
one of the drivers is activated from the IC, it provides a low-resistance
path, and the current does not flow to the load. Here is the logical circuit
operation of this IC, which you can easily understand from this diagram. The
gates are connected to transistors with an open collector
configuration.
If either or both of the inputs of the gate are low, the output of this
gate will also be low. As a result, there will be no signal on the
transistor's base pin, and it will remain off, causing the LED to turn on.
Otherwise, the LED will be turned off because when the gate's output is
high, the transistor will turn on, providing a much easier path for current
to flow through the transistor rather than the LED.
Proteus Simulation - Schematic & PCB
For schematic and PCB design, you can download the schematic and PCB
package files from this post, or you can search for them on other online
sites. You can follow the figure above to create the schematic, and for the
PCB, you can customize it according to your specific requirements.
ZIP Password : ArduinoMagix
Source Code : Arduino Sketches
Simulation
Real-time simulation of this fiber optical link is not
possible in Proteus because the SPICE simulator does not offer capabilities for
working with or modeling light or photonic circuits. However, you can still use
a photodiode and phototransistor with electrical signaling. This simulation
model is created using the Photodiode DT8811VB and Phototransistor Q2N3904
SPICE models with slight modifications. It represents a Fiber Optical
Transmitter and Receiver with an optical fiber link. It is designed solely for
the demonstration of TTL-compatible devices (Arduino and other
microcontrollers) connected with an optical link. Therefore, you can directly
connect Arduino and other devices to this model without the need for additional
driver circuits.
In the next post, we will set up the hardware for the actual implementation. Please provide your feedback in the comments, and I will be pleased to work on more subjects like this.