Automatic Active phase selector

Topic: ArtDesign
Sample donated:
Last updated: May 8, 2019

Abstract: Phase absence is a very common and severe problem in any industry, home or office. Many times one or two phases may not be live in three phase supply. Because of this, many times, some electrical appliances will be on in one room and OFF in another room. This creates a big disturbance to our routine work. This project is designed to check the availability of any live phase, and the load will be connected to the particular live phase only. Even a single phase is available, and then also, the load will be in ON condition.

The aim of this project is to construct a single phasing monitor and prevention ystem using 8bit microcontroller. Anti-single phasing relays or single phasing preventer are required for critical loads and circuits. These are required because the normal overload protection doesn’t trip on time. For large air-conditioning compressors, irrigation pumps these are sometimes, included. The purpose of this project is to develop an intelligent system that continuously monitors all the three phase voltages (High voltage AC) and if any of these three phases is disconnected then this system takes the preventive action.The preventive action could be disconnecting the power supply immediately to the load by operating an lectromagnetic relay. This system also alerts the user using visual or audible indicators.

We Will Write a Custom Essay Specifically
For You For Only $13.90/page!


order now

This system consists of three optically isolated high voltage sensors for sensing the presence of high voltage in the respective circuits. One of the voltage sensors is connected to phase line of the supply and the other is connected to neutral line. A microcontroller based control system continuously monitors the voltage in all the three phases of the power supply circuit.In ideal conditions all the three phases gets the same voltage. The visual indicators display the health status of all three phases (Red, Yellow and Green).

But, when any of the phases gets disconnected then in such situations the microcontroller-based system alerts the user about this in the form of visual or audible alerts. Automatic Phase Selection Page 1 INTRODUCTION Project Overview: An embedded system is a combination of software and hardware to perform a dedicated task. Some of the main devices used in embedded products are Microprocessors and Microcontrollers.

Microprocessors are commonly referred to as general purpose processors as they simply accept the inputs, process it and give the output. In contrast, a microcontroller not only accepts the data as inputs but also anipulates it, interfaces the data with various devices, controls the data and thus finally gives the result. The “Automatic phase selector for single phase load from three phase supply’ using PIC16F72 microcontroller is an exclusive project which is used to select a phase from three phases and switch to another phase when the using phase is off.This project has three phases of 230v each and a relay interfaced to the micro controller Page 2 Thesis: The thesis explains the implementation of “Automatic phase selector for single phase load from three phase supply’ using PIC16F72 microcontroller.

The organization of he thesis is explained here with: 1. Presents introduction to the overall thesis and the overview of the project. In the project overview a brief introduction of Relays and its applications are discussed. 2. Presents the hardware description. It deals with the block diagram of the project and explains the purpose of each block.In the same chapter the explanation of microcontrollers, power supplies, LCD and Relays are considered.

3. Presents the software description. It explains the implementation of the project using PIC C Compiler software. 4 . Presents the project description along with relay nterfacing to microcontroller. 5. Presents the advantages, disadvantages and applications of the project. 6.

Presents the results, conclusion and future scope of the project. Page 3 HARDWARE DESCRIPTION Introduction: The block diagram of the project and design aspect of independent modules is considered.Block diagram is shown in fg: FIGI : Block diagram of Automatic phase selector system Page 4 The main blocks of this project are: 1. Micro controller (PIC16F72) 2. Crystal oscillator 3.

Reset 4. Regulated power supply (RPS) 5. LED Indicator 7. LCD PIC Microcontroller: Fig2 :PIC Microcontrollers Page 5 Introduction to PIC Microcontrollers: PIC stands for Peripheral Interface Controller given by Microchip Technology to identify its single-chip microcontrollers.

These devices have been very successful in 8-bit microcontrollers.The main reason is that Microchip Technology has continuously upgraded the device architecture and added needed peripherals to the microcontroller to suit customers’ requirements. The development tools such as assembler and simulator are freely available on the internet at www. microchip. com. Low-end PIC Architectures: Microchip PIC microcontrollers are available in various types. When PIC microcontroller MCIJ was first available from General Instruments in early 1980’s, the microcontroller consisted of a simple processor executing 12-bit wide instructions with basic 1/0 functions.These devices are known as low-end architectures.

