I have an Arduino Uno powering a 4-channel dimming triac board. It has the following wiring (sorry no pictorial)
Arduino pin 3 for zero-crossing to triac
Pin 4 for triac channel 1, pin 5-7 similarly
Vdc and ground configured properly
This configuration works fine
BUT...if I add a 2nd board for more channels, the 2nd board is not energized
I split Arduino pin 3 to zero crossing input on both triac boards
I ran 5Vdc to both boards
I ran Arduino pins 8-11 to triac for channels 5,6,7,8
The 1st Triac board runs fine, the 2nd board is dead. If I swap wiring around the 2nd board works for outputs 1-4, but the original board is inactive for channels 5-8...
Do I need to do something differently for each board with the power or zero crossing?
I suggest you spend some time thinking about this as the mains power can and will kill you if you goof. There are many boards out there that will work. Me being on the lazy side I use some 4 channel boards from KRIDA Electronics. I am at about 5 years of operation without any problems. I like them because they are smart and I communicate with I2C, they have a small micro that does all the processing etc, you control them similar to the PWM part of the Arduino. They have both leading and trailing edge dimmers. If LED lighting is involved I suggest you start with trailing edge.
Sorry but without a schematic and component listing I am not going to comment on your design. I do not know your resources and skill set to do a design like this.
Hi all,
yes, I should have been clearer in my O.P.
Yes, I'm using the timer1 library. The original code was written for me using a state machine and runs fine with one four-channel output. Arduino pin 3 is the zero crossing to triac board, pins 4-7 go directly to the triacs
If I put another triac board in parallel (Vcc, ground, and pin 3), and then route Arduino pins 8-11 to the 2nd board, it doesn't even light up the on-board LEDs
Be sure you connect the AC the same on both boards. L1 to L1 and L2 to L2. Changing this will cause it to fail but not damage the board. I have this board but elected to get the fancier one that had the processor on because of the load on the Arduino. You should be able to use one of the zero cross inputs as they should be the same.
The triac board supplies the signal that occurs at zero crossing, the code then uses that signal as an INPUT to phase OUTPUTs to the triac trigger circuit.
In summary, I have one Arduino Uno now driving two separate 4-channel Krida triac boards. The Arduino zero crossing INPUT is on pin 3. Triac board #1 is pinMode "OUTPUT" on pins 4-7, triac board#2 is pinMode "OUTPUT" on pins 8-11...
Yes, the zero crossing is an INPUT on pin 3 that comes from either of the triac boards.
The board as you show on the images does not look particularly safe to me.
Of course it's a bare PCB, that has to go in a suitable enclosure, but my main concern is that there is seemingly very little separation between the mains side and the low voltage side. There's a bridge rectifier, followed by a bunch of tiny components (that's all at mains voltage), and a bit further I see something that looks like an optocoupler.
The Arduino connector is very close to the high voltage section, with no clear separation. Just a few mm of PCB - no anti-tracking slots. Also there is no such slot under the optocoupler.
I hope there are four more optocouplers on the board, to drive the gates of the TRIACs. Those I don't see. If not, the board is utterly unsafe and everything connected to it - including the Arduino - should be considered at mains potential.
In order to use the zero crossing signal (Used in the timerone.h library), the ONLY wire goes from one of the Triac boards to the Arduino Uno as an input (pin 3).
The Triac boards are from Krida Electronics and have all the appropriate isolation from 120VAC to low signal circuitry.
The purpose of this year's project expansion was to drive eight (8) Triac outputs instead of the original four (4) outputs. The software uses a "state machine" and the Timerone library to count clock ticks that drives the fading function from one channel to another.
The only problems I have been incurring are:
The gate impulse from the timer function is set to five(5) and that may be a problem when the code was expanded to eight clock pulses. I have to research further.
This whole fading function doesn't behave well with LED lights versus incandescent
Until next year, happy new year! Be safe around electricity if you're doing anything with line voltages!
If you post the code and explain the issue with changing from 5 to 8 pulses you can get some help from the group.
This whole fading function doesn't behave well with LED lights versus incandescent
An internet search indicates that an ac led will dim better with trailing edge phase cutting. Are you doing that, or phase cutting at the leading edge (sine wave rising from 0)