© Harold Timmis 2021
H. TimmisPractical Arduino Engineeringhttps://doi.org/10.1007/978-1-4842-6852-0_5

5. PCB Design

Harold Timmis1  
(1)
Jacksonville, FL, USA
 

Now that we have taken some time to learn about Fusion 360 and Simplify3D, we need to focus on the electrical aspects of this book. First, we will investigate what a PCB is and briefly describe how it is designed. Then I want to go over PCB Design software that will be used to create PCBs in this book. After that, we will have an in-depth discussion on Eagle and how to make your first PCB, as well as how to load libraries into Eagle. Then we will learn how to export the Gerber files for the final board. Finally, we will review how to get this board manufactured using PCBWay. There is a lot to cover just like the previous chapters, so let’s get started.

What Is a PCB

PCB stands for Printed Circuit Board; PCBs are created using PCB Design software. The design software will have both a schematic section and a board section. The schematic section will have a diagram like reference to all connections such as: integrated circuit (IC), passive electrical component, and so on. The board section will have the component layout, wiring, drills, and so on that are needed to create the actual board. Once both sections are completed, the board file will be compiled into a Gerber file which will hold all the information that the PCB manufacturer needs to create the PCB. All of these will be explained in detail in this chapter. Figure 5-1 illustrates some examples of PCBs manufactured by PCBWay.
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig1_HTML.jpg
Figure 5-1

Examples of PCB boards including an Arduino board, battery tester (courtesy of David Segal and Chris Defant), H-bridge, rotary encoder breakout

PCB Design Software

There are a lot of PCB Design software on the market, such as Altium, KiCAD, and what this book will utilize: Eagle. PCB Design software allows you to create schematics and board layouts. These can then be converted into Gerber files which will then be sent to the board manufacturer. There is a lot to learn with PCB Design software; this chapter will give you a good glimpse and get you ready for the next chapters that will have several board designs.

Eagle

Eagle has a monthly subscription program, so if you only want to use it for this book, you can purchase a monthly license for 15 USD. Eagle is a professional PCB software that can even link to Fusion 360, so you can make sure a PCB fits in its enclosure. It also allows you to connect to various component libraries, so you do have to create every component your board needs. So, let’s get started with Eagle.

Eagle’s Main Windows

Did I say windows? Yes, Eagle has two main windows that you will be using to create PCBs. The first window we will talk about allows you to create a schematic of the PCB. A schematic is a drawing of all the ICs, resistors, capacitors, headers, and their connections; these connections are called nets. The second window we will discuss focuses on the physical layout of the board; this is important because it will become the Gerber files you send off to the PCB manufacturer.

Schematic Window

As stated earlier, the schematic window will allow you to create a logical diagram of your circuit. This will also connect all the various components using nets that will then become routes when you switch over to the Board Layout window. Let’s look at the schematic window and its various menus and controls. See Figure 5-2.
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig2_HTML.jpg
Figure 5-2

Schematic window

  1. 1.
    Action bar: This bar has a couple of important buttons on it. They are
    1. a.

      Open/Save/Print: This is where you can save your progress.

       
    2. b.

      Schematic/Board: This button allows you to toggle between the board window and the schematic window.

       
     
  2. 2.
    Parameters bar: This bar holds all the functions for: control grid settings and layer control.
    1. a.

      Layer settings: Allows you to show or hide layers (most of the time, this is used in the board window).

       
    2. b.

      Grid: Allows you to change the resolution of the grid and change the units of measurement.

       
    3. c.

      Layer selection box: Select which layer to edit. Normally set to “Nets” for the schematic window.

       
     
  3. 3.
    Command buttons bar: I will not spend too much time here listing all of the commands (there are a ton), but instead will show you these as we create PCBs throughout the book, but here are a few very common commands:
    1. a.

      Info: Allows you to check various properties of a component.

       
    2. b.

      Add Part: Allows you to select the component you want to add to the schematic window.

       
    3. c.

      Delete: Deletes a component from the schematic window and the board window.

       
    4. d.

      Show: Select a net with this option selected, and all nets with that name will be highlighted.

       
    5. e.

      Group: Use this function to select multiple objects.

       
    6. f.

      Net: Nets are used to connect your circuit together; we will be using this function a lot in the coming projects.

       
     
  4. 4.

    Command texts bar: In this text box, you can type out commands to quickly move through schematic development. These are typically used when you get a bit more experience in Eagle. If you want to see a list of the commands, go here: http://web.mit.edu/xavid/arch/i386_rhel4/help/24.htm.

     
  5. 5.

    Simulation bar: This bar allows you to evaluate your circuit to make sure it will work as expected.

     

