## WEEK 7

Assignment :

Redraw the echo hello-world board, add (at least) a button and LED (with current-limiting resistor), check the design rules, make it (if you have time this week, test it).

## Introduction

A piece of circute execute tasks depending on your command is an interesting phenomenon. I have been facinated about Microcontrollers and electronic circuites from my early ages onwards. But i only got an opertunitys to understand and work on these devices in my last years of college only .Though i have worked on some developmet boards like arduino, raspberry pi, nodemcu, esp8266 etc. i never attempted to develop a board from scratch before. So i decided to exploite this opertunity to learn PCB designing. Eventhough designing a pcb is somuch irritating in the begining some how i am learning to enjoy this pain.

### designing

The fastest way of trying out a circuit is using some jumper wires and a breadboard. But there are some serious issues with breadboade as the number and size of the components increases.

• It will became incredibly complicate to understand and interconnect
• The contacts may loose and create random errors
• Bread boards cannot be integrated in to a product
• it is bulkier
Due to these issues we are forced to relay on a much stabel and reliable approch "the PCB". The designing of a PCB is a hard process. As the number of components increaces it will became exponentialy complicated .So we need to relay on some smarttools to handle this problem basically some softwares. Talking about PCB designing softwares there are a lots of big companeys in the market.
• The australian giant altium
• eagle which is currently owned by autodesk is also a free to use well performing PCB designing software.

### Some basics

#### Pull-up resistors:-

Pull-up resistors are resistors which are used to ensure that a wire is pulled to a high logical level in the absence of an input signal. Pull-up resistors are not a special kind of resistors; they are simple fixed-value resistors connected between the voltage supply (usually +5V) and the appropriate pin, which results in defining the input or output voltage in the absence of a driving signal.

#### Pull-down resistors:-

Pull-down resistors work in the same manner as pull-up resistors, except that they pull the pin to a logical low value. They are connected between ground and the appropriate pin on a device.

#### Resistor value

The appropriate value for the pull-up resistor is limited by two factors. The first factor is power dissipation. If the resistance value is too low, a high current will flow through the pull-up resistor, heating the device and using up an unnecessary amount of power when the switch is closed. This condition is called a strong pull-up and is avoided when low power consumption is a requirement. The second factor is the pin voltage when the switch is open. If the pull-up resistance value is too high, combined with a large leakage current of the input pin, the input voltage can become insufficient when the switch is open. This condition is called having a weak pull-up. The actual value of the pull-up’s resistance depends on the impedance of the input pin, which is closely related to the pin’s leakage current. However the resistance value for Attiny 44 is specified in its data sheet as 10KOhm to 20kOhm, We have opted 10kohm resistor for the pull-up.(thank you my friend lancy for this valuable informations.)

#### LED series Resistor value

A light-emitting diode (LED) is a two-lead semiconductor light source. It is a p–n junction diode that emits light when activated.If we apply a current that is greater than the desired value of an led the junction temperature will increace because Heat = I^2 x R x t ,(I = current through Led,R = Resistance of conductor,t = time ) .So if the junction temperature increas it may lead to the fast deterioration of the juction or complete breakdown of the device so it is importent to maintain the current through the led . the easiest and simplest way is to use a series resistor.

The formula to calculate the correct resistance to use is R=(Vs-Vf)/I

where Vs is the power supply voltage, e.g. a 9-volt battery; Vf is the LED forward voltage (also referred to as the "voltage drop") across the LED; and I is the desired current of the LED

This is the typical I-V characteristics of an led with respect to different colours

From the above table the maximum peak current for an lED is 30 mA and maximum Continuous current is 20 mA. So we have to set the LED current to a lower value as prefered in the table we can choose a value in between 16-18 mA

from the above graph find the voltage required at the given current lets say the current choosen is 20 mA and led is Red then find projecton of 20mA point from the red curve it will be arround 1.8V .The below table shows all the voltages of different LEDs at 20 mA

So let as coose 1.8v and 18 mA As the operating condition of our LED

