Sie sind auf Seite 1von 11

KEYES 3D V1.

2 Learning Manual
Download Address of Arduino IDEhttps://www.arduino.cc/
You can find related studying material on this official website. KEYES 3D V1.2 control board
contains MEGA 2560 control board and RAMPS 1.4 board.

1. Upload program to 3D V1.2 board


Hardware Required:
3D V1.2*1
USB Cable*1
Sample Code:
/*
Blink
Turns on an LED on for one second, then off for one second, repeatedly.
This example code is in the public domain.
*/
// Pin 13 has an LED connected on most Arduino boards.
// give it a name:
int led = 13;
// the setup routine runs once when you press reset:
void setup() {
// initialize the digital pin as an output.
pinMode(led, OUTPUT);
}
// the loop routine runs over and over again forever:
void loop() {
digitalWrite(led, HIGH);
// turn the LED on (HIGH is the voltage level)
delay(1000);
// wait for a second
digitalWrite(led, LOW);
// turn the LED off by making the voltage LOW
delay(1000);
// wait for a second
}

Open Arduino IDEclick

, appearing following selectionselect

BasicsBlink.

Select ToolsBoardArduino Mega 2560 or Mega ADK.

Select ToolsSerial PortCOM100(current port of 3D V1.2)

Finally, click Upload to upload program. After uploading is done, D4 light on control board is
blinking.

2. Collision Sensor
Hardware Required:
3D V1.2*1
Collision Board*1
USB Cable*1
Limit Wire*1
Connection Diagram
Complete connection according following diagram .
3D V1.2
Collision Board
+
VCC

GND
S
OUT

Sample Code
// set pin numbers:
const int buttonPin = 3;
const int ledPin = 13;

// the number of the pushbutton pin


// the number of the LED pin

// variables will change:


int buttonState = 0;

// variable for reading the pushbutton status

void setup() {
// initialize the LED pin as an output:
pinMode(ledPin, OUTPUT);
// initialize the pushbutton pin as an input:
pinMode(buttonPin, INPUT);
}
void loop(){
// read the state of the pushbutton value:
buttonState = digitalRead(buttonPin);
// check if the pushbutton is pressed.
// if it is, the buttonState is HIGH:
if (buttonState == HIGH) {
// turn LED on:
digitalWrite(ledPin, HIGH);
}
else {
// turn LED off:
digitalWrite(ledPin, LOW);
}
}

After uploading is done, press collision switch, and you can see D4 LED on 3D V1.2 is off; loosen
the switch, D4 on.

3. Temperature Sensor
Hardware Required
3D V1.2*1
Temperature Sensor*1already installed on nozzle

USB Cable*1

Connection Diagram

Sample Code
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorValue = analogRead(A13);
Serial.println(sensorValue);
delay(1);
}

After uploading is done, click


rate

, open serial monitor, select correct baud

read current value. When temperature increases, the value decreases.

4. A4988 Driver Board


Hardware Required
3D V1.2*1
A4988 Module*4
USB Cable*1
Motor Wire*4

42 Stepper Motor*4
DC Power Supply*1
Connection Diagram

Sample Code
// Arduino 2560----------------------shield
//the following is stepper motor program
#define X_EN
38
//stepper motor enable port, working at low level
#define Y_EN
56
#define Z_EN
62
#define E0_EN
24
#define E1_EN
30
#define X_DIR
55
//X axis stepper motor control direction
#define Y_DIR
61
//y axis stepper motor control direction
#define Z_DIR
48
//z axis stepper motor control direction
#define E0_DIR
28
//E0 axis stepper motor control direction
#define E1_DIR
34
//E1 axis stepper motor control direction
#define X_STP
54
//x axis stepper motor control
#define Y_STP
60
//y axis stepper motor control
#define Z_STP
46
//z axis stepper motor control
#define E0_STP
26
//E0 axis stepper motor control
#define E1_STP
36
//E1 axis stepper motor control
/*
//functionstep
functioncontrolling stepper motor direction and steps
//parameterdir controlling direction, dirPin DIR pins of corresponding motorstepperPin
pins of corresponding motor and steps
//no returned value
*/
//int i=0 ;
void setup()