Board Window

The board window is where you will create the layout of the board with the various layers and routes. Also, you will add any holes or special features that your board may need. See Figure 5-3.
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig3_HTML.jpg
Figure 5-3

Board window

  1. 1.
    Actions bar: This bar is just like the one found on the schematics window but has one function I want to mention.
    1. a.

      CAM Processor: This is the function that will be used to create the final Gerber file that will be sent to the board manufacturer.

       
     
  2. 2.

    Parameters bar: See the “Schematic Window” section.

     
  3. 3.
    Command buttons: Several of the command buttons are the same, but there are a few that differ.
    1. a.

      Route Airwire: These are used to physically connect the circuit from the schematic view together.

       
    2. b.

      Ripup: This will not delete nets; that is to say, this will not remove the connection from component to component; it will just delete the routing of the net and leave a yellow line where the two components terminate.

       
     
  4. 4.

    Command texts bar: See the “Schematic Window” section.

     

Alright, now that we know about the layout of the two main windows in Eagle, we can start to discuss how to add libraries that have already been created to Eagle.

Loading a Library

Now another essential thing you need to know how to do is to have the ability to add libraries to Eagle. This is important because sometimes the components that come with Eagle are not enough, so you have two options: find a library that has the component and add it to Eagle or create the part yourself.
  1. 1.

    Open Eagle. See Figure 5-4.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig4_HTML.jpg
Figure 5-4

Open Eagle

  1. 2.

    Open a new File Explorer and navigate to “My Documents.”

     
  2. 3.

    Create a new folder called “Extra Libraries.” See Figure 5-5.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig5_HTML.jpg
Figure 5-5

Create the Extra Libraries folder

../images/271483_2_En_5_Chapter/271483_2_En_5_Fig6_HTML.jpg
Figure 5-6

Go to the URL

  1. 5.

    Download the SparkFun Eagle library. See Figure 5-7.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig7_HTML.jpg
Figure 5-7

Download the SparkFun Eagle library

  1. 6.

    Unzip and put the folder “SparkFun-Eagle-Libraries-master” into the “Extra Libraries” folder. See Figure 5-8.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig8_HTML.jpg
Figure 5-8

Copy to the Extra Libraries folder

  1. 7.

    Go to Eagle and select Options ➤ Directories, and the Directories window will appear. See Figure 5-9.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig9_HTML.jpg
Figure 5-9

Open Directories

  1. 8.

    Copy the link address from your File Explorer to the Libraries text box in the Directories window. Remember to add the “;” after the “$HOMEEAGLElibraries”. See Figure 5-10.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig10_HTML.jpg
Figure 5-10

Copy Libraries directory

  1. 9.

    Click the “OK” button on the Directories window. See Figure 5-11.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig11_HTML.jpg
Figure 5-11

Paste directory

  1. 10.

    On the front screen of Eagle, go to the Libraries drop-down and click the arrow. See Figure 5-12.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig12_HTML.jpg
Figure 5-12

Shows the SparkFun Eagle library loaded

  1. 11.

    You should now see the SparkFun library. Right-click it and click “Use all.” One thing to note is that you will need to select “Use all” on each library when you want to use this for each project. See Figure 5-13.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig13_HTML.jpg
Figure 5-13

Select “Use all”

  1. 12.

    The library has now been added and is ready to use.

     

Alright! Now that we know how to add libraries to Eagle, we can start to create schematics and layouts, but first I would recommend adding the Adafruit library to Eagle. The link for which can be found here: https://github.com/adafruit/Adafruit-Eagle-Library.

