Stepper Motor Projects

Hello everyone! I hope you all will be absolutely fine and having fun. Today, I am going to share a list of Stepper Motor Projects using different software e.g. Arduino, Matlab and NI LabVIEW. I have already shared these projects but they are posted randomly. So, today I thought that I should combine all those projects into a single one. So I am going to share the links of all of those tutorials in this tutorial so that it may be helpful for engineering students or anyone who wants to visit. This tutorial will help you to visit all of my Stepper Motor Projects. You should also have a look at this Stepper Motor Simulation in Proteus. The links of all the tutorials will be given and you will be able to download the desired project code or simulation from the corresponding link. I will make separate sections for each software to control stepper motor. In each section all the possible controls of stepper motor will be given in detail. If you have any sort of problem, you can ask in comments. I will try my level best to solve your issues. So, let's get started with Stepper Motor Projects. first of all, I will post projects i which I have done direction control of stepper motor:

Stepper Motor Projects

In this section of Stepper Motor Projects, I will provide you the list of the tutorials in which I have already controlled the direction of the stepper motor using three different software e.g. Arduino, Matlab and NI LabVIEW. I have used the same hardware and Arduino source code in all of these tutorials. In case of Matlab and NI LabVIEW I have sent commands through the serial monitor towards Arduino and hence the whole system works.
Stepper Motor Direction Control using Arduino
In the tutorial Stepper Motor Direction Control using Arduino, I have interfaced a stepper motor with Arduino UNO board to control its clockwise and counter clockwise direction. I have used a motor controller named as H-Bdridge to control the direction of stepper motor. It can control only one stepper motor at a time.. The algorithm was very simple. Commands for clockwise and counter clockwise rotation are sent through the serial monitor of Arduino softwrare. These commands are then passed to the motor controller and then it decides the direction of rotation of stepper motor after manipulating the Arduino commands. Direction of stepper motor can be reversed by simply changing the polarity so L298 controls the direction of the stepper motor by continuously making its pins low, high and vice versa.
  • You can download the complete simulation there.
  • Download .rar file, extract it and enjoy the complete simulation:
Stepper Motor Direction Control Using Arduino
Stepper Motor Direction Control using Matlab
In the tutorial Stepper Motor Direction Control in Matlab, I have created a simple Graphical User interface (GUI) in Matlab having three different buttons for controlling the clockwise, counter clockwise direction of the stepper motor and to stop the stepper motor as well. Two more buttons are also there on the GUI for opening and closing the serial port. As we press any of the buttons, corresponding command is sent through the serial port from Matlab to Arduino and then Arduino transfers those commands to the H Bridge and hence the entire process gets completed. Pressing the Open Serial Port button, serial port will be opened and we will be able to communicate with the Arduino using serial communication and at the end we must close the serial port in order to avoid the exchange of unnecessary commands being sent through the serial port.
  • You can download the complete simulation here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Direction Control Using MATLAB
Stepper Motor Direction Control using NI LabVIEW
In the tutorial Stepper Motor Direction is Controlled in NI LabVIEW, I have controlled the clockwise and counter clockwise direction of the stepper motor using serial communication between NI LabVIEW and Arduino. Commands like C, S and are sent through NI LabVIEW towards Arduino for clockwise rotation of the stepper motor, stop the stepper motor and anti clockwise rotation of the same stepper motor respectively. There are three different buttons on the front panel of NI LabVIEW. These buttons are used to send commands C, S and from NI LabVIEW to Arduino using Serial communication.
  • You can download the complete simulation here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Direction Control in LabVIEW
Stepper Motor Direction Control using PIC Microcontroller
First of all I have made Stepper Motor Drive Circuit in Proteus ISIS and I have controlled the speed angle as well as the direction of the stepper motor using PIC micro controller. I have made a pretty simple logic. I have placed a serial terminal in my Proteus simulation. You have to sent the commands through that serial terminal. The stepper motor will change its direction as well the speed after manipulating those commands.
  • You can download the complete simulation here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Direction Control using PIC Microcontroller

Stepper Motor Speed Control

