Fnial project- electronic design and production

1. Aim

My finial project is about a 3D printing nozzle that can output melt Sn, So I need the following function in my PCB board:

  • Control relay and then turn off or turn on the hot nozzle(we should use relay to control another high power circuit, because the current and voltage is high);
  • Use NTC temperature to catch the temperature of hot nozzle;
  • Use motor driver to control the stepper motor;

2. Test

Before design and production the board, I use Arduino to simulation the function and board.

2.1 Test NTC

In Arduino (with Atmel 328 chip ),we will use the following method to connect it . So I connect this component with Arduino Then I program the code as the following:

During run the test, I use electric hair dryer to simulate high temperature, and the following picture show that temperature rise from 40 -56 in about half minutes.

The test for NTC in Arduino is OK.

2.2 Test stepper motor

According to the above guide , I connect Arduino, A4988and stepper motor. Please note: we need to connect 0.1uf(100nf) capacitance VMOT and GND

A4988

A4988(A4988 stepper motor driver carriers is a microstepping bipolar stepper motor driver. It has current limiting, over-current and over-temperature protection.) More information about A4988 in this link

stepper motor

Stepper motors are DC motors have multiple coils that are organized in groups called "phases". By energizing each phase in sequence, the motor will rotate, one step at a time(every step. A 1.8°, so motor need 200 pulse to run one cycle) More reference this link

Program
int x;   
void setup()  
{  
  pinMode(6,OUTPUT); // Enable  
  pinMode(5,OUTPUT); // Step  
  pinMode(4,OUTPUT); // Dir  
  digitalWrite(6,LOW); // Set Enable low  
}  
void loop()  
{   
  digitalWrite(4,HIGH); // Set Dir high  

  for(x = 0; x < 200; x++) // Loop 200 times  
  {  
      digitalWrite(5,HIGH); // Output high  
      delayMicroseconds(800); // Wait 1/2 a ms  
      digitalWrite(5,LOW); // Output low  
      delayMicroseconds(800); // Wait 1/2 a ms  
    }  
  delay(1000); // pause one second  

  digitalWrite(4,LOW); // Set Dir low  
  for(x = 0; x < 200; x++) // Loop 2000 times  
  {  
      digitalWrite(5,HIGH); // Output high  
      delayMicroseconds(800); // Wait 1/2 a ms  
      digitalWrite(5,LOW); // Output low  
      delayMicroseconds(800); // Wait 1/2 a ms  
    }  
    delay(1000); // pause one second

Then the stepper motor can run as the following video

The test for stepper motor in Arduino is OK.

3.Eagle design

3.1 Design basic circuit

I'm not familiar with atmel 328 ,so with the help of my instructor Silli Saverio. I design my board and learn from Daniele Ingrassia's Satshakit In the meantime atmel 328 is the chip of Arduino , so I can take the following picture for reference In Satshakit's board, the left part is the same. So I delete the right pin and keep the left part of the board.And design another function in eagle. This is the basic of the PCB board. I would use FTDI cable to program the board. So I design connect FTDI to Atmel 328 in the following picture

3.2 Design NTC(Input)

According to the test in "2.1 Test NTC",I add NTC and 50k resistor. and use A1(Arduino A1 correspond to pin24(PC1) in Atmel 328). So I add NTC part in circuit

3.3. Design step motor(Output)

According to the test in "2.2 Test stepper motor", I add the following components(Green LED, 499ohm resistor,100 uf capacitance)

3.3 Relay pin

I use the type of relay(SONGLE SRD-5VDC-SL-C) to control the high electric power for hot nozzle. There are three pin for relay control(VCC, GND,IN),detail information in the following link

3.4 Other design

I add led to show the condition of hot nozzle, stepper motor 's rotation(clockwise or anti clockwise) The following 4pins in (PC2,PC3,PC4,PC5) is prepare for some extensions

4.layout

After I check with the schematic to confirm there is no mistake. Then we can go to the next stepI use the command Generate/Switch to make the board The detail in layout can referene the WEEK 7: ELECTRONIC DESIGN-eagle practice-part5,it show the detail about creat basic board,creat a DRC design rule,move and rotate,output data. At last I got the following result For the wire in the red array there is a wire I have to use jumper to connect. Then I output 2files( trace.png ,hole.png)

5. Process

5.1 edit

Then input the png files to fabmodule(http://fabmodules.org/) For detail of this process we can reference the page: WEEK9: EMBEDDED PROGRAMMING-Embedded programming-4.2 Translate to milling machine language

5.2 milling

I use SRM-20 Desktop Milling Machine to milling the board.Detail reference WEEK 5: ELECTRONIC PRODUCTION-Practice-3.3 Equipment. The result is the following picture I use knife to take away waste copper and then use sandpaper(mix alcohol) to polish the board surface.And get the following PCB

5. Solder

The BOM is the following:

name quantity mark
Atmel328 1 Atmel328P
Capacitor(22pf) 2 C1,C2
Capacitor(100nf) 2 C5,C6
Capacitor(1uf) 1 C4
Capacitor(10uf) 1 C3
Capacitor(100uf) 1 C7
Resistor(499ohm) 4 R2,R3,R8,R9
Resistor(1Kohm) 2 R5,R7
Resistor(10Kohm) 1 R1
Resistor(50Kohm) 1 R4
Resistor(0Kohm) 1 R10
LED GREEN 1 Green
LED GREEN1 1 Green
LED stepcw 1 Blue
LED stepacw 1 Green
LED FAB1206 1 RED
SWITCH 2 SWITCH,S1
CRYSTAL 1 16MHZ
NTC temperature sensor 1 NTC

I solder it one by one.

6. Program

6.1 Bootloader

This board is referenced from Arduino, I need to upload Arduino bootloader. Here is the connection of my board with Arduino: In this time I find a problem, I forget that there is no pin for bootloader. So I have to solder new wire on the chip Then operate as following:

  • Open Arduino IDE;
  • Select proper programmer by click on Tool->Programmer
  • Select Arduino UNO as Tool->Board
  • Click on Tools->Burn Bootloader It is OK.

  • To avoid the problem and make sure it is stable

  • In the meantime, during I do the test in stepper motor , there is an explosion (The Electrolytic capacitor has the requirment in positive and negative.But I connect reverse VCC12POWER and GND12POWER )

    I update it to the following

6.2. test NTC

I have NTC circuit and port on this board. So I just need to add NTC sensor on the board as following: Then program it (NTC arduino code in the attachment) But I found I can't upload it . With the help of my instructor Saverior. I change the board choice in Arduino Then it is OK

6.3. Test Step motor

In this test , I need to add 12 v power to drive the motor. So I connect the board as following:

Then use Stepper motor arduino code and updateit . The motor is running well. We must make sure the power connect the right position,or there would be problem. For example last timeI connect reverse VCC12POWER and GND12POWER.Then the Electrolytic capacitor has the requirment in positive and negative.

6.4. test hot nozzle

6.3.Test all

7.Attachment:

results matching ""

    No results matching ""