I have a circuit where i detect zero-crossing (Mains EU 230V 50Hz) with opto to arduino(interrupts). Then I need to delay (from 0 to 10 milliseconds) it to trigger Triac gate. but then I need another arduino to tell the first one how long the delay should be.
The variable delay should be like mapping 0-5V to delay time. so 0V no pulse(delay is indefinite) and 5V = no delay and 2,5V delay should be somewhere 5milliseconds.
I am not that good in electronics but i know that AC phase control can be done without first arduino. I have been checking 555 timers but am a bit lost.
So the end circuitry should be zero crossing triggering every 10 milliseconds (have this already with short pulses of 5V) to circuit where I would with PWM or 0-5V set the delay 0 to 10 milliseconds and send again a pulse out (DONT HAVE) to trigger Triac. Or at least point me to direction I should look into. Is timer 555 the right way or something else?