In this section of Stepper Motor Projects, I will provide you the list of the tutorials in which I have already controlled the speed of the stepper motor using three different software e.g. Arduino, Matlab and NI LabVIEW. I have used the same hardware and Arduino source code in all of these tutorials. In case of MATLAB and NI LabVIEW I have sent commands through the serial monitor towards Arduino and hence the whole system works.
Stepper Motor Speed Control using Arduino
In Stepper Motor Speed Control using Arduino, I have actually used the builtin command myStepper.step to control the speed for the stepper motor. For this purpose, I have not used PWM pins of L298 motor controller instead I only used input pins of it, to control the speed of the stepper motor. By assigning higher values to the myStepper.step motor can be rotated at higher speed. Similarly motor will rotate slowly if the value of myStepper.step is lower. All the executed commands are printed on the serial monitor and I have also printed those executed commands on LCD as well for this project.
  • You can download the complete Arduino Source code here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Speed Control using Arduino
Stepper Motor Speed Control in Matlab
In Stepper Motor Speed Control in Matlab, I have created a  Graphical User Interface (GUI) in Matlab having two extra buttons as compared to the GUI of Stepper Motor Direction Control in Matlab. One for continuously accelerating the speed of the stepper motor and the other for continuously deaccelerating the speed of the same stepper motor. As we press any button, corresponding command will be sent through the serial port from Matlab to Arduino using serial communication. The logic created is pretty simple, the speed of the motor will accelerate continuously as many time we press the button and if the maximum speed is reached, motor maintains the same speed even we continue to enhance its speed. Same procedure will be followed to reduce the speed of the stepper motor.
  • You can download the complete simulation here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Speed Control using MATLAB
Stepper Motor Speed Control using NI LabVIEW
This one is the last one among Stepper Motor Projects, named as Stepper Motor Speed Control in NI LabVIEW, I have have placed five different buttons on the front panel to control the direction as well as the speed of the DC motor. By pressing the Accelerate button again and again speed of the stepper motor will increase in proportion to the number of times the buttons is pressed. Similarly, by pressing Deaccelerate button again and again the speed of the stepper motor will decrease in proportion to the number of times the button is pressed. First of all you need to press the Start button in order to start the serial communication between NI LabVIEW and Arduino. After pressing it you will be able to send the commands serially from NI LabVIEW towards Arduino.
  • You can download the complete simulation here.
  • Download .rar file, extract it and start playing with the simulation.
Stepper Motor Speed Control using LabVIEW These are all Stepper Motor Projects posted yet on our blog. I hope you all enjoyed this tutorial. If you face any sort of problem you can ask me anytime without even feeling any kind of hesitation. I will try my level best to solve your issue in a better way, if possible. I will explore Arduino, Matlab and NI LabVIEW further in my later tutorials. Till then, Take care :)

LCD Interfacing with Microcontrollers

Hello everyone! I hope you all will be absolutely fine and having fun. Today, I am going to combine all of my previous tutorials for LCD Interfacing with Microcontrollers, at a single platform for your easiness. You will able to see and learn the interfacing of LCD with three different microcontrollers. Before going into any detail I would like to tell you a bit about the history of LCD. There are a lot of devices in the market now a days, which can be used as the displaying devices. LCD's are also among those devices and considered as the one of the most important devices specially for the microcontroller based projects. The word LCD is basically abbreviated from Liquid Crystal Display because it is made up of Liquid Crystal Technology. LCD is also a great debugging tool just like Serial Port. It becomes a lot difficult to use any debugger every time and is not reliable too. Where as LCD's can used to observe the output quickly while making changes in your code. It plays a vital role in almost all kinds of microcontroller based as well as electronic based projects. While making these types of projects we need to display the output and some messages. Seven segment is the basic the device to do that task but it has a lot of limitations. Another best option available is LCD. It comes in different dimensions. The most commonly used LCD's have dimensions of 16×2 i.e. 16 columns and 2 rows. It is capable of displaying 32 ASCII characters, 16 characters per line. Other dimensions of the LCD includes 20×4, 128×64 etc. You just need to know how to interface the LCD and then you will find that it is the easiest, cheapest and reliable output device available in the market. LCD has a wide range of applications e.g. robotics, power electronic based projects, microcontroller based projects, mobile phones, cameras, high resolution color displays.

LCD Interfacing with Microcontrollers

