Week 6 : Electronics Design

February 28 - March 7 2018



Things to do :

  • Group : use the test equipment in your lab to observe the operation of a microcontroller circuit board
  • 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).

PCB Design

For this week assignment I had to use Eagle.I never used Eagle before,so I started reading this tutorial.It has some broken links but it's very usefull.Thanks to my university's studies I already knew the behaviour of many components.The hardest part was learning the basics of Eagle.
I looked to the given design of the hello-board to recognize the components that I needed.



  • ATtiny44
  • J2 FTDI Serial Port
  • 20 Mhz Resonator
  • 10 KOhm Resistor
  • 10 uF Capacitor
  • 2x3 Header

At this point, I downloaded this eagle library wich contains all the components for the hello board and I started adding all the components listed above.



We had to add a LED and a BUTTON.
Remember : The installation of a led require a resistor in order to limit the current that flows in the diode (a led is a diode).You have to know the Kirkhoff and Ohm's laws to solve the problem or you can use this calculator.
I found that the value of the resistor to add were 75-80 ohm ,so I used a 100 ohm R.
For the button I used a 10kOhm pull-up resistor.The importance of the pull.up resistor is well explained here.In few words it prevents to short the circuit.
This is the final schematic : (the green line whit the same name are linked,it is a solution to achieve a cleaner workspace)



Once I finished the schematic I moved on designing the board.Once I finished a first sketch I checked the DRC rules:
Tools --- DRC
and I changed :





After That I clicked on Check and the result was a disaster:



The first problem was that I wasn't using a SMD AVRISP.The right one is :



Once fixed it I rechecked :



To solve all this problem I changed all the routes width to 0.4mm,because in the DRC rules I setted the minimum width to 16mil that is greater than 0.3 mm
TIPS : double click on an error will show the problematic part.
At the end of the battle here is my hello-board design :

Traces and outline

I followed the same tutorial linked above at the section "Exporting a Board Design to be Used with Modela" to create the png files that will be used by the Fab Modules to generate the RML files.
Once I created the RML files (see here to know how to do it) the milling process didn't go well :



The pins in the left of the microcontroller were shorted whit the VCC.
Solution:
  • I changed the Minimum Width for the routes to 12mil
  • I changed the width of the routes that pass under the ATtiny44 to 12 mill


  • The second board was OK and I solder every component to the board :



    Testing

    After checking whit the voltimeter if every connection worked I flashed This code that Neil provides.
    The first step was to edit the makefile. And then I flashed the program using the avrdude toolchain:

  • 1: Set the fuses




  • 2: Compile the .c file and produce the .hex and .out files




  • 3: Flash the program into the ATtiny44




  • Then I used the serial monitor that the Arduino Ide provides to see if everything worked :

    Hello Board Test from Tommaso Lombardi on Vimeo.


    And it worked!


    DOWNLOADS

    click here to download the files I made in Eagle for the HelloBoard.