This CNC Sheild V4 is used as a driver expansion board for engraving machines. This Driver Expansion Board has a total of 3 channels slots for A4988 stepper motor driver and it is used for driving 3 channels of stepper motors. One stepper motor requires only 2 input/ Output ports. if we want to manage 6 IO ports are sufficient to manage 3 stepper motors. We can easily manage stepper motors if we are using them in our projects. Get Arduino NANO CNC Shield V4, Sensors, and Modules at epro.pk.
this CNC shield is compatible with a micro-driver laser engraving machine because it is a three-axis CNC engraving machine.
Only 2A can be controlled within 2 phase four-wire stepper motor.
this CNC shield contains a digital IO interface.
this shield is easy to connect to other modules like ENDSTOP.
It also contains I2C interface. Users can interface LCD I2C or other I2C modules.
This V4 Shield contains 5V DC power.
its input voltages are 7.5-12V.
this shield is GRBL compatible.
it is worked with Arduino NANO.
Connection Diagram of CNC Sheild V4 Expansion Board for Arduino NANO:
Using Method of Arduino NANO CNC Shield V4
Test Main Board
First, write below code in IDE to test whether the mainboard, shield, and three motors work normally.
Explanation for Shield :
We can increase the rotation speed of the stepper motor if we properly reduce the 800 in delay micro-sec to increase the frequency of input PWM signal. we can not change the value too much because the motors will stop moving.
To change the torque we can just adjust the output current of the motors. and for this purpose rotate the knob on A4988 Stepper motor driver.
Code:
Install the Firmware and GRBL Controller for this program
First, write the test program to key Studio UNO R3
then copy the GRBL folder_ Arduino_Library_Keyes in the data packet
then paste the Copy data into the folder library, in your Arduino IDE documents installation.
#include <grblmain.h>
void setup(){
startGrbl();
}
void loop(){}
//Burn the code above to keyestudio UNO R3
#define EN 8 // stepper motor enable, low level effective
#define X_DIR 5 //X axis, stepper motor direction control
#define Y_DIR 6 //y axis, stepper motor direction control
#define Z_DIR 7 //z axis, stepper motor direction control
#define X_STP 2 //x axis, stepper motor control
#define Y_STP 3 //y axis, stepper motor control
#define Z_STP 4 //z axis, stepper motor control
/*
// Function: step -control the direction and number of steps of the stepper motor
// Parameter: dir -direction control, dirPin corresponds to DIR pin, stepperPin corresponds to
step pin, steps is the number of steps.
// no return value
*/
void step(boolean dir, byte dirPin, byte stepperPin, int steps)
{
digitalWrite(dirPin, dir);
delay(50);
for (int i = 0; i < steps; i++) {
digitalWrite(stepperPin, HIGH);
delayMicroseconds(800);
digitalWrite(stepperPin, LOW);
delayMicroseconds(800);
}
}
void setup(){// set the IO pins for the stepper motors as output
pinMode(X_DIR, OUTPUT); pinMode(X_STP, OUTPUT);
pinMode(Y_DIR, OUTPUT); pinMode(Y_STP, OUTPUT);
pinMode(Z_DIR, OUTPUT); pinMode(Z_STP, OUTPUT);
pinMode(EN, OUTPUT);
digitalWrite(EN, LOW);
}
void loop(){
step(false, X_DIR, X_STP, 3200); // x axis motor rotates CCW for 1 circle, as in 200 steps
step(false, Y_DIR, Y_STP, 3200); // y axis motor rotates CCW for 1 circle, as in 200 steps
step(false, Z_DIR, Z_STP, 3200); // z axis motor rotates CCW for 1 circle, as in 200 steps
delay(1000);
step(true, X_DIR, X_STP, 3200); // X axis motor rotates CW for 1 circle, as in 200 steps
step(true, Y_DIR, Y_STP, 3200); // y axis motor rotates CW for 1 circle, as in 200 steps
step(true, Z_DIR, Z_STP, 3200); // z axis motor rotates CW for 1 circle, as in 200 steps
delay(1000);
}
Install Grbl Controller361 Software for CNC Shield
Grbl Controller is a piece of software that is used to send GCode to CNC Machines. Run Grbl Controller361 Setup in your installation packet, the interface below will come out:
Click Next to continue.
Click on the checkbox and accept the agreement and then click on the “Next” tab.
To continue with setup just click on “Next”.
Click on “Next”. If the user wants to select a different folder to install. then click on “Browse”.
Click on “Next”. If the user wants to select a different folder to place the program ‘s shortcuts. then click on “Browse”.
Then Select the additional tasks. the user would like the setup to perform while installing GRBL controller. after that, just click on Next.
Click Install to continue with the installation.
Then CLick on “Next”.
Now Click on “Finish”.
Grbl Controller is used to testing the G-Code
By using the USB cable power the mainboard. then connect correctly all your external devices and after that run GRBL Controller.
after that choose the port name same as the IDE COM port and click the “Open” to open the series port. and then connect your CNC machine to the computer.
When you open the series port. then the “Open” tab will be changed into “Close/ Reset” and it will get red.
Now user can click the X-axis, Y-axis, Z-axis as shown in the diagram to adjust the motion direction of motors.
Note:
When you adjust the axis, Please first close and then open it again before you beginning the G-Code file.
To try it just click on “Choose File” to choose the G-Code file named cn. this option is used to test the data packet for a beginner and definitely the interface will come out. that is GRBL Controller.
Just click on “Begin” and motors will move on coordinates.
Reviews
There are no reviews yet