Creating a Schematic

Finally, we are ready to start creating schematics and board layouts. We will start with the schematic. What we will be making is an LED board with a push button and a terminal block for easy connection to a power supply. So, let’s get started.
  1. 1.

    Open Eagle. See Figure 5-14.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig14_HTML.jpg
Figure 5-14

Open Eagle

  1. 2.

    Go to the Libraries drop-down and right-click the SparkFun library we added in the previous section and click “Use all.” See Figure 5-15.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig15_HTML.jpg
Figure 5-15

Select “Use all”

  1. 3.

    Select File ➤ New ➤ Schematic; this will open a schematic window. See Figure 5-16.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig16_HTML.jpg
Figure 5-16

Create a new schematic

  1. 4.

    Press Ctrl-S and save this schematic as LED_Board. See Figure 5-17.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig17_HTML.jpg
Figure 5-17

Save the new schematic

  1. 5.

    Click the Add Part button, and the ADD window will appear. See Figure 5-18.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig18_HTML.jpg
Figure 5-18

ADD window

  1. 6.

    Scroll down to the SparkFun-PowerSymbols selection. Then double-click the “5V” text. See Figure 5-19.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig19_HTML.jpg
Figure 5-19

Select 5V symbol

  1. 7.

    Add two of the “5V” symbol onto the schematic window by left-clicking the screen. See Figure 5-20.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig20_HTML.jpg
Figure 5-20

Add 5V symbols to the schematic window

  1. 8.

    Pressing escape will bring you back to the ADD window where you can double-click GND. See Figure 5-21.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig21_HTML.jpg
Figure 5-21

Select GND symbol

  1. 9.

    Add two “GND” symbols to the schematic window, just as you did with the “5V” symbol. See Figure 5-22.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig22_HTML.jpg
Figure 5-22

Add GND symbols to the schematic window

  1. 10.

    Press escape again, which will open the ADD window again. See Figure 5-23.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig23_HTML.jpg
Figure 5-23

Go to the ADD window again

  1. 11.

    In the search bar, type in “LED” and press enter. See Figure 5-24.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig24_HTML.jpg
Figure 5-24

Search for LED

  1. 12.

    Scroll down to the SparkFun-LED ➤ LED drop-down and double-click the “LED3MM.” See Figure 5-25.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig25_HTML.jpg
Figure 5-25

Select LED3MM

  1. 13.

    Now if you right-click, you will notice that the LED symbol will turn 90 degrees. Do this once. See Figure 5-26.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig26_HTML.jpg
Figure 5-26

Add LED3MM symbol to the schematic window

  1. 14.

    Press escape again (or click the “ADD” button). In the search bar, type in “button” and press enter. See Figure 5-27.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig27_HTML.jpg
Figure 5-27

Search for button

  1. 15.

    Scroll down to SparkFun-Switches and locate MOMENTARY-SWITCH-SPST. Then locate MOMENTARY-SWITCH-SPST-SMD-4.5MM and double-click it. See Figure 5-28.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig28_HTML.jpg
Figure 5-28

Select the Momentary button

  1. 16.

    Right-click three times on the schematic window to orient the switch correctly and then place the switch symbol. See Figure 5-29.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig29_HTML.jpg
Figure 5-29

Add the Momentary button to the schematic window

  1. 17.

    Click the Info button and then click the switch you just placed. The info dialog window will open. See Figure 5-30.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig30_HTML.jpg
Figure 5-30

Update the value of the button

  1. 18.

    If the Properties window you are seeing is not correct, try right-clicking the switch near the “+” symbol; you should see this menu. Make sure you try and right-click the bottommost “+” symbol. See Figure 5-31.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig31_HTML.jpg
Figure 5-31

Right-click the “+” next to the button’s name

  1. 19.

    The Properties menu should have the value of “VALUE.” See Figure 5-32.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig32_HTML.jpg
Figure 5-32

When the proper area of the button is selected, the name will be “VALUE”

  1. 20.

    Select the “Display” drop-down menu and select “off.” See Figure 5-33.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig33_HTML.jpg
