??? 07/06/10 18:01 Read: times |
#177121 - triac firing angle |
Respected sir,
we are doing project on microcontroller AT89c2051 based triac(BT136) firing angle control.and also we have used opto isolated triac driver MOC3021. our hardware is running perfect.there is no problem in circuit.In first section we have used zero crossing detector circuit for triac control. also zero crossing waveform on CRO is perfect.we are using aassembly language for AT89c2051. But problem is that triac firing angle is not changed.and voltage comming out is continuous..230v. here i have attached my program code in asm language for At89c2051 we are using portpin P3.0,P3.1and P3.5 as zero crossing input to microcontroller.becouse of we have to turn triac on three different firing angle also we have used port pin p1.3 for optoisolator. ;*************************************************** MOV 080H,#0FFH MOV 090H,#0FFH MOV 0A0H,#0FFH MOV 0B0H,#0FFH RELAY EQU 093H SETB RELAY STARTC: CLR RELAY START: MOV A,0B0H CJNE A,#11111110B,STARTTA CLR RELAY ACALL DELAY ACALL DELAY SETB RELAY ACALL DELAY CLR RELAY SJMP START STARTTA:MOV A,0B0H CJNE A,#11111101B,STARTTB CLR RELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY SETB RELAY ACALL DELAY CLR RELAY SJMP START STARTTB:MOV A,0B0H CJNE A,#11011111B,STARTC CLR RELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY ACALL DELAY SETB RELAY ACALL DELAY CLR RELAY SJMP START DELAY: ;FOR 1-MILISECOND MOV R2,#02 LOOP: MOV R3,#245 LOP: DJNZ R3,LOP DJNZ R2,LOOP RET END ;************************************************************************* but still triac voltage is same 230v ac. thereis no change within firing angle we are waiting for your replay. Avni modi |