Posted: June 17th, 2021
Direct current ( DC ) motor is applied in a broad scope of applications peculiarly in mechanization engineering due to minimum electromotive force ingestion. In the proposal DC motor plays an effectual function in Hardware execution. The chief rule behind the undertaking is to utilize the cascade control to run the DC motor ; it ‘s one of best feedback accountants. For gauging the speed and the armature current of the DC motor with 24 Vs and a dsPIC Microcontroller is programmed.The above all operation is done in a closed control cringle map.
Table of Contentss
2. Specific Aims of the undertaking
Brushed DC Motor
DC motor theoretical account
Digital control of District of Columbia motor
Advantages of District of Columbia with regard to rush control
Analogue control of District of Columbia motor
2.1 Dss PIC
2.2 MPLAB IDE
3. Design and Research
Speed cringle kineticss
3.1 Components for commanding 24v brushed Dc motor
3.1. Flexible upside-down board
3.2.1 Generating PWM moving ridge signifiers
3.1.2 H-Bridge convertor
3.2 Software techniques used in DC motor
Programing microcontroller in Flexible inverted board
4. Consequences and Discussion
List of Figures
FIGURE 1: Operation of BRUSHED DC Motor
FIGURE2: General block diagram of velocity cringle and current cringle of DC Motor
FIGURE3: H-bridge convertor with different electromotive force VI± & A ; VI?
The chief map of the undertaking is to command the velocity of the DC Motor utilizing a dsPIC30f3010 microcontroller. For that implement a separate hardware to fulfill the chief map of the undertaking.
1.2 Specific Aim of the undertaking
In order to accomplish the chief nucleus of the undertaking, concept Hardware for commanding the velocity control of DC motor. The chief hardware demands are
Ds PIC microcontroller
ICD interface & A ; connection for system interface
DC power supply
The above constituents are required to build a hardware called Flexible Inverted Board [ 4 ] .
1.3 OUTLINE OF PROJECT
In this paper a flexible upside-down board is constructed with the series of hardware constituents
Then pass on the Flexible inverted board with system utilizing MPLAB IDE package with ICD-3 interface [ 4 ] .the linguistic communication used in the MPLAB package is C-language.
The velocity cringle and the current cringle are the two of import maps for commanding the velocity of the Dc motor. In our undertaking the cardinal point is to command both the cringles by C-programming linguistic communication utilizing MPLAB ICD-3.
The velocity cringle of the microcontroller is called velocity accountant and the current cringle of the microcontroller is called current accountant.
THEORITICAL TECHNIQUES AND THEIR REVIEWS
2.1 Brushed DC Motor
In automotive industries DC motor is used widely in “ fuel pump control, electronic maneuvering control, engine control and electric vehicle control ” [ 6 ] for its cost effectual and it is used in many applications like “ mush and paper industries, fan pumps, imperativeness, winder motors ” [ 2 ] , ” place contraptions, washers, driers and compressors ” [ 6 ] are some of the best illustrations. DC motor is one of the of import hardware employed in this paper, it consists of a rotor and stator, and the parts are placed in a lasting magnetic field. Commutator and coppice are placed in between the rotor and stator. Positioning the coppice at a peculiar way in the rotor is classified into some classs and they are “ radial, trailling or taking ” [ 3 ] places. When the rotor rotates the commutator and C coppice interface at a point, which produces an tremendous sum of magnetic field from the coppice of the motor and it produces current to the armature twist of the Dc motor.
FIGURE 1: Operation of BRUSHED DC Motor [ a ]
2.2 DC Motor theoretical account [ 8 ]
Each motor will hold different specification and demands. Harmonizing to motor demands and inside informations the theoretical account can be designed. The purpose of motor theoretical account, trades with commanding the applied electromotive force of both velocity and current. The basic theoretical account for a Dc Motor is shown below
FIGURE2: DC Motor theoretical account
The above diagram is a simple RL circuit. RL circuit is called opposition induction circuit
and a 24v DC Motor. All these constituents combine to organize RL circuit.
Now the derivation portion of the RL circuit is explained below
T ( T ) = J
tungsten is the Angular speed
J is the minute of inactiveness
B is the clash
T is the armature Torque
T ( T ) = ( T )
is the Torque invariable
is Armature current
Harmonizing to Kirchhoff ‘s jurisprudence
( T ) – ( T ) = ( T ) +
and are the induction and opposition for the armature current ( Iowa )
The electromotive of the motor can be determined by multiplying the back voltage with velocity
The relationship for the electromotive force is shown below
( T ) =
The province theoretical account for any DC motor utilizing Iowa and tungsten ( velocity ) is mentioned below.
2.3 ds PIC -microchip
Ds PIC stands for Programmable Interface Controller or programmable intelligent computing machine, which act as an of import controlling unit for full system. The chief aim of this undertaking is to do the Ds PIC to bring forth 6PWM wave form. In an ideal status the wave form from the pulsation width transition can command the H-bridge convertor. It non merely serves as an interface accountants but besides plays a function of a programmable logic accountant ( PLC ) . [ 16,20 ]
Ds movie has a memory of 16bit microcontroller that has two major maps. Firstly it can move as a package portion functioning package maps and the other is a hardware portion functioning hardware maps.
The input signals that are attain from the feedback service system are received by the package portion which in bend utilizes the codifications that are written on the bit on C – linguistic communication to analyse the input and run the hardware. Finally the package makes certainly the hardware runs based on the package maps to derive the needed end product. [ 18, 20 ]
Our undertaking concentrated on working experiments that were run at lab conditions. Since a twosome of systems have certain differences from the stimulation that have been run in existent conditions compared to ideal conditions. This in bend is the working of the microcontroller.
dsPIC30F 3010, 2010 4011 and 3012 are the series of french friess that have been available in the Lab. The missive ‘F ‘ in ds PIC30F and such bit provinces that the bit contains brassy memory. The ground for sing this brassy memory merchandise is because 30F has an ex-ordinary public presentation when compared to EPROM ( Effaceable Programmable Read-Only Memory ) and one clip programmable french friess ( OTP ) . This has been a major demand for the running of this undertaking to acquire the needed end product.
16-bit modified Harvard architecture has been added to the CPU incorporating Ds PIC30F for using the information and upgrading the set of usher lines for running digital signal processing ( DSP ) [ 14 ] . There is a drawn-out flexible opcode field which has been installed in the CPU that has a 24 spot broad user coder memory country and the entire turn toing velocity can travel up to 4MA-24 spot. This programming theoretical account has sixteen 16bit working registries in Ds PIC30F bit. There are two categories of debut commanding unit that have been integrated and used for executing they are integrated and used for executing [ 2 ] .
2.3.1 dsPIC30F 3010
This subdivision is about the pin constellation and the constituents available in dsPIC30F3010 microcontroller. Normally the memory allotment in dsPIC30F 3010 can classified in to three classs they are
SRAM in Bytes
EEPROM in Bytes
Programmable memory in Bytes/instruction
SRAM stands for inactive RAM ( Random Access Memory ) . Harmonizing to the tabular matter shown below the informations bound for inactive RAM should non transcend 1024 bytes. The memory in the map can sort in two types they are
X – Datas RAM
Y – Datas RAM
The inactive RAM uses X -RAM and Y_RAM for hive awaying informations.
The memory allotment for EEPROM is same as inactive RAM. In read merely memory one of the of import types of ROM used to hive away memory is EEPROM. The chief map of this ROM is based on two parametric quantities they are endurance and keeping [ 2 ] . Endurance is to retain the informations even after the ROM fails. Therefore the informations ca n’t be deleted at any instant. Time period is required to hive away informations that is taken attention by keeping [ 2 ] .
In a peculiar plan Ds PIC30f microcontroller has a separate memory allotment for hive awaying both the reference and information. The memory bound for the plan memory is 24K.
plan reference infinite anda informations reference infinite
Table 1: Tabulation for memory allotment in Ds PIC30f3010
The pin constellation of dsPIC30f3010 is described below
FIGURE 3: Pin constellation of dsPIC30F 3010 [ 2 ]
( PWM1L and PWM1H ) , ( PWM2L and PWM2H ) & A ; ( PWM3L and PWM3H ) [ 2 ] these are six different types PWM channels used in the pin constellation. In which each PWM brace generates three responsibility rhythms with one high end product ( H ) and one low end product ( L ) .
INT0, INT1 & A ; INT2 are the interrupt buffers used in the PIC. VSS and VDD [ 2 ] are the supply electromotive force and land in the PIC accountant.
U1RX & A ; U1TX, U1ARX & A ; U1ATX [ 2 ] are the series of pins used for pass oning PIC microcontroller with Personal computer, in other system interface operation can be done by UART map. In that RX stands for receiving system and TX stands for sender. The above pin map plays an of import in our undertaking.
3.1 Components for commanding 24v brushed Dc motor
Since the undertaking is to the full based on difficult ware so many constituents are available and how they work in that operation.
3.1.1Cascade control operation in Dc Motor:
The below operation is done by utilizing Double cascaded layout, it consists of two cringles they are current accountant with current mention and velocity accountant with velocity mention [ 5 ] as shown in.
FIGURE4: General block diagram of velocity cringle and current cringle of DC Motor [ B ]
The current cringle is covered by the velocity cringle, in the block diagram it has the two circles interior circle is called interior cringle and the outer circle is called outer cringle since the interior circle operation is ever quicker than the outer circle. In other words interior circle public presentation is multiple of 10 times faster than the staying 1. The cascade control rule is chiefly used in our undertaking to keep the velocity of the motor at a changeless degree and the current cringle in the cascade control is the armature current and it is otherwise called as torsion. Sometimes armature current may transcend the bound to avoid this state of affairs in cascade control, it has limiter, and the chief map of the clipper is to restrict the values of the armature current. For illustration To restrict the armature current to 64volt i.e. 1 ampere. So that the armature wo n’t transcend those bounds since the clipper is available in cascade control. The velocity accountant in the cascade control used to bring forth demand current ia* . The motor runs to get the better of the demand current values. The demand current value will ever higher than the normal current values. So that the velocity motor bit by bit increases.
PI accountant ( relative Integral accountant )
The above all constituents construct a cascade accountant and the map each constituent is described below
22.214.171.124PI accountant ( relative and built-in accountant )
In cascade accountant map assorted accountants are used for observing the velocity and control of the motor, but PI accountant is recommended as high efficient accountant because it consist to constant addition Kip and Kid. By manually tuning the addition of both Kii and Kpi will cut down the steady province mistake and the stableness of the system will be increased. In recent study more than 70 % cascade accountant used PI accountant for commanding the velocity control DC Motor. In order to cut down the steady province mistake in the closed cringle system, bit by bit increase the relative addition changeless Kp. As the addition of the Kp increases the steady province mistake in the system decreases. But the stableness of the system will non be stable. To do the system stable, built-in term Ki is introduced in the system. When both the proportional and built-in term amount each other to cut down the steady province mistake and do the system stable.the above two maps can be done at the same time in the PI accountant. The mathematical look for PI accountant is explained below.
FIGURE 5: PI accountant of a closed cringle map [ 1 ]
Y- Output of the PI accountant
Err-Error in the PI accountant
At the get downing mistake ( Err ) will go through through both Kp and Ki.
For relative addition the end product is Kp Err
y1= Kp Err eqn1 [ 1 ]
y2 = eqn 2 [ 1 ]
Y = y1 + y2 eqn 3 [ 1 ]
eqn 4 [ 1 ]
The cardinal point in this PI accountant is the mistake Err in intergral addition Ki will be integrated. so that the steady mistake will be reduced and the system will be stable.
The current accountant in the closed cringle maps of the cascade control. The current cringle is besides called as current accountant. It is used to protect cascade circuit from harm. The chief map of the cascade map is to command the velocity. Before commanding the velocity the current of the accountant should be controlled. The current obtained from the closed cringle map is from armature circuit of the DC Motor [ 7 ] .the input in the current accountant is the back voltage ( ia* ) .
Power convertor is chiefly used to better the control in the system. It has high exchanging frequence, since the power convertor in the current cringle is really speedy. The end product of the convertor is armature electromotive force ( Va ) .
( -E ) is the perturbation occurred in the current cringle, in order avoid the perturbation
FIGURE 6: Functional block diagram of Current accountant
The perturbation is added along with RL circuit, and the equation is shown below
Va = ( S La + Ra ) ia + Tocopherol
The map of the RL circuit is cut down complexness
Va is Armature electromotive force.
Iowa is armature current ( seeking to command )
Ra is Armature opposition
Tocopherol is Disturbance
RL = 1/ ( S La + Ra )
Current cringle is carried out by conveying the from Iowa ( armature current ) to ia* ( demand armature current ) . As speedy as possible without doing the over shoot acquiring so high. If the over shoot is high it creates job to the convertor. Similarly when the addition values ( Kp and Ki ) increases in PI controller the over shoot value reduces, but the same clip there is more sum of oscillation which may impact the system. Care should be taken in taking both Kp and Ki values.
FIGURE 7: graph for armature current V subsiding clip
ia – Armature current
ia* – Demand armature current
ts – Settling clip
3.1.2 Flexible inverted board
The major hardware has been designed and implemented as Flexible inverted board.
It consists of many constituents they are dsPIC30F3010 microcontroller, H-bridge convertor and District of Columbia motor. The maps of these hardware constituents are explained earlier. The above all operation is implemented in a individual hard ware called flexible inverted board.
FIGURE 8: Functional block diagram of Flexible inverted board
126.96.36.199 IR2130 gate thrust circuit:
There are three input signal generator blocks which are capable of supplying two end products each gives the inputs to the six end product drivers. L1, L2 and L3 are signal generators which drive exactly the three low-side end product drivers although H1, H2 and H3 signal generators must be flat shifted before it is fed to the high-side end product drivers.
The drifting points of the driver, gate charge demands of the power switch and the maximal power switch “ ON ” times receives power from three bootstrap capacitances C1, C2 and C3. Bootstrap capacitances besides feed supply to the internal natation driver current. Once these energy demands are met there must be considerable sum of charge still on the 8.3V nominal to forestall halting. D7, D8 and D9 should be super-fast.
VCC degree seen by an under-voltage sensor circuit gives an input to criminalize six end products of the signal generator circuits. Current detector R1 derives the ITRIP signal in the chief power circuit of the motor when it is segregated with a 0.5 V mention to criminalize the six signal generator end products. ITRIP inputs sets up a mistake logic circuit which in bend gives unfastened drain TTL end product for system gesture.
FIGURE 9: Circuit diagram for IR2130 gate thrust circuit
188.8.131.52Trim port map with PWM
Trim port are little in size and they are really little in size.it is chiefly used in many PCB building board since it ‘s occupies less infinite.
The spare port act like a potentiometer and it is otherwise called as pruner [ ] . By tuning the spare port, opposition value can be minimized or maximized. For illustration if a 50ohm opposition can be tuned by spare port from 0 – 50.
The two leg of H-bridge convertor produce two pulse wave form one with low end product ( 1L ) and another 1 with high end product ( 1H ) . The responsibility ratio of the PWM wave signifier can set utilizing spare port.
184.108.40.206DC MOTOR ENCLOSED WITH A ENCODER
The best methods of ciphering the velocity of the DC motor is utilizing optical encoder method. It consists of a disc, Light Emitting Diode ( LED ) and optical detector [ 6 ] . The disc is fitted with the rotor, as the rotor rotates the disc starts whirling along with the rotor and it is placed in between the LED beginning and the light detector. Once the rotary motion starts the disc passes through the LED beginning and the optical detector gets started, from which the velocity of the motor can be calculated because the optical detector Acts of the Apostless like a tachometer. In other words the encoder in the DC motor is otherwise called as velocity observing detectors. [ 6 ]
220.127.116.11 H-Bridge convertor
DC motor runs differential velocity, but the applied electromotive force of the motor varies at every interval of clip. Since the electromotive force is straight relative velocity, as the electromotive force increases the velocity of the motor besides increases. Speed can be calculated by tachometer which is in physique in the DC motors, the applied electromotive force can be supplied and controlled by a convertor called h-bridge convertor.
GD – Gate Drive Circuit
FIGURE 10: H-bridge convertor with different electromotive force VI± & A ; VI? [ c ]
In this H-bridge circuit it produces two unipolar pulsation breadth transitions because it has two leg inverter. Effective transition takes topographic point merely in the first half of the inverter. As a consequence two variable electromotive forces are generated on either side of the armature twist.
In H-bridge, transition index is represented as ( +mi ) and the reciprocal of transition index is represent as ( -mi ) .the motor in our undertaking really sing two pulse breadth. Both the pulsations are reciprocally relative to each other bring forthing a unipolar PWM.
The two legs in the convertor are called the shift signals or exchanging frequence. Bigger convertor comparatively has lower frequence and smaller convertor has higher frequence. If the frequence in the leg1 is high in contrast the frequence in the leg2 will be low.
In our undertaking see VI± and VI? are the exchanging channels of the H- p convertor. they are reciprocally relative to each other.
The bearer signal is called the input frequence. the bearer frequence used in our undertaking is 10khz. Harmonizing to the bearer frequence the clip period of VI± and VI? differs.
In C coding VI± and VI? is mentioned as PDC1and PDC2 from the below graph
FIGURE 11 graphical representation of PWM signals in H- Bridge convertor.
The end product electromotive force of the h-bridge convertor can be obtained both negative and positive electromotive force distribution [ 1 ] . Pulse width transition in the h-bridge convertor helps to command the armature circuit of the DC motor [ 1 ] . Maximal armature current ( torsion ) can be obtained by comparing clip invariable of both field twist and the armature weaving [ 1 ] . Since the motor is connected straight to the field twists supply electromotive force in the field twist is more when compared with the armature weaving. To keep equal clip invariable in both field and armature weaving [ 1 ] , the applied electromotive force in the armature twist should be increased, as the armature current increases the torsion end product is maximized [ 1 ] .
3.1.3 Generating PWM moving ridge signifiers
As the torsion end product gets maximized, pulse breadth transition is introduced in the H-bridge system to avoid the perturbation in the armature current.it can be done by increasing the frequence degree of the H-bridge convertor at a higher scope.
As the torsion end product gets maximized, pulse breadth transition is introduced in the H-bridge system to avoid the perturbation in the armature current.it can be done by increasing the frequence degree of the H-bridge convertor at a higher scope.
FIGURE 12: Diagrammatic representation of the pulsation breadth transition is shown below [ 6 ]
The below specification is referred from [ 6 ]
Ton – Time is ON ( applied electromotive force )
Toff – Time OFF ( applied electromotive force )
T – Time period.
Duty rhythm = .
The mean electromotive force of the DC motor can be shown in an equation below
Average = Duty rhythm A- Vin [ 6 ]
When the motor is running at a changeless velocity the back voltage of the motor is besides remain changeless.
As the back voltage remain the same the motor running at changeless velocity and the armature current ( Ia ) is zero. PWM is one chief portion that is required for the operation of cascade control.
4. Software used to drive the Motors
4.1 Programing microcontroller in Flexible inverted board utilizing C-language
In the flexible inverter board PIC microcontroller plays a major place in directing the pulsation breadth transition. The Ton clip in the pulsation breadth transition ( PWM ) signal can be modulated or controlled by the microcontroller, as the microcontroller varies the clip, the speed of the motor alterations with regard to clip. The Programing linguistic communication used in microcontroller is embedded C. The scheduling codifications are downloaded in the microcontroller bit, the downloading attack can be done by a package development tool called MPLAB, this package exists in supervising the systems, this package should be foremost installed in the Personal computer, the coders will compose the codifications to modulate the PI accountant to get Applicable beginning from the current cringle of the cascade control map. Once the codifications are accepted harmonizing to the current cringle [ 1 ] , the plans can be downloaded in the microcontroller through cosmopolitan consecutive coach or in circuit Debugger ( ICD ) ; ICD is a coach which interfaces Personal computer system and the flexible inverter Board. [ 6 ]
In order to plan the microcontroller examine whether the hardware constituents are interfaced with the accountant. The scheduling linguistic communication used for programming the accountant is C linguistic communication. In c-language the information ‘s are classified in to input informations and end product informations. The microcontroller direct the information in linear signal, where the C-language wo n’t accept linear signals.To avoid the state of affairs ADC convertor and encoder interface are introduced in the system. ADC stands for parallel to digital convertor ; it converts the linear signal in to digital signals. Then the digital signals get received by the C-program as input informations. In turns c-program will direct the end product informations to the PWM unit. UART communicating system is a bidirectional so that microcontroller and Personal computer can pass on at the same time. UART stands for cosmopolitan asynchronous receiving system sender. The basic diagrammatic representation for system communicating with C-language is shown below
FIGURE 13: System communicating in C – Programing Language.
In C-language foremost initialise all the maps required for the velocity control of motor.
4.1.1Current detector input:
The current in the motor spiral is one of import parametric quantity in the effectual running of the motor. So it is indispensable to mensurate the value of this current. The measuring of the current is performed by utilizing particular detectors call Hall Effect Sensors. The scope of the current is determined by the evaluation of the motor. Any over current in the motor can severely damage the motor. The Hall Effect detectors produce a electromotive force matching to the stage current. This is fed to the ADC inputs of the micro accountant where it is converted into the digital signals. This is so fed into the microcontroller plan. Hence the current demands to be limited within specific limits.CL1, CL2 and CL3 are the three current detectors variables used in this cryptography. The spot ratio of the ADC input is 10 so the input informations scopes from 0 to 1023. The maximal informations bound for the current detector is 1023.so the current detector value in the C- codification is initiated as
CL1 = 511 ; CL2 = 511 ; CL3 = 0 ;
4.1.2 Encoder input:
For any velocity accountant, the existent velocity of the rotor forms the footing for the control signals. The velocity control signal can be changed merely if there is an mistake between the existent velocity of the rotor and the coveted velocity of the rotor. If the measured velocity is less than the coveted velocity so the PWM pulsations are changing consequently to increase the velocity. To execute this action a shaft encoder is used. The shaft encoder uses an opto-mechanical system to bring forth pulsations.
These pulsations so are used to deduce the velocity of the rotor. A mention pulsation is used as an index to number the pulsation. This information is fed to the microcontroller, which so uses a particular timing circuit that processes these encoder pulsations. The motor velocity to be accessed by the microcontroller needs to be stored in a variable within the micro accountant codification. The variable used in this plan is a variable called revolutions per minute. This variable is accessed to cipher all maps related to the motor velocity.
4.1.3 Pulse Width Modulation:
The MOSFET ‘s in the circuit is used as switches. These MOSFET ‘s are switched harmonizing to a PWM. To drive these MOSFETs ‘ a gate driver circuit is required. The gate thrust signal generates the electromotive force required for the operation of these MOSFET ‘s. The PWM is generated by the microcontroller harmonizing to the plan and is supplied to the gate thrust circuit. The PWM signals are separate for each if the 3 legs of the MOSFET inverter. Each of the PWM requires a transition index to bring forth the signal. These transition indexes are stored in a registry. The registries are named as PDC1, PDC2, and PDC3. These variables are really important in bring forthing the PWM signals for the MOSFET drivers. Since informations bound is 1023.
4.1.4 Initializing the codification in C – linguistic communication
Before executing any map in C-language, it requires an low-level formatting. It is of import to initialising the variable of a map. Some the maps are initialized below.
Init PORT ( )
This map initialise the digital input and end product port or parallel input and parallel end product of the microcontroller.
Init UART ( )
It is one of pin in the microcontroller.The chief map of the UART is used for bidirectional communicating with Personal computer. Since UART can able to observe the transmittal velocity in informations transportation between the microcontroller and Personal computer. The maximal transmittal velocity is around 19200.the informations transportation wo n’t transcend the bound.
Init PWM ( )
The input frequence of our PWM signal is 10kHz.the clip bound for the transition index is around 0-1474.in the h-bridge convertor has two legs so each leg produces a PWM signal with a maximal clip bound of 0-737. Hence the Ton clip of PWM signal will be in 1:1 responsibility ratio.
Init ADC ( )
It is used to change over the parallel signals in to digital signals. In the microcontroller there are five pins reserved for the ADC inputs. During the informations transmittal ADC maps plays a of import function in disrupting the signal. An low-level formatting is required for the interrupt to execute any map in C- linguistic communication.
Init CAPTURE ( )
The gaining control map is chiefly used to mensurate the frequence and clip period of the PWM wave signifier generated from the two legs J30 and J31 pins of the H-bridge convertor
InitTimer3 ( ) and InitTimer1 ( )
To put initial clip in the microcontroller for the gaining control map and timer 1 set the starting clip for the interrupt map happened in the UART communicating system.
Interrupts are occurred merely during the informations transportation, when the transmittal velocity that is the baud rate is known means the interrupts can be added to the system easily.in our undertaking the baud rate is 19200.the chief map of the interrupt is used synchronize clip period of PWM with the velocity cringle and the current cringle of the motor. In our undertaking four different type of interrupt service modus operandi are used.
They are ISR_ADCInterput ( )
This interrupt is triggered when the ADC finishes its transition and hence its get synchronized to the microcontroller PWM clip base. From this all the application control codification to be implemented in this interrupts service modus operandi.
ISR_T1Interput ( )
The assorted information to the Personal computer is transferred by utilizing the UART communicating nexus in this interrupts service modus operandi. All the variables that are needed to be mentioned in this everyday utilizing standard C map dash ( ) .
ISR_U1RXInterput ( )
Assorted information is transferred from the Personal computer in to the C plan. This everyday concedes us to modulate the facets of the plan when it is running.
ISR_IC1Interput ( )
It measures the velocity value from clocking informations that are attained in the input gaining control faculty.
FIGURE 14 The connexion diagram for the velocity control of Dc motor is shown above
5 Consequences and treatment
As discussed earlier the assorted maps of hardware constituents in this undertaking, this subdivision discusses the inside informations sing how the undertaking deals with comparing and measuring the consequences. Undertaking has a series of stairss ; each measure is assigned with different operation techniques to put to death the concluding consequences.
5.1 Initial connexion trial between MPLAB IDE and Flexible inverted Board
Initially the system needs to be interfaced utilizing the flexible inverter board. This operation is performed by linking the Personal computer to the flexible upside-down board. To link the Personal computer to the flexible upside-down board, ICD 3 interface port is used to finish the connexion. Since the informations transmittal velocity in ICD 3 is high when compared with ICD 2, the power supply to the inverted board is supplied through the Dc power supply generator. The Initial conditions were set to the power supply generator where the electromotive force bound and current bound is zero. For the Dc motor maximal electromotive force supply is 24voltage in VDC and a current of 0.5 ampere is set in the power supply generator which is so connected to the inverter board. Once the initial conditions are set, the power generator is fitted with a path button which needs to be held and at the same time the end product button needs to be pressed. Once the end product button is turned ON, the power is applied to the inverted board. On the other manus MPLAB IDE package is opened in the system, where a new file demands to be created so the needed compiler for this undertaking needs to be selected. Once these scenes are done the debugger option in the MPLAB ICD 3 is chosen, the package will initialise the tool and a verification message was displayed on the screen which says “ ICD 3 is connected ” . The codifications for this were designed in the MPLAB package and burnt in the Ds PIC microcontroller by ICD 3 interface.
5.2 Measure 3, 4 & A ; 5
One of the ADC input pin in the PIC microcontroller demands to be initialize as ADCBUF0. The maximal input scope of ADC interrupt is 1023 since ADC input is initialized as IN1.
When IN1 is initialized as ADCBUF0 in C-language it can be written as
IN1 = ADCBUF0 ;
PDC1 = IN1 ;
IFS0bits.ADIF = 0 ;
Here IN1 is the informations value for the spare port in the flexible upside-down board. The maximal IN1 value is 1023. As mentioned earlier PDC1 is initialized as one leg portion H-bridge convertor, where PDC1 is 1474 and a unipolar pulsation breadth transition was generated. If IFS0bits.ADIF is zero, it means that the chief used to initialise ADIF value is 0 in other words it is the default value.
PDC1 = 2*IN1 ;
Similarly in measure 4 multiply the spare port input value with 2. Then the PDC1 input scope will transcend so ‘if ‘ statements are used to restrict the value of PDC1 from 0 to 1474.
To restrict the values of PDC1 the codification in C-language can be implemented as ;
PDC1 = 2*IN1 ;
If ( PDC1 & gt ; 1474 )
PDC1= 1474 ;
5.3 Step6 & A ; 7
The flexible upside-down board consists of a gate triggered circuit in other words they are known as MOSFETS. Wholly 6 MOSFETS are available in the flexible upside-down board. In our undertaking two MOSFET are used and both of them are connected to the legs of the H-bridge convertor. The MOSFETS that are connected to H-bridge convertor are ‘U10 and U13 ‘ & As ; ‘U11 and U14 ‘ . To supervise and look into if the MOSFETS are triping the pulsation or non it can be done by analyzing the trial points available in the flexible upside-down board. This is done utilizing the CRO where the trial points are connected via investigations as a consequence triping pulsation is produced. The diagrammatic representation of Square wave signifier is shown below.
FIGURE 15The above diagram represents the general pulsation wave form
Depending on the transition index value produced by the ADC input the responsibility ratio of the pulse fit transition varies consequently. In other words the transition index is straight relative to the responsibility ratio. Using appropriate C plan the ensuing wave form from the three different responsibility ratios was observed to be in the square form. When the CRO is connected to the trial point J30, three different per centums were obtained due to the different responsibility rhythms. The C codifications that were used to obtain the wave forms are mentioned below:
C codification for 50 % responsibility rhythm:
PDC1 = MI + 737 ;
PDC2 = MI – 737 ;
Manual computation for 50 % responsibility rhythm
Since PDC1 = 1474
If PDC1/2 = 1474/2 = 737.
Resulting wave form for 50 % responsibility rhythm is shown below
FIGURE 16 moving ridge from for 50 % responsibility rhythm
C codification for 25 % dutycycle:
PDC1 = MI + 1105.5 ;
PDC2 = MI – 1105.5 ;
Manual computation for 25 % dutycycle:
( PDC1 and PDC2 ) value for 50 % responsibility rhythm is 737
( PDC1 and PDC2 ) value for 75 % responsibility rhythm is 368.5
For 25 % responsibility rhythm add both 737 + 368.5 = 1105.5
Resulting wave form for 25 % dutycycle:
FIGURE 17 moving ridge signifier for 25 % responsibility rhythm
Code for 75 % dutycycle:
PDC1 = MI + 368.5 ;
PDC2 = MI – 368.5 ;
Manual computation for 75 % responsibility rhythm
For PDC1 and PDC2 is 737
Divide PDC1 and PDC2 by 2
The solution for for PDC1 and PDC2 is 368.5.
Resulting wave signifier for 75 % dutycycle
FIGURE 18 moving ridge signifier for 75 % responsibility rhythm
5.4 Measure 7
The last operation is based on linking the CRO with the trial point J30 in the flexible upside-down board, likewise the same operation is performed in another trial point J31. The triggered pulsation obtained from the MOSFETS is shown below for the different responsibility rhythm ratio as already mentioned in measure 6.
Resulting wave form for 25 % responsibility rhythm:
FIGURE 19 Resulting wave signifier for 25 % responsibility rhythm in trial point J31
Resulting wave signifier for 50 % responsibility rhythm is shown below
FIGURE 19 Resulting wave signifier for 50 % responsibility rhythm in trial point J31
FIGURE 20 Resulting wave signifier for 75 % responsibility rhythm:
From above three wave signifiers each differs in their responsibility ratio. Then compare the wave form of J30 & A ; J31. The different is happened because of hold or mistake occurred during the informations transmittal.
5.5 Measure 10
In the initial status of the spare port is set as nothing. Then the responsibility rhythm of the PWM 1 is high and PWM 2 will be low.In other words PWM1 is reciprocally relative to PWM2. Similarly in the ulterior status when the spare port is turning toward the higher terminal. Now the responsibility rhythm of PWM 2 is found to be more than 95 % . The end product of the PWM is determined from the CRO. Since the value of PDC1 and PDC2 will be 1474.due to 1:1 responsibility ratio. The input informations values are every bit shared by both PDC1 and PDC2. In some conditions when the PDC1 = 2*IN1.the value of IN1 is 1023, and so value of PDC1 is 2046. As per the conditions mentioned earlier the value should non transcend the input informations bound 1474. Such state of affairs are handled with aid of if statements. Using if statement how the status is satisfied in C cryptography
PDC1 = 737+MI ;
If ( PDC1 & gt ; 1474 )
PDC1 = 1474 ;
If ( PDC2 & gt ; 1474 )
This codification C2=1474-PDC1 makes the motor to revolve at rearward way.
When the above codification is compiled and executed the electric resistance value increased or decreased by manually tuning the spare port in the flexible upside-down board. Harmonizing to the opposition value in the microcontroller the amplitude and the current flow can be controlled.
5.6 Measure 11
Ripple current and RL Load
Now connect the RL burden with the connection of the flexible upside-down board to cipher the ripple current. In the connection of the flexible inverted board has two points. They are sing as point A and point B. Ripple current can be calculated by a device called current investigation. First connect the current investigation to the point A of the connection and view the mean value of the ripple current in the CRO. The wave form for the mean ripple current value for point A is shown below.
FIGURE 21 moving ridge signifier for responsibility cycle1 with 1H and duty rhythm 2 1L ( indicate A )
1H – High End product
1L – Low End product
In this wave form the conditions are wholly reversed when compared with the above wave form.
The responsibility rhythm 1 with 1L and duty rhythm 2 with 1H ( indicate A )
FIGURE 22 moving ridge signifier for responsibility cycle1 with 2L and duty rhythm 2 1H ( indicate A )
Once the rippling currents are calculated in point A. the similar operation is performed by the current investigation in point B. the wave forms are shown below
FIGURE 23 wave form for responsibility cycle1 with 1H and responsibility cycle2 with 1L ( point B )
FIGURE 24 wave form for responsibility cycle1 with 2L and responsibility cycle2 with 2H ( point B )
5.7 Measure 12
This measure deals with ciphering the beginning and derive value of ripple current through current investigation as discussed earlier. These values are chiefly used for trying the input informations ‘s from the microcontroller.
In order to cipher the beginning and addition value the values need to be identified as shown in the tabular matter below they are ; ADC electromotive force, current detector, PDC1 and PDC2. Initially the interface needs to be reloaded with the flexible upside-down board. The PDC1 and PDC2 value can be determined by the ticker option in MPLAB IDE package. The current detector in the flexible inverted board has a trial point J43. Then the current detector value was measured by multi metre through the trial point. For this a 24 electromotive force Dc motor the maximal current detector value gettable will be 2.57voltage. Initially set the spare port value to zero, so look into the current detector value by a multi metre where it showed 2.57. By increasing the electric resistance of the spare port the current detector and ADC electromotive force will be bit by bit decreased nevertheless at one phase the ADC electromotive force bit by bit decreases to zero. Later the ADC electromotive force value increased easy but the current detector invariably decreased as shown in the tabular matter. These values were recorded in the tabular matter.
Subtracted ADC electromotive force value from PDC1 value and the mean value consequence was recorded in the new column. Then the mean value for the new column is calculated.
Table 2 Tabular column for ciphering beginning and addition values
ADC electromotive force
PDC2 – ADC electromotive force
Manual computation for the above tabular matter is shown below
Offset spot = ( PDC1 – ADC electromotive force ) / entire figure values
( PDC1- ADC electromotive force ) = 13.49 + 117.57 + 261.21 + 528.21 + 756.9993 + 956.28 + 1118.93 + 1412.6 = 5588.7793
PDC1-ADC electromotive force = 5588.7793
Entire figure of values = 9
Average ( PDC1 – ADC electromotive force ) = 5588.7793/9 = + 620.9754778.
Calculate the entire ADC electromotive force
Entire ADC electromotive force =27.51 + 25.43 + 21.79 + 20.51 + 17.79 + 0.0007 + 3.72 + 4.07 + 18.4 = 132.5
Offset spot = + 620.9754778./ 132.5 = 4.4602 spot
5.8 Measure 13
In this subdivision connect 24 volt Dc motor to the flexible upside-down board. When the power supply is turned ON the motor rotates at a peculiar velocity and this velocity of the motor rotates harmonizing to the responsibility ratio produced by the H-bridge convertor. Initially test all the conditions to verify the on the job status of the motor. The motor used here is fitted with an encoder that is attached together. Since the flexible inverted board has an encoder sensor the encoder portion of the motor was connected to the encoder sensor, therefore the motor satisfies the conditions mentioned above.
5.9 Measure 14
In this measure, J14 pin of the flexible upside-down board is interfaced together with the system through a overseas telegram. Using Lab position package ‘s the Tacho scope, RPM can be determined.
PDC1, PDC2 and their corresponding responsibility rhythm per centum are viewed.
Like this similar operation
Table 3 Tabular column for ciphering electromotive force Vs velocity
Revolutions per minute
Duty 1 %
Duty 2 %
RPM = K
To cipher the value of the K
K = Vdc12 – Vdc1/RPM12 – RPM1
K = 19.6-18.1/1919 – 1776
K = 0.0104
As per the demands from the tabular matter secret plan the graph for Vdc ( electromotive force ) V RPM
The graph representation is shown below
FIGURE 25 Voltage Vs Speed
5.10 Measure 15
Once the mean value of the ripple current and the beginning values are calculated, to command the velocity of the motor, foremost the applied electromotive force of the motor should be controlled. Interestingly the applied electromotive force can be determined from the current cringle of the relative and Built-in accountant in other words as PI accountant. Since the operation of PI accountant is explained before itself. In the PI accountant current plays the interior cringle, and it is 10 times faster than the outer cringle. So the interior cringle is executed foremost. A measure input given to the PI accountant. The consequence expected from the end product of the PI accountant as a measure end product with extremum over shoot.
This extremum over shoot increases the steady province mistake besides increases. In bends steady province mistake produces a electromotive force bead in the motor. So the velocity of the motor bit by bit decreases. This state of affairs can be overcome by seting the addition of both relative and built-in. The maximal extremum over shoot degree is 7.5 % . If the degree exceeds, the end product of the current cringle is non in a stable status. If the system is non stable, it is hard to command the velocity of the motor. the graphical representation of the expected current cringle is shown below.
FIGURE 26 measure response end product for current cringle
In the above measure response the ia* and Iowa are the demand current and the armature current.
Since the current detector value 1023.
Two current detectors are used.
They CL1 and CL2
The armature current Iowa = 511
Demand current ia* = 511
Tocopherol is the mistake
E = demand current – armature current
E = ia* – Iowa
E = 511 – 511 = 0 ;
Harmonizing to the computation shown above.The codification is compiled in C-language for the current cringle.
In the cryptography
First originate the addition values of the PI accountant as kpi and kii.
int kpi, kii ;
Then initialise the mistake, armature current and demand current as i_error, Iowa and ia_demand
int Iowa, ia_demand, i_error ;
Iowa = CL1 ; ( initialise current detector 1 as armature current of the motor )
CL1 = 511 ; ( initialise the value of current detector 1 as 511 )
ia_demand = 511 ; ( demand armature current )
i_error = ia_demand – CL1 ; ( Error in the armature current can be determined by deducting the armature currenr ( Iowa ) from the demand armature current ( ia* ) . The expected mistake should be zero. when the above codification is executed in MPLAB package. In the get downing the mistake is non zero. Some clip the current detector value differs. As per the codification the expected CL1 value should 511.
In this status, a new set of codification is implemented. In this codification, if statements are used for the CL1 value. Then the current detector value will be within the scope.
if ( 510 & lt ; CL1 & A ; & A ; CL1 & lt ; 517 ) the value CL1 ranges from ( 511 to 517 )
The manual tuning of kpi and kii alterations CL1 from 511 to some other value.
As a consequence mistake occurs in the extremum over shoot.
For illustration if CL1 is 514, which is displayed on the ticker of MPLAB
Since the expected CL1 is 511 but CL1 is 514
The mistake difference between the expected and the present value is 3.
The avoid the mistake difference in CL1 a simple codification is designed below
CL1 = CL1 -3 ; ( if CL1 is 514, 514 – 3 is 511 ) .
The mistake is zero but the extremum over shoot is still high. This is due built-in air current up map because the built-in added with kii in PI accountant. To avoid this mistake separate codification is executed in C cryptography.
The variable zi is initialized as built-in collector and its value is 737.
if ( zi & gt ; 737 )
if ( zi & lt ; -737 )
the above codification keeps the zi value within the scope.
Since i_error = 511
zi = 737 + 511
zi = zi+i_error ; ( anti air current up codification added with an mistake )
In order to avoid the built-in mistake multiply built-in collector with built-in addition ( kii ) .
kii * zi ( eqn 1 )
Multiply the mistake with the addition of proportional.
kpi * i_error ( eqn 2 )
add both the eqn to acquire the concentrated transition index. This map will cut down the steady province mistake and extremum over shoot.
myocardial infarction = ( kpi*i_error ) + ( kii*zi ) ;
From this codification the expected extremum over shoot is obtained with zero steady province mistake.
The expected current cringle moving ridge signifier implemented from the codification is shown below
In this moving ridge signifier over shoot is high.
To cut down the over shoot and stead province mistake manually tune the kpi and kii value.
Manual tuning is like a loop method to acquire a peculiar solution after many comparings take topographic point between kpi and kii values. The expected end product is non yet determined. So the expected end product is still under procedure.
[ 1 ] D.J.Atkinson, “ Control of Electric thrusts, ” EEE 8014 talk notes, School of electrical, electronic and Computer technology, Newcastle University,2011. [ c ]
[ 2 ] R.Roberge, “ Carbon coppice public presentation and application in the mush and paper environment ” , National Electrical Carbon Products, 2001.
[ 6 ] E.A.CHOON, “ DCmotor velocity control utilizing microcontroller pic16f877a ” , 2005, pp. 1-64.
[ 3 ] K.Hameyer, R.J.M.Belmans, “ Permanent magnet excited brushed DC motors ” Dept. of Electrical. Engineering. Katholieke University, Vol. 43, 1996, pp. 247-255
[ a ] CONDIT, R. ( 2004 ) Brushed DC Motor Fundamentals Microchip Technology Inc.
[ 5b ] P.Chevrel, L.Sicot, S.Siala, “ Switched LQ accountant for DC Motor Speed and Current Control: a comparing with cascade control ” , 1996.
[ 4 ] G.J.Atkinson, “ Electrical Power and Control Project, ” EEE8075 ( Semester 1 ) talk notes, School of electrical, electronic and Computer technology, Newcastle University, 2011.
[ 7 ] M.V.Ramesh, J.Amarnath, S.Kamakshaiah, G.S.Rao, “ SPEED CONTROL OF BRUSHLESS DC MOTOR BY USING FUZZY LOGIC PI CONTROLLER ” ARPN Journal of Engineering and Applied Sciences.Vol.6, NO. 9, 2011.
[ 8 ] R. K. Munje, M. R. Roda, B. E. Kushare, “ Speed Control of DC Motor Using PI and SMC ” IPEC, 2010 Conference Proceedings, 2010, pp.945- 950.
DS movie mention
[ 2 ] . ( 2010 ) dsPIC30f3010 Data Sheet. Microchip Technology Inc.
[ 16 ] .D’SOUZA, S. ( 2004 ) detector less BLDC Motor Control Using dsPIC30f2010. Microchip Technology Inc.
[ 18 ] . ELLIOTT, C. & A ; BOWLING, S. ( 2004 ) Using the dsPIC30F for mindless BLDC control. IEEE Inc.
[ 20 ] . HUDDLESTON, C. ( 2007 ) Intelligent detector design utilizing the micro chip Ds PIC [ electronic resource ] / by Creed Huddleston. , Elsevier/News.
J. Plantier, H. Aziza, J.M. Portal, C. Reliaud, A. Regnier, J.L. Ogier, “ EEPROM tunnel oxide life-time dependability anticipation based on fast electrical emphasis trials ” ELECTRONICS LETTERS Vol. 46 No. 23, 2010.
Tang Yiliang, Cui Wenjin, Xie Xiaorong, Han Yingduo, Man-Chung Wong “ 80Cl96MC Microcontroller-based Inverter Motor Control and IR2130 Six-output IGBT Driver ” Department of Electrical Engineering and Faculty of Science and Technology, 1999, pp.665-667. [ FIGURE9 and 18.104.22.168 ]
David Cook “ CHAPTER 14 Variable Resistors ROBOT Building FOR BEGINNERS ” , 2010, pp 173-191. [ trimport ]
Place an order in 3 easy steps. Takes less than 5 mins.