They have limited program memory and are meant for applications requiring simple interface functions and small program & data memories. Some of the low-end device numbers are 12C5XX 16C5X 16C505 Mid-range PIC Architectures: Mid range PIC architectures are built by upgrading low-end architectures with more Some of the mid-range devices are 16C6X 16C7X 16F87X Program memory type is indicated by an alphabet. Page 6 C = EPROM, F = Flash, RC = Mask ROM Popularity of the PIC microcontrollers is due to the following factors. . Speed: Harvard Architecture, RISC architecture, 1 instruction cycle = 4 clock cycles.

2. Instruction set simplicity: The instruction set consists of Just 35 instructions (as opposed to 111 instructions for 8051). 3. Power-on-reset and brown-out reset. Brown-out-reset means when the power supply goes below a specified voltage (say 4V), it causes PIC to reset; hence malfunction is avoided. A watch dog timer (user programmable) resets the processor f the software/program ever malfunctions and deviates from its normal operation. .

PIC microcontroller has four optional clock sources. Low power crystal Mid range crystal High range crystal RC oscillator (low cost). 5. Programmable timers and on-chip ADC. 6.

Up to 12 independent interrupt sources. 7. Powerful output pin control (25 mA (max. ) current sourcing capability per pin. ) 8.

EPROM/OTP/ROWFlash memory option. 9. 9. 1/0 port expansion capability. Basically, all PIC microcontrollers offer the following features: 0 On-chip timer with 8-bit prescaler,power-on reset Watchdog timer,Power saving SLEEP modeDirect, indirect, and relative addressing modes External clock interface,RAM data memory EPROM (or OTP) program memory page 7 Peripheral features: High sink/source current 25mA TimerO: 8-bit timer/counter with 8-bit prescaler can be incremented during sleep via external crystal/clock Timer2:8-bit timer/counter with 8-bit period register prescaler and post scalar. Capture, Compare, PWM (CCP) module Compare is 16-bit, max resolution is 200 ns PWM max, resolution is 10-bit 8-bit 5 channel analog-to-digital converter Synchronous serial port (SSP) with SPI (Master/Slave) and (Slave) Some devices offer the following additional features:Analogue input channels Analogue comparators Additional timer circuits EEPROM data memory Flash EEPROM program memory External and timer interrupts Internal oscillator USART serial interface Page 8 High-Performance RISC CPU ??? High performance RISC CPU ??? Only 35 single word instructions to learn ??? All single cycle instructions except for program branches which are two-cycle ??? Operating speed: DC – 20 MHz clock input DC – 200 ns instruction cycle ??? 2K x 14 words of Program Memory 128 x 8 bytes of Data Memory (RAM) ??? Pin out compatible to the PIC16C72/72A and PIC16F872 ?? Interrupt capability ??? Eight level deep hardware stack ??? Direct, Indirect and Relative Addressing modes Peripheral Features ??? TimerO: 8-bit timer/counter with 8-bit prescaler ??? Timerl : 16-bit timer/counter with prescaler, can be incremented during SLEEP via external crystal/clock ??? Timer2: 8-bit timer/counter with 8-bit period register, prescaler and postscaler ??? Capture, Compare, PWM (CCP) module – Capture is 16-bit, max resolution is 12.

5 ns Page 9 – Compare is 16-bit, max resolution is 200 ns – PWM max resolution is 10-bit ??? 8-bit, 5-channel Analog-to-Digital converter ?? Synchronous Serial Port (SSP) with SPI (Master mode) and 12C (Slave) ??? Heat sink/ Source Current: 25 mA ??? Brown-out detection circuitry for Brown-out Reset (BOR) Following are the major blocks of PIC Microcontroller. Program memory (FLASH) is used for storing a written program. Since memory made microcontroller suitable for device development. EEPROM – data memory that needs to be saved when there is no supply.It is usually used for storing important data that must not be lost if power supply suddenly stops. For instance, one such data is an assigned temperature in temperature regulators.

If uring a loss of power supply this data was lost, we would have to make the adjustment once again upon return of supply. Thus our device looses on self- reliance. RAM – Data memory used by a program during its execution. In RAM are stored all inter-results or temporary data during run-time. PORTS are physical connections between the microcontroller and the outside world. PIC16F72 has 22 1/0. FREE-RUN TIMER is an 8-bit register inside a microcontroller that works independently of the program.On every fourth clock of the oscillator it increments its value until it reaches the maximum (255), and then it starts counting over again from ero.

As we know the exact timing between each two increments of the timer contents, timer can be used for measuring time which is very useful with some devices. page 10 CENTRAL PROCESSING UNIT has a role of connective element between other blocks in the microcontroller. It coordinates the work of other blocks and executes the user program. CISC, RISC: It has already been said that PIC16F72 has RISC architecture.

