This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
3. Connect any one of the outputs of FRL unit to 5/2 direction control unit port 1
4. Connect port 4 of DCV to blank end of the double acting cylinder
5. Connect the output of FRL unit to the input of two 3/2 roller lever valves to give pilot pressure for 5/2 double pilot valve
6. The output of the two roller valves are connected to the either side of the 5/2 double pilot valve properly.
7. When the FRL valve is opened the higher pressure air enters the blank end of the cylinder through DCT and the piston moves forward.
8. At the end of the forward stroke the piston rod pressures the roller valve. The output of roller valve is sent to double acting cylinder to change the position.
9. Now the high pressure air from FRL unit is sent to rod end of the double acting cylinder through the second position of the DCV the piston retracts.
10. At the end of return stroke the roller valve is pressed. The output of the roller valve is sent to dc change the piston. This is repeated until the FRL valve is closed.
RESULT:
Thus the continuous reciprocating of single and double acting cylinders are actuated by
STUDY OF 8051 MICROCONTROLLER AND STEPPER MOTOR Expt. No.: Date:
AIM: The study the fundamentals of 8051 microcontrollers and stepper motor.
MICROCONTROLLER:
A microcontroller is an integration of a microprocessor with memory and input, output interfaces and other peripherals such as timers on a single chip.
A microcontroller may take an input from the device it is controlling and control the device by sending signals to different components in the device.
A microcontroller is often small and low cost. The components may be chosen to minimize size and to be as inexperience as possible.
Another name for a microcontroller is embedded controller. They can control features or action of the product.
Register in microcontroller:
A microcontroller contains a group of registers each type of register having a different functions.
Accumulator:
The accumulator (A) is an 8 bit register where data for an input to the arithmetic and logic unit is temporarily stored. So the accumulator register is a temporary handling register for data to be operated on by the arithmetic and logic unit also after the operation the register for holding the result.
B Register:
In addition to accumulator an 8 bit B-register is available as a general purpose register when it is not used for the hardware multiply/divide operation.
Data pointer (DPTR):
The data pointer consists of a high byte (DPH) and a low byte (DPL). Its function is to hold a 16 bit address. It may be manipulated as a 16 bit data register. It serves as a base register in direct jumps, lookup table instructions and external data transfer.
The stack refers to an area of internal RAM that is used in conjunction with certain opcode data to store and retrieve data quickly. The stack pointer register is used, by the 8051 to hold as internal RAM that is called top of stock. The stack pointer register is 8 bit wide. It is increased before data is stored during PUSH and CALL instructions and decremented after data is restored during POP and RET instruction. The stack pointer is initialized to 07H after a reset. This causes the stack to begin at location 08H.
Program counter:
The 8051 has 16 bit program counter. It is used to hold the address of memory location from which the instruction to be fetched. 8051 is a 16 bit hence it can be address up to 216 byte i.e. 64k of memory. The PC is the only register that does not have an internal address.
Internal RAM:
The 8051 has 128 bytes internal RAM. It is addressed using RAM address register
First thirty two bytes from address 00H to 1FH of internal RAM constitute 32 working registers. They organized into four banks of eight registers each. The four register banks are numbered 0 to 3 and consist of eight registers named R0 to R7. Each register can be addressed by name or by its RAM address.
Only one register bank is in use at a time. Bits Rs0 and Rs1 in the PSW determine which bank of register is currently in use.
Register banks when not selected can be used as general purpose RAM.
PIN diagram of microcontroller:
The 8051 microcontroller is available in a 40 pin dual in-line (DIL) package arrangement. It is important to note that many pins of 8051 are used for more than one function.
The function of each of the pins is as follows.
PORT 0 (pins 32-39):
Port 0 pins can be used as I/O pins. The output drives and input buffers of port 0 are used to access external memory address, time multiplexed with the data being written or read. Thus port 0 can be used as multiplexed address data bus.
The output drives of port 2 are used to access external memory. Port 2 outputs the high order byte of the external memory address when the address is 16 bits wide otherwise port 2 is used as I/O ports.
PORT 3 (pins 10-17):
All ports pins of port-3 are multifunctional. They have special functions including two external interrupts two counter two special data lines and two timing control strobes.
Power supply pins Vcc and ground to pin Vcc with rated power supply current of 125mA.
Oscillator Pins XTA2 (pin 18) and XTA1 (pin 19):
For generating an internal clock signal the external oscillator is connected at these two pins.
ALE (address latch enable) Pin 30:
AD0 to AD7 lines are multiplexed. To determine these lines and for obtaining lower half of an address, an external latch and ALE of 8051 is used.
RST (Reset pin 9):
This pin is used to reset 8051. For proper reset operation, reset signal must be held high at least for two machine cycles, while oscillator is running.
PSEN (Program Store Enable pin29):
It is the active low output control signal used to activate the enable signal if the external ROM/EPROM. It is activated every six oscillator periods while reading the external memory. Thus this signal acts as the read store to external program memory.
STEPPER MOTOR
A motor in which the rotor is able to assume only discrete stationary angular position is a stepper motor. The rotary motion occurs in a stepwise manner from one equilibrium position to the next.
Construction features:
A stepper motor could be either of the reluctance type of or permanent magnet type. A PM motor consists of multiphase stator and two part permanent magnet rotor variable reluctance motor has magnetized rotor. PM stepper motor is the most commonly used type. The basic two phase stepper motor consists of two pairs of stator poles. Each of four poles has its own winding. The excitation of any one winding generates a north pole and a South Pole gets attracted and the torque induced at the diametrically opposite side. The rotor magnetic system has two end faces. The left face is permanently magnetized as south and the right face as North Pole faces.
The north pole structure is twisted with respect to the south pole structure so that south pole precisely between two north poles. In an arrangement where there are four stator poles and three pairs of rotor poles, there exist 12 possible stable position in which a south pole if the rotor can lock with a north pole of the stator. From this is can be noted that the step size is
= 360 (Ns*Nr)
Ns number of stator pole
Nr number of pairs of rotor poles
Generally step size of the stepper motor depends up on rotor poles. There are three different schemes available for stepping a motor. They are
There are many kinds of stepper motor like unipolar type, bipolar type, single phase type, multiphase type; single phase stepper motor is often used for quartz watch. In PM type stepper motor, a permanent magnet is used for motor and coils are put on stator. The stepper motor model which has 4 poles at top and bottom and at either sides. X coil, X¯ coil, r coil and r¯ coil are put to the upper side and the lower pole. r coil and r¯ coil are rolled up for the direction of the pole becomes opposite when applying an electric current to the r¯ coil. It is similar about X and X¯ too. The turn of the motor is controlled by the electric current which pairs into X, X¯, r, r¯. The rotor rotational speed and the direction of turn can be controlled by this control.
Speed control of a stepper motor:
The requirement is to use a microcontroller to drive a stepper motor in both forward and reverse directions of shaft rotation and to implement a two speed arrangement switches are to be used to produce the two speeds and a reversal of shaft rotation.
Generally a stepper motor has four sets of coils; one end of each coil may be connected together and then connected to DC supply. The remaining four ends may be driven through transistors either separately or in integrated circuit form. A four bit code sequence continuously applied to the drive circuit from the microcontroller port causes the motor shaft to rotate in angular steps. Stepper motor have step angles of 1.8 degree step revolution and turning force may be improved by using a step down gear box. The stepping code sequence may be obtained from the motor manufacturer or distributor. The program in this example was a common four step sequence of A,9,5,6 that it sent continuously would cause the motor shaft to rotate.
RESULT:
Thus the fundamentals of microcontroller and stepper motor were studied.