EN / USD
32
of 76
TEP , The Engineering Projects , Image

syedzainnasir

TEP , The Engineering Projects , Rating 7.5 7.5 / 10
TEP , The Engineering Projects , Icon Level: Moderator
TEP , The Engineering Projects , Icon Joined: 20 Mar 2022
TEP , The Engineering Projects , Icon Last Active: 2:21 PM
TEP , The Engineering Projects , Icon Location: TEP , The Engineering Projects , Flag
TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon
Making an animated relay in proteus
TEP , The Engineering Projects , Calender Question: 20-Feb-2017
TEP , The Engineering Projects , Category In: Proteus Projects
Hi all,
I am trying to make an animated relay work to switch on the bulb in my circuit. When a input is given to the pic16f877A, it is to make the relay on the bulb. I have fixed everything correctly( according to me...). But i can't make the relay work when i execute (F12). The lcd included works well though. Pls help. I will include the coding and the picture of the circuit. Also what do the blue and red square lights that appear in the proteus simulation.
Pls do help me.
Thanks
S.Trinetra

p.s
relay is set to 5V. It is still not working.
Do u notice the power terminal connected to one part of the relay and diode. Must have a certain value? I can't seem to insert any value.
Do u think that there is something wrong with the code in Mplab?
Must ac source and bulb be connected to the transistor and ground?
[code] #include<htc.h> #include <pic.h> __CONFIG ( 0x3F32 ); #define data PORTD //Pins to the LCD D0-D7 #define rs RC2 //rs of LCD #define rw RC0 //rw of LCD #define en RC3 //e of LCD #define in RE0 //input for RFID // The above pins can be changed according to whicheva u choose void initialize(); void busy(); void display(unsigned char one[], unsigned char two[]); void command(unsigned char var); void send_data(unsigned char var); void string(unsigned char *var); unsigned char text1[]={"RFID PROJECT"}; unsigned char text2[]={"PLACE YOUR CARD"}; unsigned char text3[]={"CARD ACCEPTED"}; unsigned char text4[]={"CARD REJECTED"}; unsigned char text5[]={" "}; //Additional text can be placed above. and can be called according to how //u the calling in the code void main(void) { int i, d; ADCON1 = 0x06; TRISC=0x00; TRISD=0X00; TRISE=0x01; initialize(); display(text1, text2); while(1) { if (in==1) { RC1=1; display(text3, text5); busy(); } else { RC1=0; display(text4, text5); busy(); } } } void initialize() { data=0x38; rs=0; rw=0; en=1; en=0; busy(); data=0x0E; rs=0; rw=0; en=1; en=0; busy(); data=0x01; rs=0; rw=0; en=1; en=0; busy(); data=0x06; rs=0; rw=0; en=1; en=0; busy(); } void busy() { unsigned char i,j; for(i=0;i<50;i++) for(j=0;j<255;j++); } void command(unsigned char var) { data=var; rs=0; rw=0; en=1; en=0;busy(); } void send_data(unsigned char var) { rs=1;rw=0; en=1; data=var; en=0; busy(); } void string(unsigned char *var) { while(*var) send_data(*var++); } void display(unsigned char one[], unsigned char two[]) { command(0x80); string(one); command(0xC0); string(two); busy(); } [/code]
TEP , The Engineering Projects , Icon Answer: 1 TEP , The Engineering Projects , Icon Views: 150 TEP , The Engineering Projects , Icon Followers: 85
Small Bio
TEP , The Engineering Projects , Image

adiono

TEP , The Engineering Projects , Rating 7.5 7.5 / 10
TEP , The Engineering Projects , Icon Level: Moderator
TEP , The Engineering Projects , Icon Joined: 20 Mar 2022
TEP , The Engineering Projects , Icon Last Active: 2:21 PM
TEP , The Engineering Projects , Icon Location: TEP , The Engineering Projects , Flag
TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon TEP , The ENgineering Projects , Icon

RE:

Making an animated relay in proteus
TEP , The Engineering Projects , Calender Comment: 20-Feb-2017
TEP , The Engineering Projects , Category In: Proteus Projects
[quote=Eugene post_id=93 time=1487592165 user_id=72] Hi all,
I am trying to make an animated relay work to switch on the bulb in my circuit. When a input is given to the pic16f877A, it is to make the relay on the bulb. I have fixed everything correctly( according to me...). But i can't make the relay work when i execute (F12). The lcd included works well though. Pls help. I will include the coding and the picture of the circuit. Also what do the blue and red square lights that appear in the proteus simulation.
Pls do help me.
Thanks
S.Trinetra

p.s
relay is set to 5V. It is still not working.
Do u notice the power terminal connected to one part of the relay and diode. Must have a certain value? I can't seem to insert any value.
Do u think that there is something wrong with the code in Mplab?
Must ac source and bulb be connected to the transistor and ground?
[code] #include<htc.h> #include <pic.h> __CONFIG ( 0x3F32 ); #define data PORTD //Pins to the LCD D0-D7 #define rs RC2 //rs of LCD #define rw RC0 //rw of LCD #define en RC3 //e of LCD #define in RE0 //input for RFID // The above pins can be changed according to whicheva u choose void initialize(); void busy(); void display(unsigned char one[], unsigned char two[]); void command(unsigned char var); void send_data(unsigned char var); void string(unsigned char *var); unsigned char text1[]={"RFID PROJECT"}; unsigned char text2[]={"PLACE YOUR CARD"}; unsigned char text3[]={"CARD ACCEPTED"}; unsigned char text4[]={"CARD REJECTED"}; unsigned char text5[]={" "}; //Additional text can be placed above. and can be called according to how //u the calling in the code void main(void) { int i, d; ADCON1 = 0x06; TRISC=0x00; TRISD=0X00; TRISE=0x01; initialize(); display(text1, text2); while(1) { if (in==1) { RC1=1; display(text3, text5); busy(); } else { RC1=0; display(text4, text5); busy(); } } } void initialize() { data=0x38; rs=0; rw=0; en=1; en=0; busy(); data=0x0E; rs=0; rw=0; en=1; en=0; busy(); data=0x01; rs=0; rw=0; en=1; en=0; busy(); data=0x06; rs=0; rw=0; en=1; en=0; busy(); } void busy() { unsigned char i,j; for(i=0;i<50;i++) for(j=0;j<255;j++); } void command(unsigned char var) { data=var; rs=0; rw=0; en=1; en=0;busy(); } void send_data(unsigned char var) { rs=1;rw=0; en=1; data=var; en=0; busy(); } void string(unsigned char *var) { while(*var) send_data(*var++); } void display(unsigned char one[], unsigned char two[]) { command(0x80); string(one); command(0xC0); string(two); busy(); } [/code] [/quote]
I think you are looking for the [url=http://www.theengineeringprojects.com/2014/11/relay-simulation-in-proteus-isis.html]Relay Simulation in Proteus ISIS[/url]
TEP , The Engineering Projects , Tick Correct Answer
Comment Bio
TEP , The Engineering Projects , Tags
PLC
Robot
STM32
Arduino
AI
ESP32
Ladder Logic
PLC Projects
Programming
Communicates STM32
PLC Projects
Communicates PLC
Font Style
Alignment
Indenting and Lists
Insert Media
Insert Items

Want to leave an answer!

Word Count :0 Draft Saved at 12:42 am.