I have disigned a dimmer circuit using Pic12F629. It works fine but with a little electrical noise the pic is resetting. I have added L1 and L2 inductors (see circuit) and some capacitors across the supply but did not solve it completely.
Any idea how to make Pic completely immune to mains...