Here in the tutorial, LCD Interfacing with Microcontrollers, I will tell you about the configuration of the LCD, its pins specifications and about the procedure to interface it with different microcontrollers e.g Arduino, PIC Microcontroller and 8051. First of all, I would like to tell about the desired components and their specifications in the form of a list.
Components Required
The list for the basic and necessary components required while LCD Interfacing with Microcontrollers is given below.
  1. Microcontroller (Arduino, PIC, 8051)
  2. Jumper Wires (Male-female)
  3. Soldering Iron
  4. Soldering Iron and Gum
  5. Male Pins for LCD
  6. LCD (either 16×2 or 20×4)
Components Description
  • Microcontroller acts as the back bone of any project because it controls and handles all the tasks and is used to exchange the desired commands either serially or simultaneously. In the tutorial LCD Interfacing with Microcontrollers, I am going to use three different microcontrollers as the backbone of the project, i.e. Arduino, PIC microcontroller and 8051 microcontroller.These microcontrollers are shown in the figure below.
  • Jumper Wires are basically used for making the connections between microcontrollers and LCD in order to obtain the circuit in proper working condition. The jumpers wires are usually of for different types i.e. male-male, male-female, female-female and female-male. The jumper wires are shown in the figure below.
  • Soldering Iron is used to join the male pins with the LCD specifically in this case. Its a device or an electronic equipment used to make the permanent connections between two or more devices. Soldering Iron is shown in the figure below.
  • Soldering Gum and Stand are used for the purpose of clean soldering and supporting the solder respectively. The soldering gum along with the soldering stand is shown in the figure below.
 
  • Male Pins for LCD are used to make connect between LCD and microcontroller. These supporting pins are shown in the figure below.
  • Liquid Crystal Display (LCD) is used to display output messages and the desired results. LCD are available in the markets now a days, in different sizes. 16×2 and 20×4 are the most commonly used dimensions of the LCD. This type of LCD has 16 pins. Each pin is associated with the different function. The functions associated with each pin of the LCD are shown in the table below.
  • LCD can be operated in two different modes 4-bit mode and 8-bit mode, depending upon the selection of data pins. If we have selected four of its data pins (DB0-DB3) then LCD will be in 4-bit operating mode and if we have selected all of its data pins (DB0-DB8) the LCD will operate in 8-bit mode. 16×2 LCD is shown in the figure below.
  • Another most frequently used small LCD with 20×4 dimension is shown in the figure below.
  • For the proper working of LCD in 4-bit mode we need to use four of its data pins i.e. (DB4-DB7). In total we need to use 8 pins including RS, Enable, DB4, DB5, DB6, DB7, Voltage (5V) and Ground (0V). Data pins are used for the exchange of the data between microcontrollers and LCD.
  • RS is the pin 4 of the LCD and it selects data register when high and command register when low as described in the above table.
  • Enable is the pin 6 of the LCD. When it is high a low pulse is provided and it i used to send data to data pins (DB4-DB7) in this case.
  • So, that was the brief discussion of the components necessary for LCD Interfacing with Microcontrollers.
  • Now, I am going to combine all of my previous tutorials related to LCD interfacing with different microcontrollers here on a single platform.

New LCD Library for Proteus

In this tutorial, I have shared a new LCD library for Proteus which will help you in interfacing LCD with Arduino or any other microcontroller in Proteus ISIS. We have designed two new LCDs in Proteus. Proteus already has builtin libraries for LCD but they are not such good looking. So, I designed them which are good looking as compared to the builtin LCDs of the Proteus. I have provided two different libraries in this package. You just need to copy and paste them in libraries folder of your installed Proteus software. After restarting the Proteus software you will be able to search two different LCD's with excellent external look. Pick anyone of them from the search option and start interfacing it with the Arduino in Proteus and observe its working.
  • You can download these libraries here by clicking on the button below.
  • Download .rar file, extract it and enjoy these libraries.

Download LCD Library for Proteus

LCD Interfacing with Arduino

