Reader small image

You're reading from  Architecting High-Performance Embedded Systems

Product typeBook
Published inFeb 2021
Reading LevelExpert
PublisherPackt
ISBN-139781789955965
Edition1st Edition
Languages
Right arrow
Author (1)
Jim Ledin
Jim Ledin
author image
Jim Ledin

Jim Ledin is the CEO of Ledin Engineering, Inc. Jim is an expert in embedded software and hardware design and testing. He is also an expert in system cybersecurity assessment and penetration testing. He has a B.S. degree in aerospace engineering from Iowa State University and an M.S. degree in electrical and computer engineering from the Georgia Institute of Technology. Jim is a registered professional electrical engineer in California, a Certified Information System Security Professional (CISSP), a Certified Ethical Hacker (CEH), and a Certified Penetration Tester (CPT).
Read more about Jim Ledin

Right arrow

Chapter 6: Designing Circuits with KiCad

This chapter introduces the excellent, open source KiCad electronics design and automation suite. Working in KiCad, you design a circuit using schematic diagrams and develop a corresponding printed circuit board layout. You'll learn how to turn a circuit board design into a prototype at a very reasonable cost. This chapter includes example schematics for the oscilloscope circuit project you will assemble in the next chapter.

After completing this chapter, you will have downloaded and installed KiCad, learned how to create circuit schematics in KiCad, learned how to develop circuit board layouts in KiCad, and worked through portions of the circuit board design for the digital oscilloscope project.

We will cover the following topics in this chapter: 

  • Introducing KiCad
  • Basic KiCad procedures
  • Developing the project schematic diagram
  • Laying out the Printed Circuit Board (PCB)
  • Prototyping the circuit board
  • ...

Technical requirements

Files for this chapter are available at https://github.com/PacktPublishing/Architecting-High-Performance-Embedded-Systems.

KiCad is available to download for free at https://kicad-pcb.org/download/. Several operating systems are supported, so be sure to select the correct distribution when you begin the download. When the download has completed, run the installer and accept the defaults at the prompts.

Introducing KiCad

The KiCad suite installs a set of applications that perform the following functions:

  • Schematic entry: Schematic entry is the process of describing an electrical circuit using a diagram that shows the circuit components and the connections between them. In KiCad, you select from a palette-based set of tools to choose electrical components, arrange them on the drawing canvas, and connect them together with lines that represent wires.
  • Component definition: KiCad includes a large set of definitions for common electrical components. Additional libraries are available for free from a variety of online sources. Despite the availability of a large set of predefined devices, you will occasionally need to define a component that isn't in the library. KiCad provides tools to describe the electrical connections of a device in terms of pins and their functions, and to define a footprint for the device. The footprint of an electrical component describes the connections...

Basic KiCad procedures

After installing KiCad, you will find a KiCad icon on your Windows desktop. Double-click the KiCad icon to start the KiCad project management window. This window will appear as shown in Figure 6.3:

Figure 6.3 – KiCad project manager window

On the File menu, select New | Project… to create a project. You will be prompted to select a filename and directory location for the project. To begin designing the circuit board for the oscilloscope project we began in Chapter 5, Implementing Systems with FPGAs, select the C:\Projects\oscilloscope-circuit directory and enter oscilloscope as the file name. This will create the schematic and PCB files as shown in Figure 6.4:

Figure 6.4 – Oscilloscope KiCad project files

As the names suggest, the .pcb file name extension contains the PCB description and the .sch file name extension contains the schematic.

In the next section, we will begin developing a...

Developing the project schematic diagram

The entire circuit diagram for the oscilloscope project is organized into six hierarchical KiCad sheets as shown in the following figure:

Figure 6.15 – Project schematic sheets

The contents of each sheet are as follows:

  • Analog Inputs: This portion of the circuitry receives an analog input from a standard oscilloscope probe in the range ±10 V and transforms it into a differential signal in the range ±1.0 V for input to the ADC.
  • ADC: This portion of the circuit connects the ±1.0 V analog signal to the ADC input pins. This diagram also connects a 100 MHz digital clock signal from the Arty board to the ADC. The ADC provides high-speed LVDS differential outputs for two lanes (OUT1A and OUT1B) as well as a data clock (DCO) that connect to Arty board inputs. The ADC used in the project is the Linear Technology LTC2267-14, a dual-channel 14-bit ADC capable of 105 million samples per second...

Laying out the PCB

Once we have a completed, rules-checked schematic diagram, the next step is to begin PCB layout. Before laying out the circuit board itself, we must first assign footprints to each of the circuit components. KiCad maintains schematic symbols and device PCB footprints as separate entities, allowing the user to associate the correct footprint with each device.

We will continue the schematic diagram containing the +1.8V power supply and the GDT we created earlier in this chapter. Click the Assign PCB footprints to schematic symbols icon, which is just to the right of the electrical rules check icon. This will open the Assign Footprints dialog and list the components in the circuit as shown in the following figure:

Figure 6.19 – Footprint assignment dialog

Of the four components in our circuit, only one, the TLV757 voltage regulator, already has a footprint assigned. Perform the following steps to assign the remaining components...

Prototyping the circuit board

A number of low-cost PCB prototype board vendors offer services to hobbyists and other small-scale clients. Some vendors require a set of Gerber files in industry-standard formats for production. Others will directly accept a KiCad project as their input, which saves some minor steps.

In this example, we will use OSH Park as the vendor. You can place orders with OSH Park at https://oshpark.com/. OSH Park produces prototype PCBs in a distinctive purple color directly from KiCad project files. The following figure shows the board top for the fifth revision of the oscilloscope project PCB:

Figure 6.27 – OSH Park PCB rendering for the oscilloscope project

At the time of this writing, OSH Park charges $10.00 per square inch to produce three copies of a four-layer PCB. Since our board is 2.5" x 2.5", the cost for three boards is $62.50 plus sales tax, and comes with a free shipping option.

When ordering a...

Summary

This chapter introduced the open source KiCad electronics design and automation suite and provided some examples of its use. You learned how to turn your circuit board design into a PCB prototype at a very reasonable cost. The chapter included examples of schematic entry and PCB layout for the oscilloscope project you will assemble in the next chapter.

After completing this chapter, you have downloaded and installed KiCad, learned basic procedures in KiCad, learned how to create circuit schematics in KiCad, learned how to develop circuit board layouts in KiCad, and worked through a portion of the circuit board design example for the digital oscilloscope project.

The next chapter will introduce the equipment and techniques involved in assembling high-performance digital devices using surface-mount and through-hole electronic components.

lock icon
The rest of the chapter is locked
You have been reading a chapter from
Architecting High-Performance Embedded Systems
Published in: Feb 2021Publisher: PacktISBN-13: 9781789955965
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
undefined
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime

Author (1)

author image
Jim Ledin

Jim Ledin is the CEO of Ledin Engineering, Inc. Jim is an expert in embedded software and hardware design and testing. He is also an expert in system cybersecurity assessment and penetration testing. He has a B.S. degree in aerospace engineering from Iowa State University and an M.S. degree in electrical and computer engineering from the Georgia Institute of Technology. Jim is a registered professional electrical engineer in California, a Certified Information System Security Professional (CISSP), a Certified Ethical Hacker (CEH), and a Certified Penetration Tester (CPT).
Read more about Jim Ledin