Free Trials

Download a free trial to find out which Altium software best suits your needs

How to Buy

Contact your local sales office to get started on improving your design environment


Download the latest in PCB design and EDA software

  • Altium Designer

    Complete Environment for Schematic + Layout

  • CircuitStudio

    Entry Level, Professional PCB Design Tool

  • CircuitMaker

    Community Based PCB Design Tool


    Agile PCB Design For Teams

  • Altium 365

    Connecting PCB Design to the Manufacturing Floor

  • Altium Concord Pro

    Complete Solution for Library Management

  • Octopart

    Extensive, Easy-to-Use Component Database

  • PDN Analyzer

    Natural and Effortless Power Distribution Network Analysis

  • See All Extensions

    World-Renowned Technology for Embedded Systems Development

  • Live Courses

    Learn best practices with instructional training available worldwide

  • On-Demand Courses

    Gain comprehensive knowledge without leaving your home or office

  • Altium 365 Viewer

    View & Share electronic designs in your browser

  • Altium Designer 20

    The most powerful, modern and easy-to-use PCB design tool for professional use


    Annual PCB Design Summit

    • Forum

      Where Altium users and enthusiasts can interact with each other

    • Blog

      Our blog about things that interest us and hopefully you too

    • Ideas

      Submit ideas and vote for new features you want in Altium tools

    • Bug Crunch

      Help make the software better by submitting bugs and voting on what's important

    • Wall

      A stream of events on AltiumLive you follow by participating in or subscribing to

    • Beta Program

      Information about participating in our Beta program and getting early access to Altium tools

    All Resources

    Explore the latest content from blog posts to social media and technical white papers gathered together for your convenience


    Take a look at what download options are available to best suit your needs

    How to Buy

    Contact your local sales office to get started improving your design environment

    • Documentation

      The documentation area is where you can find extensive, versioned information about our software online, for free.

    • Training & Events

      View the schedule and register for training events all around the world and online

    • Design Content

      Browse our vast library of free design content including components, templates and reference designs

    • Webinars

      Attend a live webinar online or get instant access to our on demand series of webinars

    • Support

      Get your questions answered with our variety of direct support and self-service options

    • Technical Papers

      Stay up to date with the latest technology and industry trends with our complete collection of technical white papers.

    • Video Library

      Quick and to-the-point video tutorials to get you started with Altium Designer

    PCB Design Tutorial: Tips for Using Optocouplers in Your PCB Layout

    October 31, 2017

    Are you guilty of hitting the snooze button at least twice before you reluctantly wake up from your blissful sleep? My wife claims that I probably have the world record time for hitting the snooze button since I do it without even opening my eyes. But there are times when the third snooze alarm mysteriously doesn’t go off and it is a losing battle to get my day started on time.

    In electronics, embedded systems often rely on optocouplers to receive input signals from external sensors or switches. In a way, they are like the microcontrollers’ alarm clocks. Ideally, all the signals are relayed accurately to the microcontroller. However, when the optocouplers are not properly implemented, the microcontroller can sometimes miss inputs signals or falsely detect signals when no inputs are triggered. In this PCB design tutorial, we will discuss how to set your optocoupler up for success in your PCB layout. But first, let’s remind ourselves how an optocoupler design works.

    PCB Design Tutorial: Basic Principles Of An Optocoupler

    Optocouplers are electronic components that isolate input signals through an optical interface. The most basic form of optocoupler consists of an infrared LED and a photo-transistor within a single integrated . The infrared LED is turned on when electrical current passes through and the intensity depends on the amplitude of the current. The phototransistor is activated by the LED light, which causes a short connection on between its collector and emitter.

    The infrared LED and the phototransistor are often separated by glass or air. This gives an electrical isolation of <10kV across the optocoupler. As a result, optocouplers are an ideal choice for isolating embedded systems from electrical interference originating from the input signal’s environment.

    Besides protecting the embedded system from electrical noise, optocouplers are also used to keep low voltage and high voltage systems apart. For example, photo-triac, which is a variation of optocouplers, can be used to control high AC voltages devices. For example, an AC motor. This eliminates the risk of circuitry faults that can cause damage to the microcontroller and its accompanying components.

    Single Phase Magnetic Induction Motor.
    An optocoupler can reduce the risk of high voltage damage.

    PCB Design Tutorial: Mistakes With Optocouplers

    The optocoupler is a simple passive component that most designers encounter. Getting an optocoupler to work is not rocket science; however, there are a couple of design mistakes that defeat the purpose of using one or that causes unstable input signals.

    1. Failing To Separate Optocoupler Ground Connections.

    In the basic optocoupler, the integrated (IC) consists of two ground pins. One is connected to the infrared LED and the other connected to the photo-transistor. A mistake is to connect both grounds together when routing the PCB. In my engineering experience, I’ve encountered this even in electronics controller used in machines.

    The main reason for using an optocoupler is to safely separate two circuits. When the external ground is connected to the PCB, any ground noises from the circuitry can directly couple to sensitive onboard circuits. Instead, create a separate signal connection for the external ground pins and allocate dedicated connectors for the input ground wires.

    2. Using The Wrong Value For The Current Limiting Resistor

    Besides applying the proper output voltage, the optocoupler’s infrared LED require adequate current to function properly. The value of the minimum forward current can be referred from the Current Transfer Ratio chart of the respective optocoupler. If the current limiting resistor performs at the optocoupler’s minimum value, the phototransistor may behave irregularly. For example, out of 10 valid inputs from the switches, only part of it will be detected.

    On the other hand, the value of the limiting resistor should not be too low. This is to prevent the infrared LED from breaking down. Like regular LEDs, the infrared LED has a maximum forward current that should not be overshot. This makes choosing the right current limiting resistor a crucial step in ensuring a reliable optocoupler operation.

    Image of purple light
    As the name implies, enough current need is needed to light up the infrared LED

    3. Choosing The Wrong Optocoupler

    As general as it may seem, not all optocouplers are built the same. For example, the opto-triac is used for controlling an AC load and opto-Darlington is ideal for situations where only a small amount of input current is generated. Another consideration is the Collector-Emitter breakdown output voltage, which can vary for different models of optocouplers.

    But if you’re just using optocouplers for normal input isolation, models like PC817 will do the trick. You’ll also spend less time in creating footprints since the generic optocoupler components in the of your PCB design software will do the trick.

    Speaking of PCB design software, Altium’s CircuitStudio® and Altium Designer® are a great place to get started!

    Have a question about optocouplers? Contact an expert at Altium.

    Check out Altium in action...

    Powerful PCB Design

    most recent articles

    Back to Home