arduino + optotriac based ac dimmer blinking severely
Description: The light is blinking instead of dimming. A specific software was used to illuminate the bulb without dimming, which includes the following code:
```cpp
unsigned int i = 1;
void setup() {
Serial.begin(9600);
pinMode(AC_pin, OUTPUT);
pinMode(11, OUTPUT);
attachInterrupt(0, light, RISING);
}
void light() {
i++;
digitalWrite(11, LOW);
delayMicroseconds(10);
digitalWrite(11, HIGH);
}
void loop() {
if (i % 100 == 0) {
Serial.println("100");
i = 1;
}
}
```
The results show that the code tests the zero-crossing circuit by counting up to 100 and printing a value (100) when it reaches that count. When the system runs without a load (with pin 11 not connected to the opto-triac), it provides a nearly perfect print rate of one per second, visibly steady. However, when pin 11 is connected to the opto-triac (MOC3021), the output load bulb begins to blink inconsistently, and the output from the optocoupler (4N25) becomes erratic, not outputting every second but instead appearing random. It is important to note that instead of MOC3021, an EL3021 is being used, and a BT136 triac is used in place of the TIC206. Currently, there is no snubber circuit in use. Previous attempts with different software have not resolved the issue, although the provided schematic differs slightly in terms of biasing, the exact values from the attached schematic are being utilized. Assistance is requested to resolve this problem.
The described circuit involves a microcontroller interfacing with an opto-isolator and a triac to control an AC load. The microcontroller is programmed to count and print a message at regular intervals, relying on an interrupt service routine (ISR) to manage the timing of the output signal. The use of an EL3021 opto-isolator instead of the MOC3021 may introduce variations in the switching characteristics, affecting the performance of the overall circuit.
In this configuration, the opto-isolator serves to safely interface the low-voltage control signal from the microcontroller with the higher-voltage AC load. The BT136 triac is intended to switch the AC load on and off based on the control signal provided by the opto-isolator. The blinking behavior observed may be attributed to several factors, including the lack of a snubber circuit, which is typically used to suppress voltage transients that can occur when switching inductive loads. The absence of this component might lead to instability in the control signal, resulting in the erratic blinking of the load.
To troubleshoot this issue, it is advisable to examine the timing and characteristics of the signals being generated by the microcontroller and opto-isolator. Verifying the connections and ensuring that the correct components are used according to the specifications of the circuit is essential. Additionally, implementing a snubber circuit across the triac could help mitigate any voltage spikes and improve the stability of the output signal.
Furthermore, it may be beneficial to review the interrupt handling within the microcontroller code to ensure that it is not being disrupted by other processes. The use of debouncing techniques or additional filtering may also be considered to enhance the performance of the circuit. By addressing these factors, the overall functionality of the circuit can be improved, leading to a more stable dimming control of the AC load.The light is simply blinking instead of dimming. So I used the following software to just glow the bulb without dimming: unsigned int i=1; void setup() { Serial. begin(9600); pinMode(AC_pin, OUTPUT); pinMode(11, OUTPUT); attachInterrupt(0, light, RISING); } void light(){ i+; digitalWrite(11, LOW); delayMicroseconds(10); digitalWrite(11, HIGH); } void loop(){ if(i%100=0){ Serial.
println("100"); i=1; } } Following are the results: In the above code I am testing the zero crossing circuit just by counting upto 100, and printing a value (100) when it turns hundred. When i run the system without load (pin 11 is not connected to opto triac) it gives me almost perfect print rate of 1 per second (visibly) and steady.
Now if i connect pin 11 to opto triac 3021, the output load bulb starts blinking (not steady at all), and also the output of optocoupler (4n25) gets randomized; Visibily i can see it is not giving output at every 1 second, rather it is somewhat random. Please note instead of MOC3021 i am using EL3021, and in place of TIC206 triac i used bt 136. I am not using any snubber right now. I also tried the software from. Still with no luck however their schematic is little bit different in terms of biasing but i am using exact values from the schematic attached.
Connect eight LEDs to an Arduino and create a Knight Rider display using only two Arduino pins in this tutorial. This is achieved by utilizing a PCF8574 I/O expander IC.
To implement the Knight Rider display using an Arduino and a...
A simple game console was created to play Pong and other games using Atari 2600 joysticks. The Arduino processes joystick inputs and outputs the data to a TV using the TVout library. The project was designed to demonstrate that anyone...
The example programs and Arduino sketches provided are free software.
The provided example programs and Arduino sketches serve as a valuable resource for developers and hobbyists working with Arduino microcontrollers. These software tools are designed to facilitate learning and experimentation with...
For an upcoming project, a pneumatic ram with a closed-loop control system was required to achieve precise positioning. Due to budget constraints, an off-the-shelf solution was not feasible, prompting the assembly of a custom system using an Arduino, a couple...
The system is designed to regulate an 860-watt lamp load from half to full power. This is achieved through the controlled half-plus-fixed half-wave phase control method. Applying half power to an incandescent lamp results in 30% of the full light...
An Arduino is used to measure the rotational speed of a basic computer fan. This project was part of a series of YouTube videos created during a Master's program in Computer Science, specifically focusing on an embedded systems programming course...
An Arduino voltmeter that displays voltage on an LCD display. The voltmeter has 4 channels for measuring four different voltages.
The Arduino voltmeter utilizes an Arduino microcontroller to measure and display voltage levels on a Liquid Crystal Display (LCD). This device...
A tutorial on LCD communication was planned for a later date due to high demand. A circuit was already assembled for testing a new LCD provided by element14. The tutorial explains how communication functions with modern LCD character displays, showcasing...
The objective of this project is to consolidate various robot designs and transform them into a new device featuring updated hardware and standardized software, specifically utilizing Arduino for ease of use. These robots share three key components: a mechanical structure,...
We use cookies to enhance your experience, analyze traffic, and (if you allow) serve personalized ads.
By clicking Accept All, you agree to our use of cookies.
Learn more