step

{//setting IO pins as output


pinMode(X_EN, OUTPUT); pinMode(Y_EN, OUTPUT);
pinMode(Z_EN, OUTPUT); pinMode(E0_EN, OUTPUT);
pinMode(E1_EN, OUTPUT); pinMode(X_DIR, OUTPUT);
pinMode(Y_DIR, OUTPUT);pinMode(Z_DIR, OUTPUT);
pinMode(E0_DIR, OUTPUT);pinMode(E1_DIR, OUTPUT);
pinMode(X_STP, OUTPUT);pinMode(Y_STP, OUTPUT);
pinMode(Z_STP, OUTPUT);pinMode(E0_STP, OUTPUT);
pinMode(E0_STP, OUTPUT);digitalWrite(X_EN, LOW);
digitalWrite(Y_EN, LOW);digitalWrite(Z_EN, LOW);
digitalWrite(E0_EN, LOW);digitalWrite(E1_EN, LOW);
}
void EN()
{
digitalWrite(X_EN, LOW);
digitalWrite(Y_EN, LOW);
digitalWrite(Z_EN, LOW);
digitalWrite(E0_EN, LOW);
digitalWrite(E1_EN, LOW);
}
void turn(boolean dir, int steps)
{
EN();
digitalWrite(X_DIR,dir);
digitalWrite(Y_DIR,dir);
digitalWrite(Z_DIR,dir);
digitalWrite(E0_DIR,dir);
digitalWrite(E1_DIR,dir);
delay(100);
for(int i=0;i<steps;i++)
{
digitalWrite(X_STP, HIGH);
digitalWrite(Y_STP, HIGH);
digitalWrite(Z_STP, HIGH);
digitalWrite(E0_STP, HIGH);
digitalWrite(E1_STP, HIGH);
delayMicroseconds(100);
digitalWrite(X_STP, LOW);
digitalWrite(Y_STP, LOW);
digitalWrite(Z_STP, LOW);
digitalWrite(E0_STP, LOW);
digitalWrite(E1_STP, LOW);

delayMicroseconds(100);
}
}
void loop()
{
EN();
turn(true, 12800);
turn(false, 12800);
}

Connect to power supply DC12V 8Aaccording to diagram, and you can see the stepper motor
rotates towards positive direction at the same time and towards negative direction after uploading
is done.

5. Display Screen
Hardware Required
3D V1.2*1
LCD2004 Control Panel*1
USB Cable*1
10PIN Flat Cable*2
SD Card*1not included in this kit
Connection Diagram

Connect EXP1 on 3D V1.2 to EXP1 on LCD2004 control board , and EXP2 on 3D V1.2 to EXP2
on LCD2004 control board with 10PIN flat cable.

Sample Code
Download Address of Firmware:
http://7326097.s21d-7.faiusrd.com/0/ABUIABAAGAAgjPDavQUogP_SgAc?f=KEYES+MI
NI+3D+Printer++Firmware.zip&v=1471592460

Double click

open KEYES MINI 3D printer firmware. You can see all files

showed above are included in IDE.

Click Upload, and wait for some time because uploading a pile of files and compiling takes long
time. After uploading is done , you can see some parameters on LCD2004.

Press rotary encoder to enter to menu. Adjust to the bottom of menu through encoder. If not
installing SD card, it displays NO SD CARD as following picture. Otherwise, it displays Print
from SD, and enter this menu , you can see files in SD card. Now, if you want to print, choose G
code file whose file suffix is gcode to print.

If you have trouble uploading firmware, the reason maybe is that you havent add

libraries.
as

RAMPS1.4 Diagram

Now, add these libraries to IDE, such


. After adding, reopen firmware and upload.

Das könnte Ihnen auch gefallen