Figure 5-33

Select “off”

  1. 21.

    Click the ADD button again. See Figure 5-34.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig34_HTML.jpg
Figure 5-34

ADD window

  1. 22.

    In the search bar, type in “connector” and press enter. See Figure 5-35.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig35_HTML.jpg
Figure 5-35

Search connector

  1. 23.

    Scroll to the SparkFun-Connectors drop-down; then select the CONN-02 drop-down. See Figure 5-36.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig36_HTML.jpg
Figure 5-36

Select the 5mm terminal block

  1. 24.

    Double-click the “CONN_025MM” and add it to the schematic window. See Figure 5-37.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig37_HTML.jpg
Figure 5-37

Add the 5mm terminal block to the schematic window

  1. 25.

    Click the ADD button again and type in resistor into the search box and press enter. See Figure 5-38.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig38_HTML.jpg
Figure 5-38

Search resistor

  1. 26.

    Go to Resistor ➤ R-US ➤ R-US_R0805 and add it to the schematic window. See Figure 5-39.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig39_HTML.jpg
Figure 5-39

Select the R0805 resistor

  1. 27.

    Press escape and click the cancel button. See Figure 5-40.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig40_HTML.jpg
Figure 5-40

Get out of the ADD window

  1. 28.

    Click the “Move” button and configure the symbols like Figure 5-41. Rotate any symbols as needed by selecting the symbol and using a right mouse click.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig41_HTML.jpg
Figure 5-41

Configure the symbols in these orientations

  1. 29.

    Click the “Net” button; we are now in the phase where we will be connecting the various components together. Pay special attention to each of these connections as an incorrect connection here means an incorrect connection on the board layout, which can cause serious problems with your board. See Figure 5-42.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig42_HTML.jpg
Figure 5-42

Click the “Net” button

  1. 30.

    Connect 5V to the 5mm terminal block. See Figure 5-43.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig43_HTML.jpg
Figure 5-43

Connect the 5V net to the terminal block

  1. 31.

    If you want your schematic to look just like Figure 5-43, you can cycle through the different directions of net shapes by right-clicking while the net button is active.

     
  2. 32.

    Connect 5V to the left side of the switch symbol. See Figure 5-44.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig44_HTML.jpg
Figure 5-44

Connect 5V to the right side of S1

  1. 33.

    Connect the right side of the switch symbol to the left side of the resistor. See Figure 5-45.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig45_HTML.jpg
Figure 5-45

Connect the left side of S1 to the right side of R1

  1. 34.

    Connect the right side of the resistor symbol to the anode (left side) of the LED symbol. See Figure 5-46.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig46_HTML.jpg
Figure 5-46

Connect the left side of R1 to the right side of D1

  1. 35.

    Connect the GND symbol to the 5mm terminal block. See Figure 5-47.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig47_HTML.jpg
Figure 5-47

Connect GND to the terminal block

  1. 36.

    Connect the GND symbol to the cathode (right side) of the LED. See Figure 5-48.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig48_HTML.jpg
Figure 5-48

Connect the left side of D1 to GND

  1. 37.

    In order to add a value to the resistor, right-click the “+” on the resistor and select “Value” on the pop-up menu. Then enter “330ohm” and click “OK.” See Figure 5-49.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig49_HTML.jpg
Figure 5-49

Set the value of R1

  1. 38.

    The schematic is now done, but in order to create a board file for the next section, we need to click the “Generate/Switch to Board” button. A dialog will come up asking you if you would like to create a board file; click the “Yes” button. See Figure 5-50.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig50_HTML.jpg
Figure 5-50

Create a *.brd file

  1. 39.

    This file will automatically be saved as LED_Board.brd. See Figure 5-51.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig51_HTML.jpg
Figure 5-51

Board window for LED_Board

Now that the schematic is done and we have a board file, we can focus on the board layout for this project, which is what the next section will cover.

Laying Out a PCB

