Fan regulator Using PIC16F628?

Status
Not open for further replies.
how to create remote control fan regulator









Hi,IanP
I tried to find out the zero crossing point.I used a 0-18v transformer.I rectified it with bridge rectifier and i gave this rectified voltage to the base of BC547.Base resistor=10k,collector resister=4.7k.The collector pin is connected to the RB0 pin of pic16f876a.I treid to read the time interval between two zero crossing(it must be 10ms right?)using timer1 with out using any prescaler.But i am getting the timer value as 19937.Ie that much microsecond instead of 10 ms.So where is the problem?Is threr any thing wrong with the programe or design?.


Here is the program in HI-Tech for finding the time period.
I used 4Mhz crystal.



#include <pic.h>
unsigned char first,second;
unsigned short x;


__CONFIG(WDTDIS & XT & UNPROTECT & PWRTDIS & BORDIS & LVPDIS );



/*************************************************************/

static void interrupt isr()
{
if(INTF)
{
GIE=0;

if(first)
{
TMR1ON=1; //First zero crossing timer value=0
first=0;

}
else if(second)
{
TMR1ON=0; //second zero crossing,Read timer1 in to x
x=TMR1H;
x=x<<8;
x=(x| TMR1L);
first=1;;

TMR1H=0;
TMR1L=0;
x=0;
}
}
INTF=0;
GIE=1;
}

void main(void)
{

T1CON=0b00001000;
TMR1H=0;
TMR1L=0;

first=1;
second=1;

TRISB=0b00000001;

INTF=0;
INTEDG=0;
INTE=1;
GIE=1;

while(1)
{

PORTB=0; //Nothing to in while loop

}

}
 

fan regulator circuit with pic

Hi,

I've been searching a way to design an opto-isolated zero crossing detector (220V AC). I've looked the entire forum and google but couldn't find a good answer. I don't want to use a transformer. Anyone have an idea ?

Franck.

Added after 1 hours:

It's ok, I've found the solution. Elektor 2002
 

pwm fan regulator

Hi
I tried with half wave and bridge rectifier.In both the result is the same ie 20ms.
Why my code not detecting the negative half cycle.Presently i dont have an oscilloscope to view the wave form.
Plzz Help........
 

pic 16f628 pwm

humpy said:
Hi
I tried with half wave and bridge rectifier.In both the result is the same ie 20ms.
Why my code not detecting the negative half cycle.Presently i dont have an oscilloscope to view the wave form.
Plzz Help........


Hi,
wht u r gettig is right.U r trying to measure the time between 2fallin edges.U converted the bridge o/p in to squarewave.Now measure the time between falling & risin edge.IT will be10.

Added after 12 minutes:

Hi,
In the first if add this line
INTEDGE=1;
In the 2nd if add this line
INTEDGE=0
Then try again
 

capacitive fan regulator circuit

humpy said:
Hi
I tried with half wave and bridge rectifier.In both the result is the same ie 20ms.
Why my code not detecting the negative half cycle.Presently i dont have an oscilloscope to view the wave form.
Plzz Help........

use bridge rectifier to a non center taped step down transformer ,connect another diode after bridge rectifier after that connect a resistor 10k l between the diode and bridge rectifier connection ,the other end to a transistorbase npn ,emiter to ground and collector to +5v through another 10K resistor.you will get a square wave for every zero crossing.
 

pic16f628 pwm motor control 1 pin

Hi,
I completed this board successfully.Now I am able to control the speed of AC fan(220v) with an RC5 remote.I want to improve the circuit for making it in to a programable remote fan regulator.
1: I want to add 7segment led display(small sized) plus one rtc chip (DS1307.)
There comes the problem of power supply.Now I getting 5v for pic,by connecting a dropping resistor to AC.So this circuit will be able to drive the Seven segment leds?

2: When the fan rotates , it generates a small hizzing sound.How can i remove that.I ddnt use any snubers for triac.

Regards
Sajeev
 

dc motor speed control pic16f628

Hi, I am looking for the answers.I have already buit the board.Is it possible to connect 7segment displays to the 5v line which used for powering pic?I ddnt use any transformer


Regards
Sajeev
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…