The above figure is a typical led connection where .Rs is the Series resistance ,Vs is the source voltage,Vf is the forward voltage of the LED(also referred to as the "voltage drop") ,If is the safe current through the LED

So we have

Vs = supply voltage =5v

Vf = 1.8V

If = 18mA

So Rs = (5 - 1.8)/(.018) = 177.77

The closest resistor having a greator value than this in our lab is 499 ohm . i hope may be this work with a reduced brightnes.

### Eagle

EAGLE is a scriptable electronic design automation (EDA) application with schematic capture, printed circuit board (PCB) layout, auto-router and computer-aided manufacturing (CAM) features. EAGLE stands for Easily Applicable Graphical Layout Editor and is developed by CadSoft Computer GmbH. The company was acquired by Autodesk Inc. in 2016.[\wiki]

Eagle is the most preferable because a lot of opensource projects are available in eagle .It is easy to use easly understandable and have a well back of active users .also it is free for hobbie projects and students.

### Starting with eagle

To start redrawing the board, I used this tutorial First thing to do is install Eagle, after that, set it up. Once Eagle is installed, download the Fab library that provides you with all the components you need for this board. It can be downloaded here.

### Drawing a Schmatic

• Next open eagle.
• Create a new folder for your project it will later help you to organize all of your documents related to a project.to create a new folder right click and select New Folder.I decider to add my fab projects in this folder so i named it fablab.
• Next Create a new project. To do this right click on your folder and select new project
• To create a new schematic rigth click inthe project select new -> schematics

Now we are directed to a new schematic window. To add our fab library

• Extract and copy the fab.lbr file to the eagle library folder
• Select library inthe menue bar -> open Library
• select the fab.lbr file we pasted before

Then we can see all the components and its details in the added Library

To add a new component to the schematic Select the add icon in the tool bar and choose the fab library

Remark! Some times though we added our library to the eagle library we may not see it in the add components it may be due to it is disabled

To change it go to the main window look under librarys -> right click on the desired library and select -> select "use all" .this will enable our library by showing a green dot

• We can rotate the componets by clicking the right button of mouse by holding the left button down
• press esc key to end current tool

• To move the componets drag holding a cross mark in the components
• We can use the net tool to inter connect components
• Name multiple net component with same name to interconnect them with out disturbing our view

To name a component

• Right click on the component and choose name
• Choose an appropriate name

we an access the same tool using multiple ways but i fund right clicking and choosing the tool is easier for me.

If you have allredy used that name for another component eagle will ask you to connect it with the other one.

Innorder to display the name on the schematics right click on the component and choose label.

You can add values to components by rigth click and choosing value .Then choose an appropriate value for the component

### Switching to Board

To switch to board choose File -> Switch to board

Using the move tool aline the board with the desired board area

Befor autorouting we have to set our design rools.Set all the clearences to 16 mill this is bacause we are using 16 mills milling bit if you are using another bit you have to vary this.

Under Distance change "drill hole" and "Copper/dimension" sze to 16 mills.

Under Size change "maximum width" to 16 mills.

After rearranging the components in a decent fasion Refer to pcb design principles

• Go for autorouting (Tools ->Autorouter)
• Disable the bottom layer
• i choose effort high to get maximum possible attenmts
• Proced with "continue"

• Each item in the list is an indipendent attempt
• We can try each one using the evaluate tool
• After evaluation select the most confident one and choose end job
• If you are not satisfied with the percentage of completion re arrange the components and try again

after completing auto routing we need to check which all components are not connected
• choose tools-> DRC
• Select check

It will list all design problems associated with the board

Innorder to highlight the unrouted components
• go to View -> layer settings
• Choose "select none"
• Select the 19th layer (unrouted)

this will highlight all unrouted lines with an yellow line .tou have to join it manually.

Remark! If it seems impossible to connect with out jumpers choose a 0 ohm resistor to jump over wires .But in eagle we can't add components in board so you have to go back to schmatic and add component in the appropriate place and grt back to the board.After some rearrangements its done .