This term is often found in computer literature, and it needs to be explained here in more detail.Harvard architecture is a newer concept than von-Neumann. It rose out of the need to speed p the work of a microcontroller. In Harvard architecture, data bus and address bus are separate. Thus a greater flow of data is possible through the central processing unit, and of course, a greater speed of work. Separating a program from data memory makes it further possible for instructions not to have to be 8-bit words. PIC16F72 uses 14 bits for instructions, which allows for all instructions to be one-word instructions. It is also typical for Harvard architecture to have fewer instructions than von- Neumann’s, and to have instructions usually executed in one cycle.

Microcontrollers with Harvard architecture are also called “RISC microcontrollers”. RISC stands for Reduced Instruction Set Computer. Microcontrollers with von- Neumann’s architecture are called ‘CISC microcontrollers’. Title CISC stands for means that it has a reduced set of instructions, more precisely 35 instructions. (Ex. Intel’s and Motorola’s microcontrollers have over hundred instructions) All of these instructions are executed in one cycle except for Jump and branch Automatic Phase Selection Page 1 1 instructions. According to what its maker says, PIC16F72 usually reaches results of :1 in code compression and 4:1 in speed in relation to other 8-bit microcontrollers in its class.Applications: PIC16F72 perfectly fits many uses, from automotive industries and controlling home appliances to industrial instruments, remote sensors, electrical door locks and safety devices.

It is also ideal for smart cards as well as for battery supplied devices because of its low consumption. EEPROM memory makes it easier to apply microcontrollers to devices where permanent storage of various parameters is needed (codes for transmitters, motor speed, receiver frequencies, etc. ). Low cost, low onsumption, easy handling and flexibility make PIC16F72 applicable even in areas where microcontrollers had not previously been considered (example: timer functions, interface replacement in larger systems, coprocessor applications, etc.

).In System Programmability of this chip (along with using only two pins in data transfer) makes possible the flexibility of a product, after assembling and testing have been completed. This capability can be used to create assembly-line production, to store calibration data available only after final testing, or it can be used to improve programs on finished products. page 12 Pin diagram: The PIC16F72 CMOS FLASH-based 8-bit microcontroller is upward compatible with PIC16C72/72A and PICI 6F872devices. It features 200 ns instruction execution, self programming, an ICD, 2 Comparators, 5 channels of 8-bit Analog-to-Digital (AID) converter, 2 capture/compare/PWM functions, a synchronous serial port that can be configured as either 3-wire SPI or 2-wire 12C bus, a USART, and a Parallel Slave Port.Pin description: PIC16F72 has a total of 28 pins. It is most frequently found in a DIP28 type of case but can also be found in SMD case which is smaller from a DIP. DIP is an abbreviation for Dual In Package.

SMD is an abbreviation for Surface Mount Devices suggesting that holes for pins to go through when mounting aren’t necessary in soldering this type of a component. page 13 Pins on PIC16F72 microcontroller have the following meaning: There are 28 pins on PIC16F72. Most of them can be used as an 10 pin. Others are already for specific functions. These are the pin functions. 1.

MCLR -to reset the PIC 22. RBI 2. 4.

5. 6. 7. 8.

3. RAI 9. OSCI – connect to oscillator 10.

OSC2 – connect to oscillator RAO- port A pin O – port A pin 1 RA2 – port A pin 2 RA3 – port A pin 3 RA4 – port A pin 4 RA5 – port A pin 5 VSS – ground port C pin O VDD – power supply 11. RCO 12. RCI – port C pin 1 13.

RC2 – port C pin 2 14. RC3 – port C pin 3 15. RC4 – port C pin 4 16. RC5 – port C pin 5 17. RC6 – port C pin 6 18. RC7- port C pin 7 19. VDD – power supply 20.

21 . RBO- port B pin O – port B pin 1 23. RB2 – port B pin 2 24. RB3- port B pin 3 25. RB4 – port B pin 4 26. RB5 – port B pin 5 27. RB6- port B pin 6 28.

RB7 – port B pin 7 Page 14 By utilizing all of this pin so many application can be done such as: 1. LCD to Port B pin. 2. LED – connect to any pin declared as output.

3. Relay and Motor – connect to any pin declared as output. – connect

x

Hi!
I'm Eileen!

Would you like to get a custom essay? How about receiving a customized one?

Check it out