dimming 120 VAC lights with PWM output

Want to control 120 vac lights using PWM outputs from arduino mega board. Tried a Sharp S101S02 zero crossing SSR but heavy flicker not smooth dim below full on. Any help appreciated.

You need to use a voltage controlled dimmer, which you can drive from a PWM pin with a smoothing resistor and capacitor. See http://www.vellemanusa.com/products/view/?id=521945 for an example. The manual says it can be adjusted to take a 0 to 5v control input.

THanks for the response ie Vellman unit.Want to build a 12 channel unit based on arduino that receives sound from a mic or audio input and drives 120 Vac light strings on a xmas tree. Want to also have a preprogrammed section for different effects. Would like to find a method (like SSR's) to keep cost down. Thought I might input 60hz signal into an analog input and watch for zero cross of sine wave to control pulse sync to fire SSR like the Sharp S101S02 or adjust PWM speed in arduino registers. New to Arduino world and just learning C/C++ language. Lovin it. If I cant find a low cost SSR solution I would consider a circuit design with triac, optic coupler etc to again keep cost down. Xmas tree light string are less than 1/2 amp per string. Havent measured exact current but will. The sharp SSR was attractive for a 1.25 amp, 400v, 20ma control and less than $4.00 each. Any help greatly appreciated. Any code also great.

The concept of doing your own zero crossing detection and hence timing the phase control yourself for a 12 channel unit is sound. However, that Sharp SSR has built-in zero crossing detection, so it can't be used for phase control. You can use an SSR that has instant turn-on instead of zero crossing turn on, or you can use an opto triac to drive a regular triac.

Thank you so much for your response. I understand what you said. Do you know of a SSR that would work at a low cost? Do you know of a better approach to the problem?
All my circuit books are at least 30 years old. Started in the 1960s with tubes etc. Do you know of a good book or books on circuits. Bought the Arduino Cookbook among others and am enjoying it.
A real trip to be learning C/C++ at 67. Lovin it and really impressed with Arduino.
Again thanks for your help.
Had an old PLC system but figured as soon as I used it it would fail with no support.

dlbowman:
Thank you so much for your response. I understand what you said. Do you know of a SSR that would work at a low cost?

A quick search of one of my suppliers websites for non-zero crossing AC mains SSRs showed up these: http://uk.rs-online.com/web/c/relays-switches-indicators/relays/pcb-solid-state-relays-ssr/?searchTerm=solid+state+relay&sort-by=P_breakPrice1&sort-order=asc&sort-option=Price&applied-dimensions=4294576235,%204294847806,%204294851928,%204294790748,%204294850565,%204294849104,%204294806213,%204294806116,%204294767732,%204294678564,%204294806210,4294851468&lastAttributeSelectedBlock=4294955701.