We have a schematic, but we still need to create a board layout so that a Gerber file can be created and sent off to the board manufacturer. This section will cover several important functions. It is alright if you must do these steps a few times before you get the hang of it; try to follow the layout as best you can.
  1. 1.

    Go to the Board Layout window if you are already not there. See Figure 5-52.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig52_HTML.jpg
Figure 5-52

Board window

  1. 2.

    Click the Grid button and make sure it looks like Figure 5-53.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig53_HTML.jpg
Figure 5-53

Make sure the grid is the same

  1. 3.

    Once the Board Layout window is open, click the “Info” button. See Figure 5-54.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig54_HTML.jpg
Figure 5-54

Select the “Info” button

  1. 4.

    Click the left vertical line, and a menu should appear. See Figure 5-55.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig55_HTML.jpg
Figure 5-55

Select the left vertical line

  1. 5.

    In the second text box next to “From,” type in 542 (if this value makes your board huge, please make sure you change your “Grid” to “mil”) and click “OK.” See Figure 5-56.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig56_HTML.jpg
Figure 5-56

Update vertical line value

  1. 6.

    Now click the bottom horizontal line, and the same box should appear. See Figure 5-57.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig57_HTML.jpg
Figure 5-57

Select bottom horizontal line

  1. 7.

    Type 1294 into the box right next to the “to” and click “OK.” See Figure 5-58.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig58_HTML.jpg
Figure 5-58

Update horizontal line value

  1. 8.

    Now click the top horizontal line (or what would be horizontal had we not updated the other lines). See Figure 5-59.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig59_HTML.jpg
Figure 5-59

Select top horizontal line

  1. 9.

    Type 1294 into the box right next to “From” and click “OK.” See Figure 5-60.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig60_HTML.jpg
Figure 5-60

Update top horizontal line value

  1. 10.

    Click the right-side vertical line. See Figure 5-61.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig61_HTML.jpg
Figure 5-61

Select right vertical line

  1. 11.

    Type 542 into the second box next to “To,” and you now have the dimensions for the PCB. See Figure 5-62.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig62_HTML.jpg
Figure 5-62

Update right vertical line value

  1. 12.

    Click the “Move” button and select the terminal block. See Figure 5-63.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig63_HTML.jpg
Figure 5-63

Select the “Move” button

  1. 13.

    Rotate the terminal block and move it onto the PCB. You can use the “Info” button and type in the position “155” and “365,” or you can move it with the mouse and hold the Alt Key to get more precision. See Figure 5-64.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig64_HTML.jpg
Figure 5-64

Move terminal block

  1. 14.

    Next, move the push button onto the PCB. Pay attention to the yellow lines going from one component to the next. These lines are the nets you created in the schematic. The position for the button should be “540” and “265.” See Figure 5-65.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig65_HTML.jpg
Figure 5-65

Move button

  1. 15.

    You may notice that the push button’s device name is very long and not necessary to put on the PCB. If you zoom in to the PCB and right-click the “+” right next to the name, you can select “Delete,” and this will remove the name from the PCB. See Figure 5-66.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig66_HTML.jpg
Figure 5-66

Delete button name value

  1. 16.

    Now add the resistor to the PCB, positioned at “860” and “270.” See Figure 5-67.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig67_HTML.jpg
Figure 5-67

Move resistor

  1. 17.

    Now add the LED to the PCB, positioned at “1135” and “280.” You have now finished arranging the parts onto the PCB. See Figure 5-68.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig68_HTML.jpg
Figure 5-68

Move LED

  1. 18.

    Select the “Route Airwire” button. See Figure 5-69.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig69_HTML.jpg
Figure 5-69

Select the Route Airwire button

  1. 19.

    At the top, select 12 from the “Width:” drop-down menu, or you can just enter “12.” See Figure 5-70.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig70_HTML.jpg
Figure 5-70

Select 12mil route

  1. 20.

    Left-click the 5V contact on the terminal block (J1), then move your mouse over to the top-left contact of the push button (S1), and left-click that contact. See Figure 5-71.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig71_HTML.jpg
Figure 5-71