Draw a boundary box arround the PCB or uoy can import a drawing drawn in a cad software in to the board also . you have to place the boundry in a different layer .To do that select the boundry , right click on it and choose properties. Under properties change the layer of the component.

Before exporting the image to a png go to layer settings and select the top layer alone.

To export

• go to file ->Export ->Image.
• Browse the location to save and choose name
• Selet a higher resolution(i choose 1500)
• Choose monochrome and select okey
• Repeat it for the boundry layer also.

These are my final results also to know how to make PCB using Modella MDX 20 Go through my week 5 assignment

Trace file

Cut File

Eagle Files -Schematic

Eagle Files -Board

## Group Project

### Pocket Multimeter PM55A

The Amprobe PM55A is the ultimate pocket-sized multimeter. Only 3/8" thick and less than 3 oz in weight with full functionality offering AC and DC voltage measurement to 600 V, AC and DC current to 2000 μA, resistance to 6 Megohm, capacitance to 2000 μF, frequency to 30 kHz, diode test and continuity with beeper. It also offers VolTect™, a built-in, non-contact voltage detection feature for AC voltages. Another key feature of this pocket multimeter is AutoTect, which automatically selects between AC and DC voltage, or resistance measurement based on the test point to which the leads are connected. Fully auto ranging, this meter offers nine different measurement functions plus features that are usually found in much more expensive and larger meters. I used PM55A to test the continuity of my circuit board and also for checking wether power supply is available at all desired points

### Instek GPD-3303D

The Instek GPD-3303D 3-Channel Programmable Linear DC Power Supply, 195W, 100mV/10mA .

• Tracking Series and Parallel Function
Tracking series and parallel function allows you to use the GPD-3303D in a wide range of applications. The tracking series mode guarantees higher output voltage, while the tracking parallel mode guarantees higher output current.
• Convenience Functions
The GPD3303D knobs are digitally controlled, allowing for fine or coarse volume settings. The key lock feature locks panel operations, preventing accidental settings changes, which might damage the equipment.
• 4 Sets of Save/Recall
The GPD-3303D can save and recall panel settings; quickly select a panel setting from the four memory sets without the need for manual configuration.
• USB Remote Control
The USB device port in the GPD3303D allows you to remotely control the power supply according to your application needs.

I used GPD-3303D to power my PCB and Checked wether my LED connections are correct

Remark! Though we changed the voltage and current we have to press the output button to get the output in terminals.

### UniSource DS-1100 100 MHz, 2 Ch, Digital Storage Oscilloscope

When we are dealing with timing and signal shapes a simple multimeter became insufficent. We need to have something more to visualize and compare the signal. A digital storage oscilloscope is an apt choise for this.The DSO in our lap has the following capabilities.

• 100 MHz bandwidth, 1 M Memory
• High resolution color LCD display
• USB storage, RS232C & J45 interface
• 4000 point record length for each channel
• Multi-waveforms math, FFT Function
• Built-in delay sweep function
• Automatic Multi-waveform Measurement
• Cursor & Track measurement
• Waveform Record & Recall, Trigger Mode for Edge, Video, Pulse Width, Slope & Alternate
• Display of date, clock and help information
• Also available in 60 MHz DS-1065, 100 MHz DS-1200

### AFG-2100/2000 Series Arbitrary Function Generator

The AFG-2100/2000 Series Arbitrary Function Generator is a DDS (Direct Digital Synthesized) based signal generato.It can generate output of Sine, Square (Pulse), Ramp (Triangle), Noise and Arbitrary waveforms. It provides 20M Sa/s sampling rate, 10 bit vertical resolution and 4k point memory .Also it can generate 0.1Hz resolution of Sine, Square and Triangle waveforms and the 1% ~ 99% adjustable duty cycle of Square (Pulse) waveform

We connected the out put of the function generator to the DSO and observed the variation of signal with change in different parameters. here also we have to press the output buttion to get the output signal.