Here, in this section of the tutorial LCD Interfacing with Microcontrollers, I will combine my previous tutorials having detailed discussion about how to interface LCD with Arduino.
Scrolling Text on LCD with Arduino
Here, in the tutorial Scrolling text on LCD with Arduino, I have shared my knowledge with all of guys that how make an algorithm in Arduino software in order to generate a scrolling text on LCD. I have used a very basic 16×2 LCD in Proteus for this article. This tutorial will help you to learn how to interface 16×2 LCD with Arduino and how to display a scrolling text on it in Proteus. I have written a simple code to print the name of our website on LCD first, then I updated the same code for displaying the name with a movement in both left and right direction.
  • You can download the Arduio source for displaying scrolling text on LCD.
  • Download .rar file, extract it and enjoy the complete code.

Arduino Source Code

ADC Value on LCD using Arduino
In the tutorial ADC Value on LCD using Arduino, I have provided the detailed discussion about the circuit designing for LCD to interface it with Arduino. The design consists of two types of transformers named as current transformer and potential transformer. AC power is supplied to these transformers which is converted into 5V later. After designing the circuit properly I have designed an algorithm to display ADC values on LCD using Arduino. The second part of this section of the tutorial LCD Interfacing with Microcontrollers consists of the source code for displaying ADC values on LCD using Arduino in Proteus. The algorithm is very simple and is easy to understand. The function for displaying voltage is a bit complicated but not so difficult.
  • You can download the circuit designed in Proteus and the Arduino Hex file here by clicking on the button below.
  • Just download the .rar file, extract it and enjoy the complete package containing both Proteus design as well as Arduino Hex file.

Proteus Simulation & Arduino Hex File

LCD Interfacing with 8051 Microcontroller

In this section of the tutorial, LCD Interfacing with Microcontroller, I will explain you that how to interface an LCD with 8051 Microcontroller and the step by step procedure to design a simple program for 8051 microcontroller in order to display the messages on the LCD interfaced with it. In the tutorial, I have given a detailed discussion about both, the designing of the circuit in Proteus as well as the source code for printing the text on LCD using 8051 microcontroller. I have divided this tutorial in two different parts. The first part includes the designing of the circuit in Proteus whereas the second part contains the description about the embedded code for 8051 microcontroller. Source code is written using keil uvision3 compiler and 8051 microcontroller. I have used AT89C51.
  • You can download the complete Proteus design and the complete source code here by clicking on the button below.
  • Download .rar file, extract it and enjoy the complete package.

Proteus Simulation and Code

LCD Interfacing with PIC Microcontroller

Here, in this section of the article LCD Interfacing with Microcontrollers, I have shared a detailed discussion with all of you guys about designing a circuit for LCD interfaced with PIC microcontroller as well as about designing an algorithm to display ADC value on LCD using the same microcontroller i.e. PIC microcontroller.
Display ADC Value on LCD using PIC Microcontroller
In the tutorial Display ADC Value on LCD using PIC Microcontroller, I have elaborated the design of the circuit for LCD interfacing with PIC microcontroller and to display ADC values on LCD. Basically I have divided this task into two different parts. In the first part I have performed the task for Circuit Designing of LCD with PIC where as in the second part contains the code for displaying ADC values on LCD.
  • You can download the Proteus simulation here by clicking on the button below.
  • Download .rar file, extract it and enjoy the package.

Proteus Design

  • That was the combined version of my all of the previous tutorials related to LCD Interfacing with the three different types of microcontrollers.
So, that is all from the tutorial LCD Interfacing with Microcontrollers. I hope you enjoyed this tutorial. If you face any sort of problem regarding anything, you can ask me freely anytime without even feeling any kind of hesitation. I will try my level best to solve your issues in some better way, if possible. I will explore different software e.g. Arduino, Keil uvision3, MATLAB, NI LabVIEW etc as well as the hardware based projects, in my later tutorials and will surely share them with all of guys as well. In my next tutorial I will explain about the different amazing tools of MATLAB e.g. command window, m.file, simulink and Graphical User Interface (GUI). So, till then, Take Care :)
Syed Zain Nasir

I am Syed Zain Nasir, the founder of <a href=https://www.TheEngineeringProjects.com/>The Engineering Projects</a> (TEP). I am a programmer since 2009 before that I just search things, make small projects and now I am sharing my knowledge through this platform.I also work as a freelancer and did many projects related to programming and electrical circuitry. <a href=https://plus.google.com/+SyedZainNasir/>My Google Profile+</a>

Share
Published by
Syed Zain Nasir