Connect terminal block to 5V

  1. 21.

    Left-click from the 5V contact on the push button (S1) and drag your mouse to connect the route to the other 5V contact on the push button (S1). See Figure 5-72.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig72_HTML.jpg
Figure 5-72

Connect 5V lines

  1. 22.

    Left-click the top-right contact on the push button and connect it to the left contact of the resistor (R1). See Figure 5-73.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig73_HTML.jpg
Figure 5-73

Connect button to resistor

  1. 23.

    Left-click the top-right contact on the push button again and connect it to the right-bottom contact “N$1.” See Figure 5-74.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig74_HTML.jpg
Figure 5-74

Connect buttons right side

  1. 24.

    Next, left-click the right contact of the resistor and connect the other end to the top contact of the LED (D1). See Figure 5-75.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig75_HTML.jpg
Figure 5-75

Connect resistor to LED

  1. 25.

    To select the bottom layer, go to the top and change the “Layer:” drop-down to “16 Bottom.” See Figure 5-76.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig76_HTML.jpg
Figure 5-76

Select the bottom layer

  1. 26.

    Select the bottom contact on the terminal block (J1) and connect the other end to the bottom contact of the LED (D1). Because this is on the bottom layer of the board, you can pass right through top layer contacts and routes as long as the contacts are not on the bottom layer as well. A good example of this is that when you pass underneath an SMT (surface mount) part which is only on the top layer, but if there is a through-hole contact, you will have to go around that part. See Figure 5-77.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig77_HTML.jpg
Figure 5-77

Connect the terminal block to GND

  1. 27.

    The board is now ready to be made into a Gerber file. See Figure 5-78.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig78_HTML.jpg
Figure 5-78

Final board

Exporting Gerber Files

Creating a Gerber file is very simple in Eagle and is also a very important step as it is the file that you will eventually send to the board manufacturer.
  1. 1.

    Go to the Board Layout window for your project. See Figure 5-79.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig79_HTML.jpg
Figure 5-79

Final board

  1. 2.

    Go to File ➤ CAM Processor. Make sure your current project is saved. See Figure 5-80.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig80_HTML.jpg
Figure 5-80

Select CAM Processor…

  1. 3.

    At the top, you will see the “Job” file that is currently being utilized, “template_2_layer.cam.” This job will work for the current PCB we have created, but if we say had a four-layer board, this job would need to be modified to include those layers, as well as any other layers, such as soldermask or silkscreens those layers may also employ. See Figure 5-81.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig81_HTML.jpg
Figure 5-81

CAM Processor window with “Job” name highlighted

  1. 4.

    If you select the “Top Copper” layer, you will see a preview of that layer. Same thing goes for any of the other selections that the CAM Processor shows. See Figure 5-82.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig82_HTML.jpg
Figure 5-82

Preview of the Top Copper of the PCB

  1. 5.

    Click the “Process Job” button, and Gerber files will be generated after you select where you want them to be stored and what name you want to give them. See Figure 5-83.

     
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig83_HTML.jpg
Figure 5-83

Save Gerber files

  1. 6.

    When done, just exit out of the CAM Processor window and close out Eagle.

     

PCB Manufacturers

There is a plethora of board manufacturers in the United States and in China. I personally use PCBWay for both professional and personal projects, but there are 100s of board manufacturers ready to make your board. Figure 5-84 illustrates what I used to create this board.
../images/271483_2_En_5_Chapter/271483_2_En_5_Fig84_HTML.jpg
Figure 5-84

Common settings for board manufacturing

Summary

Well, you have made it through all of the first five chapters which I know contained a ton of information, and I am sure not all of it has been retained, which is fine because in the next five chapters we will be focusing on using and reinforcing these new skills to do some pretty cool project, but first let’s take a look at some of the highlights of this chapter:
  • Looked at what a PCB is and what kind of software is needed in order to make a PCB

  • Took a tour of Eagle and some of the most important functions

  • Learned how to load a third-party library into Eagle

  • Learned the basics on how to create a schematic

  • Learned the basics on how to create a board layout

  • Learned how to export Gerber files

  • Took a look at PCBWay as a board manufacturing company

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
44.222.242.27